Skip to content

cockpit: Work around Firefox bug re reloading iframes when navigating#22912

Merged
mvollmer merged 1 commit intocockpit-project:mainfrom
mvollmer:firefox-iframe-reloads
Feb 24, 2026
Merged

cockpit: Work around Firefox bug re reloading iframes when navigating#22912
mvollmer merged 1 commit intocockpit-project:mainfrom
mvollmer:firefox-iframe-reloads

Conversation

@mvollmer
Copy link
Member

No description provided.

// See https://bugzilla.redhat.com/show_bug.cgi?id=2422331
//
if (window.location.hash != hash)
if (navigator.userAgent.includes("Firefox")) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This added line is not executed by any test. Details

Comment on lines +175 to +179
const a = document.createElement('a');
a.href = hash;
document.body.appendChild(a);
a.click();
document.body.removeChild(a);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These 5 added lines are not executed by any test. Details

@mvollmer mvollmer requested a review from martinpitt February 23, 2026 13:24
@mvollmer
Copy link
Member Author

The rhel-8-10/ws-container failures are unrelated.

@mvollmer
Copy link
Member Author

We should have a test that fails without this workaround...

@mvollmer
Copy link
Member Author

We should have a test that fails without this workaround...

We have: At least TestMachinesCreate.testConfigureBeforeInstall fails with Firefiox 147, as expected. Our CI uses Firefox Nightly, which is currently 149, and which seems to have fixed that bug. (I was confused and thought 148 has it fixed.)

@mvollmer
Copy link
Member Author

So, since Firefox 149 has this fixed and will be released on March 24th, should we just sit this out?

Copy link
Member

@martinpitt martinpitt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Indeed we won't get the workaroud into distros that much faster than March 21 (and especially not into RHEL), but if it does help somebody, this looks acceptable to me.

@mvollmer mvollmer merged commit 373846f into cockpit-project:main Feb 24, 2026
85 of 92 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants