[reportlab-users] Failed test with reportlab-4.0.0

James PK jamespk at reportlab.com
Fri Jun 9 06:10:33 EDT 2023


Hi Antonio,

Thanks for the feedback and test results. We made changes to our extensions
for bitmaps and text paths in 4.0 (
https://docs.reportlab.com/releases/notes/whats-new-40/),
and it looks like you witnessed that in your test.

However, we have released 4.0.4 that as appropriate, should now skip
specific tests if we can't find the right extensions.

Regards,

James


On Sat, 20 May 2023 at 15:21, Antonio T. sagitter <
sagitter at fedoraproject.org> wrote:

> Hi all.
>
> A test of reportlab-4.0.0, compiled in Fedora 38 with Python-3.11, is
> failing with these errors:
>
> + cd reportlab-4.0.0
> + cp -a build/lib/reportlab tests/
> + cp -a build/lib/reportlab docs/
> + cp -a build/lib/reportlab docs/userguide/
> + /usr/bin/python3 setup.py tests
> .........Traceback (most recent call last):
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/docs/userguide/genuserguide.py",
>
> line 107, in <module>
>      main()
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/docs/userguide/genuserguide.py",
>
> line 105, in main
>      run(pagesize, verbose,outDir)
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/docs/userguide/genuserguide.py",
>
> line 56, in run
>      exec(open_and_read(f+'.py', mode='r'), G, G)
>    File "<string>", line 175, in <module>
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/docs/userguide/reportlab/graphics/charts/textlabels.py",
>
> line 20, in <module>
>      from ..utils import text2Path as _text2Path   #here for continuity
>      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/docs/userguide/reportlab/graphics/utils.py",
>
> line 255, in <module>
>      globals().update(__makeTextPathsCode__())
>                       ^^^^^^^^^^^^^^^^^^^^^^^
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/docs/userguide/reportlab/graphics/utils.py",
>
> line 253, in __makeTextPathsCode__
>      raise ImportError(f'Could not create text2PathDescription for using
> backends from {TP!a}')
> ImportError: Could not create text2PathDescription for using backends
> from ('freetype', '_renderPM')
>
> F......s.E.E...............EEEsEEs...........................................................................................................E......................................................................................................................ss..................................................E...............
> ======================================================================
> ERROR: test_graphics_barcode
> (test_graphics_barcode.BarcodeWidgetTestCase.test_graphics_barcode)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/tests/test_graphics_barcode.py",
>
> line 340, in test_graphics_barcode
>
> self.createSample('test_cbcim.png',createBarcodeImageInMemory('EAN13',
> value='123456789012'))
>
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/tests/reportlab/graphics/barcode/__init__.py",
>
> line 152, in createBarcodeImageInMemory
>      return d.asString(format)
>             ^^^^^^^^^^^^^^^^^^
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/tests/reportlab/graphics/shapes.py",
>
> line 806, in asString
>      from reportlab.graphics import renderPM
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/tests/reportlab/graphics/renderPM.py",
>
> line 20, in <module>
>      from .utils import setFont as _setFont, RenderPMError
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/tests/reportlab/graphics/utils.py",
>
> line 255, in <module>
>      globals().update(__makeTextPathsCode__())
>                       ^^^^^^^^^^^^^^^^^^^^^^^
>    File
> "/home/sagitter/rpmbuild/BUILD/reportlab-4.0.0/tests/reportlab/graphics/utils.py",
>
> line 253, in __makeTextPathsCode__
>      raise ImportError(f'Could not create text2PathDescription for using
> backends from {TP!a}')
> ImportError: Could not create text2PathDescription for using backends
> from ('freetype', '_renderPM')
>
> I send you the full log attached
>
> Regards.
> --
> ---
> Antonio Trande
> Fedora Project
> mailto: sagitter at fedoraproject.org
> GPG key: 0x40FDA7B70789A9CD
> GPG keys server: https://keyserver.dcc.sib.swiss/
> _______________________________________________
> reportlab-users mailing list
> reportlab-users at lists2.reportlab.com
> https://pairlist2.pair.net/mailman/listinfo/reportlab-users
>


-- 
-- 
jamespk at reportlab.com

ReportLab Europe Ltd.
Compton Road
Wimbletech - Zone 2
London SW19 7NB, UK
Tel. +44 20 8191 7277
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist2.pair.net/pipermail/reportlab-users/attachments/20230609/38b3cfb5/attachment.htm>


More information about the reportlab-users mailing list