We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug Crash when generating PDF/A using pdf 3.11.3
To Reproduce Code snippet to reproduce the behavior:
Future<Uint8List> loadColorProfile() async { try { ByteData data = await rootBundle.load('assets/pdfColorProfiles/sRGB2014.icc'); return data.buffer.asUint8List(); } catch (e) { debugPrint('Error loading asset: $e'); return Uint8List(0); } } Future<Uint8List> generatePdf( [PdfPageFormat format = PdfPageFormat.a4]) async { final pdf = pw.Document( version: PdfVersion.pdf_1_5, compress: true, metadata: PdfaRdf( invoiceRdf: PdfaFacturxRdf().create(), ).create(), ); PdfaColorProfile(pdf.document, await loadColorProfile()); PdfaAttachedFiles( pdf.document, { 'factur-x.xml': '<test></test>', }, ); return pdf.save(); ) await generatePdf(); // EXCEPTION debugPrint('Never reached... Exception on previous line');
Exception doesn't occur if I remove:
PdfaAttachedFiles( pdf.document, { 'factur-x.xml': '<test></test>', }, );
ERROR
Expected behavior Should not crash
Screenshots
Flutter Doctor
[✓] Flutter (Channel stable, 3.24.3, on macOS 14.7.3 23H417 darwin-arm64, locale en) [✓] Android toolchain - develop for Android devices (Android SDK version 35.0.0) [✓] Xcode - develop for iOS and macOS (Xcode 16.2) [✓] Chrome - develop for the web [✓] Android Studio (version 2024.2) [✓] VS Code (version 1.97.0) [✓] Connected device (4 available) [✓] Network resources
Desktop (please complete the following information):
Smartphone (please complete the following information):
The text was updated successfully, but these errors were encountered:
@ilaurillard
Sorry, something went wrong.
see #1820
Thanks @ilaurillard. I confirm the pull request fixes the bug!
No branches or pull requests
Describe the bug
Crash when generating PDF/A using pdf 3.11.3
To Reproduce
Code snippet to reproduce the behavior:
Exception doesn't occur if I remove:
ERROR
Expected behavior
Should not crash
Screenshots
Flutter Doctor
Desktop (please complete the following information):
Smartphone (please complete the following information):
The text was updated successfully, but these errors were encountered: