Bug 275729 - www/chromium: bad_optional_access.cc:39 Abort trap when headless
Summary: www/chromium: bad_optional_access.cc:39 Abort trap when headless
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-chromium (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-12-12 19:20 UTC by Paul Boehmer
Modified: 2024-01-27 21:09 UTC (History)
6 users (show)

See Also:
bugzilla: maintainer-feedback? (chromium)


Attachments
ICU fix for chromium 118.0.5993.117 on 14.0-R (484 bytes, patch)
2023-12-27 22:52 UTC, Jon Stuart
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Boehmer 2023-12-12 19:20:29 UTC
When running the command:

/usr/local/bin/chrome --headless --disable-gpu --run-all-compositor-stages-before-draw --print-to-pdf-no-header --print-to-pdf="/tmp/test.pdf" http://www.google.com[/code]

I receive the following error:

[26614:-1571897344:1212/141619.133891:ERROR:property_cache.cc(46)] Check failed: it->second.response.has_value(). 
[bad_optional_access.cc : 39] RAW: Bad optional access
Abort trap

Stripping off options other than "--headless" has no change.  I am able to replicate on multiple 13.2-Rel-p5/6/7 machines using both ports and packages.
Comment 1 SolarCatcher 2023-12-21 07:54:35 UTC
I confirm this for both, chromium and ungoogled-chromium. 

We have seen this for a while, and I pkg-locked version 117.0.5938.88 to keep a functioning version for the PDF generation. But this now blocks upgrading FreeBSD to 14.0-RELEASE.
Comment 2 Jon Stuart 2023-12-27 22:52:51 UTC
Created attachment 247304 [details]
ICU fix for chromium 118.0.5993.117 on 14.0-R

I was able to build 118.0.5993.117 on 14.0-RELEASE and a current ports tree with a small ICU-related patch I found over at Gentoo [1]. It's attached here reformatted for FreeBSD.

This version works --headless for me, and I can get back to scraping my API-shy power provider's stats :)

[1] https://bugs.gentoo.org/917645
Comment 3 Jon Stuart 2023-12-27 23:05:12 UTC
I should have included: this doesn't fix the --headless problem with the current version of www/chromium (120.0.6099.109 and at least 119.0.6045.199 too)
but rather allows 118.0.5993.117 to build, as resurrected from freebsd-ports.git with

git restore --source=4fd9620ae253e35362b65f411408fc3fc1eaccde www/chromium/

Running an old version of a browser isn't great, of course. Sadly I have no chops to address the real problem.