html-to-xlsx fails with "Browser.getVersion: Target closed" while PDF works



  • Hi,
    We have successfully resolved the AWS Lambda layer size issue by separating Chromium and jsReport into two different layers, and the setup is now deploying and running correctly.
    PDF generation using Chromium is working as expected. However, we are currently facing an issue specifically with the html-to-xlsx recipe.

    Issue Details:
    When executing the html-to-xlsx recipe, the Lambda function fails with the following error:
    Error: Protocol error (Browser.getVersion): Target closed

    This error occurs during Chromium initialization and causes the Lambda invocation to fail.

    Chromium Launch Configuration
    We are launching Chromium using @sparticuz/chromium with the configuration.

    Additional Notes

    • AWS Lambda runtime: Node.js with 24.x runtime
    • Chromium is provided via a separate Lambda layer. Memory size: 1024 MB
    • PDF recipes work fine with the same Chromium setup
    • The issue only occurs with the html-to-xlsx recipe
    • We are using @sparticuz/chromium version 143.0.0.

    Could you please help with this?



  • Thank you for reporting the problem.
    I was able to isolate the issue. The latest Chromium interprets one of the configurations we use differently, which breaks the limited AWS Lambda runtime. We will try to reimplement the approach. Hopefully, it will be part of the next release. However, we still need to analyze the new approach, so no promises yet.

    Here is the bug to track
    https://github.com/jsreport/jsreport/issues/1271



  • Hi Jan,
    Thank you for the update and for isolating the issue—appreciate you sharing the details around the Chromium behavior and the AWS Lambda limitations.
    Understood that the approach is being reimplemented and that further analysis is still ongoing. To help us plan our rollout and dependency upgrades on our side, could you please let us know if there is a tentative target timeline or expected window for the next jsreport release that may include this fix?

    Thanks again for your continued support. Looking forward to your guidance.



  • Hi,

    The fix is already in the master branch. I expect the release to happen within the next two weeks.

    However, you can easily already apply the fix manually, it is just one line change
    https://github.com/jsreport/jsreport/commit/b7c97212ca1bb7eba65475cdab7432e6fec4996f


Log in to reply
 

Looks like your connection to jsreport forum was lost, please wait while we try to reconnect.