You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Tilman Hausherr (JIRA)" <ji...@apache.org> on 2017/11/10 18:04:00 UTC

[jira] [Closed] (PDFBOX-3987) Apache PDFBox {2.0.6,2.0.7} java.lang.NoSuchMethodError: org.apache.fontbox.ttf.TrueTypeFont.getOriginalDataSize()

     [ https://issues.apache.org/jira/browse/PDFBOX-3987?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Tilman Hausherr closed PDFBOX-3987.
-----------------------------------
    Resolution: Cannot Reproduce

Closing as no further information has been coming. Make sure that you have only one version in the class path and that the versions of pdfbox and fontbox match. {{getOriginalDataSize()}} is called in our build tests so there's no way there would be any incompatibility. If you can't find the cause, search for old versions within other software in your classpath (e.g. tika). Or use extreme measures and delete everything from your classpath do your installation steps again.

Current version is now 2.0.8.

> Apache PDFBox {2.0.6,2.0.7} java.lang.NoSuchMethodError: org.apache.fontbox.ttf.TrueTypeFont.getOriginalDataSize()
> ------------------------------------------------------------------------------------------------------------------
>
>                 Key: PDFBOX-3987
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-3987
>             Project: PDFBox
>          Issue Type: Bug
>          Components: FontBox
>    Affects Versions: 2.0.6, 2.0.7
>         Environment: Oracle Linux Server 6.8, Sun/Oracle Java SE JDK 1.8.0_141, jetty-8.1.12.v20130726, ActiveWeb-1.15
>            Reporter: Sergei Haramundanis
>
> The following exception occurs during PDF generation using Apache PDFBox. It appears to be caused because Apache PDFBox {2.0.7,2.0.6} is bundled with and uses dependent library Apache FontBox org.apache.pdfbox:fontbox:bundle:2.0.7, of which class org.apache.fontbox.ttf.TrueTypeFont does not include the implementation for getOriginalDataSize(), although it is documented in the API docs.
> java.lang.NoSuchMethodError: org.apache.fontbox.ttf.TrueTypeFont.getOriginalDataSize()J
>         at org.apache.pdfbox.pdmodel.font.TrueTypeEmbedder.buildFontFile2(TrueTypeEmbedder.java:117)
>         at org.apache.pdfbox.pdmodel.font.PDCIDFontType2Embedder.buildSubset(PDCIDFontType2Embedder.java:106)
>         at org.apache.pdfbox.pdmodel.font.TrueTypeEmbedder.subset(TrueTypeEmbedder.java:319)
>         at org.apache.pdfbox.pdmodel.font.PDType0Font.subset(PDType0Font.java:176)
>         at org.apache.pdfbox.pdmodel.PDDocument.save(PDDocument.java:1270)
>         at org.apache.pdfbox.pdmodel.PDDocument.save(PDDocument.java:1249)
>         at org.apache.pdfbox.pdmodel.PDDocument.save(PDDocument.java:1237)
> ...
> The web application source code does not directly call this method, so it is an internal dependent call made by Apache PDFBox.
> This is a runtime error only, no related errors observed during the build process.
> This issue first appears in Apache PDFBox 2.0.6 and is not present in Apache PDFBox 2.0.5.
> Current workaround is to downgrade Apache PDFBox to 2.0.5, which temporarily solves the problem until the bundled Apache FontBox can be fixed.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: dev-help@pdfbox.apache.org