Skip to content
New issue

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

Fedora 39 javascript error #72

Closed
RobusTetus opened this issue Nov 7, 2023 · 2 comments
Closed

Fedora 39 javascript error #72

RobusTetus opened this issue Nov 7, 2023 · 2 comments

Comments

@RobusTetus
Copy link

Upon turning on the extension through the GNOME Extensions app, error message shows up reading "import declarations may only appear at top level of a module".

The settings of extension gamemode@christian.kellner.me had an error:

SyntaxError: import declarations may only appear at top level of a module

Stack trace:

@file:///usr/share/gnome-shell/extensions/gamemode@christian.kellner.me/prefs.js:1:24
_init/GLib.MainLoop.prototype.runAsync/</<@resource:///org/gnome/gjs/modules/core/overrides/GLib.js:266:34
@fjsevilla-dev
Copy link
Collaborator

fjsevilla-dev commented Nov 8, 2023

Hi @RobusTetus, Fedora 39 uses GNOME 45 which has brought important changes regarding extensions, the main one being that GNOME Shell 45 moved to ESM (which is the reason for the error you mention).

The version available in extensions.gnome.org is not compatible with Gnome 45, and, unlike previous versions, adding the new version to metadata.json or disabling compatibility checking is not enough. To make the extension compatible with GNOME 45 we have to make code changes that break backwards compatibility.

There is an open issue about this topic; GNOME 45 support. If you want to use the extension on Fedora 39, you can build from source and install the port to GNOME 45 in my fork, until Gicmo can update the extension to a newer version. See my comment on this issue to see how to do it.

If you have any problems let me know.

@fjsevilla-dev
Copy link
Collaborator

Duplicate of #70

@fjsevilla-dev fjsevilla-dev marked this as a duplicate of #70 Nov 8, 2023
@fjsevilla-dev fjsevilla-dev closed this as not planned Won't fix, can't repro, duplicate, stale Nov 8, 2023
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

No branches or pull requests

2 participants