You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2018/01/24 09:45:11 UTC

[Bug 62041] New: ant build fails

https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

            Bug ID: 62041
           Summary: ant build fails
           Product: POI
           Version: 4.0-dev
          Hardware: PC
                OS: Mac OS X 10.1
            Status: NEW
          Severity: normal
          Priority: P2
         Component: POI Overall
          Assignee: dev@poi.apache.org
          Reporter: wf@bitplan.com
  Target Milestone: ---

[java] There was 1 failure:
     [java] 1) resizeToFitTextXSLF(org.apache.poi.sl.TestFonts)
     [java] java.lang.AssertionError: 391 wasn't within the expected sizes:
[304, 306, 311, 312, 313, 318, 348, 362, 372, 377, 398, 399, 406]
     [java]     at org.junit.Assert.fail(Assert.java:88)
     [java]     at org.junit.Assert.assertTrue(Assert.java:41)
     [java]     at
org.apache.poi.sl.TestFonts.resizeToFitText(TestFonts.java:143)
     [java]     at
org.apache.poi.sl.TestFonts.resizeToFitTextXSLF(TestFonts.java:106)
...
     [java]     at org.apache.poi.util.OOXMLLite.build(OOXMLLite.java:149)
     [java]     at org.apache.poi.util.OOXMLLite.main(OOXMLLite.java:94)
     [java] 
     [java] FAILURES!!!
     [java] Tests run: 2354,  Failures: 1
     [java] 
     [java] Exception in thread "main" java.lang.RuntimeException: Tests did
not succeed, cannot build ooxml-lite jar
     [java]     at org.apache.poi.util.OOXMLLite.build(OOXMLLite.java:151)
     [java]     at org.apache.poi.util.OOXMLLite.main(OOXMLLite.java:94)

BUILD FAILED
/Users/wf/Documents/workspace/poi/build.xml:1519: Java returned: 1

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

--- Comment #9 from Wolfgang Fahl <wf...@bitplan.com> ---
with 391 in the correct place the compile works.
I'd now like to use the created jar file in my maven projects. There seem to be
three build options:
- ant
- gradle
- maven

which of these will get me to make the new poi-4.0.0-SNAPSHOT.jar available
locally?

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

--- Comment #3 from Wolfgang Fahl <wf...@bitplan.com> ---
echo "testok" > build/ooxml-lite-testokfile.txt;ant jar
also does not work - the build logic seems to be forcing the tests even if the
corresponding flag is set to not to do this.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

--- Comment #2 from Wolfgang Fahl <wf...@bitplan.com> ---
same as for the gradle build
This is on High Sierra Mac Os 10.13.2 javac 1.8.0_152

Additionally I do not have a workaround at this time. I'd love to build without
running the tests. I tried

ant jar -Dooxml.lite.test.notRequired=true
but then get
/Users/wf/Documents/workspace/poi/build.xml:1811: The following error occurred
while executing this line:
/Users/wf/Documents/workspace/poi/build.xml:1798:
/Users/wf/Documents/workspace/poi/build/ooxml-lite-classes does not exist.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

Wolfgang Fahl <wf...@bitplan.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] TestFonts fails on Mac

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

Andreas Beeker <ki...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|ant build fails             |TestFonts fails on Mac

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

Wolfgang Fahl <wf...@bitplan.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |wf@bitplan.com

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

Nick Burch <ap...@gagravarr.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #1 from Nick Burch <ap...@gagravarr.org> ---
Which JDK are you using, and on what platform?

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

--- Comment #7 from Andreas Beeker <ki...@apache.org> ---
When I've initially written the test, I hoped that there are only minimal
differences on the various platforms. I wanted to have something simple to
validate if the line-breaks, the font loading/rendering and other issues work,
therefore I've used the textbox height. 
Furthermore the fixed list (opposed to a range of e.g. 300-450) would fail
faster if something in the rendering changes.

But when you look at the list of values now, we have a spread from 304 to 406
so that's not really validating anything of the above and eventually also lead
to failing tests, especially with the interesting font handling on Mac OS [1]

So currently I think using the range 300-450 would be a compromise and
hopefully minimize failing builds ... or the other solution would be to skip
the assert on Mac OS, in the assumption that the font selection is mysterious
there and more users are using Linux/Windows and might have already complaint

[1] https://stackoverflow.com/questions/26063828

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

--- Comment #6 from Alain Fagot Bearez <Al...@cua.li> ---
MacOS is contributing only 3, now 4 of these magic values, out of 14.

Or would the test only support one version of some arbitrary OS? And then all
developers should run the tests in a container on their machine? What about
variations on the continuous integration infrastructure? 

At least we should document the workaround for devs wanting to run locally with
reduced overhead.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

--- Comment #5 from Andreas Beeker <ki...@apache.org> ---
Actually we probably should simply skip those platform dependent test on Mac OS
...

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

--- Comment #4 from Alain Fagot Bearez <Al...@cua.li> ---
You are the lucky owner of a new OS. 

Please open a pull request adding the value `391` to the list of accepted sizes
in `org.apache.poi.sl.TestFonts`.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

--- Comment #8 from Wolfgang Fahl <wf...@bitplan.com> ---
I added 391 and now get
   [java] java.lang.AssertionError: 391 wasn't within the expected sizes: [304,
306, 311, 312, 313, 318, 348, 362, 372, 377, 398, 391, 399, 406]
so I now have to fix the source again since obviously there is an assumption
that the values are in ascending order ...

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] TestFonts fails on Mac

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

Andreas Beeker <ki...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|NEW                         |RESOLVED

--- Comment #11 from Andreas Beeker <ki...@apache.org> ---
I've added the 391 now to TestFonts via r1831948
On the next font size complaint, I'll change the assert to a range check.
If you have further problems with failing tests on the Mac, please reopen this
issue.
For further assistance on the build, please use the dev mailing list.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 62041] ant build fails

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62041

--- Comment #10 from PJ Fanning <fa...@yahoo.com> ---
Hi Wolfgang,
The poi build is not very newbie friendly.
I would suggest the easiest thing to do is to use `ant jar` to build the jars
and if you need to access them from another local project, most build tools
facilitate this. For example, gradle has support like this:
https://stackoverflow.com/a/20956456/987959

compile files('/path/to/poi-4.0.0-SNAPSHOT.jar') 

You will need to explicitly reference all the poi snapshot jars that your build
depends on.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org