Bug 30852 - [patch][enhancement] "No meaningful layout in block" --> better location in FOPException
Summary: [patch][enhancement] "No meaningful layout in block" --> better location in F...
Status: CLOSED WONTFIX
Alias: None
Product: Fop - Now in Jira
Classification: Unclassified
Component: general (show other bugs)
Version: 0.20.5
Hardware: Other other
: P3 enhancement
Target Milestone: ---
Assignee: fop-dev
URL:
Keywords:
: 30851 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-08-25 17:22 UTC by tagunov
Modified: 2012-04-01 13:51 UTC (History)
0 users



Attachments
The patch (2.90 KB, patch)
2004-08-25 17:25 UTC, tagunov
Details | Diff
Sample source files to test the patch (30.00 KB, application/octet-stream)
2004-08-25 17:26 UTC, tagunov
Details
The revised patch (prev variant contained bad formatting - tabs and a stray import) (2.85 KB, patch)
2004-08-25 18:01 UTC, tagunov
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description tagunov 2004-08-25 17:22:35 UTC
While a new version of FOP is being designed and coded it would be highly benefitial to current FOP users to have

* more precise [systemId + line] reported when
  FOP is unable to generate a layout
  and endless loop terminator kicks in

* getters for systemId, line, column on FOPException

In fact currently when FOPException with message

    No meaningful layout in block after many attempts.
    Infinite loop is assumed.  Processing halted.

is thrown it may produce very little infromation that would help user
to locate offending fo element. In our case it contained line/column for
our fo:root element!

The proposed patch goes down FObj tree following markers and thus
locates offending fo element (a too large png imange in our case)
pretty well.

Also, while we're at it, getters for systemId, line, column on FOPException
are also helpful (we won't have to parse FOPException.getMessage() once we
have them)
Comment 1 tagunov 2004-08-25 17:24:40 UTC
This patch is an enhancement to infinite loop terminator
which was commited while fixing bug #8778
Comment 2 tagunov 2004-08-25 17:25:51 UTC
Created attachment 12529 [details]
The patch
Comment 3 tagunov 2004-08-25 17:26:47 UTC
Created attachment 12530 [details]
Sample source files to test the patch
Comment 4 tagunov 2004-08-25 18:01:27 UTC
Created attachment 12531 [details]
The revised patch (prev variant contained bad formatting - tabs and a stray import)
Comment 5 tagunov 2004-08-25 18:17:13 UTC
*** Bug 30851 has been marked as a duplicate of this bug. ***
Comment 6 tagunov 2004-08-25 18:17:59 UTC
Glen's comment (from bug #30851)

Thanks--we have this in our upcoming 1.0 version however.  FOPException is 
being downgraded/deprecated in much of the code in favor of SAXParseException, 
which already has methods to provide locator (line, col, sys id) information. 

I'm inclined not to make this change in our 0.20.5 version--the branch is 
frozen, and we're trying to emphasize resources with 1.0, but am keeping this 
open in case other committers feel differently.

Glen
Comment 7 Pascal Sancho 2007-11-20 01:45:08 UTC
Glenn kept this open in case of… but said that it is only applicable to 0.20.5.

What to do now?
Comment 8 Jeremias Maerki 2007-11-20 02:43:16 UTC
Latest FOP includes this functionality. The error messages were improved in a
number of places.
Comment 9 Glenn Adams 2012-04-01 13:51:33 UTC
batch transition to closed remaining pre-FOP1.0 resolved bugs