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

Fix on gnome 42 #23

Closed
wants to merge 16 commits into from
Closed

Fix on gnome 42 #23

wants to merge 16 commits into from

Conversation

Matr1x-101
Copy link

See nvlgit#1 for more details. I did this pull request as there are too many forks and I wanted to clean it up :).

TheDoctorRAB and others added 16 commits January 5, 2021 12:44
Date.prototype.toLocaleFormat  is no longer available in gjs.
Code from https://gitlab.gnome.org/GNOME/gnome-shell/-/blob/master/js/ui/environment.js
I noticed that a warning & error were shown from `journalctl -f -o cat /usr/bin/gnome-shell`:

```
Some code accessed the property 'Class' on the module 'Settings'. That property was defined with 'let' or 'const' inside the module. This was previously supported, but is not correct according to the ES6 standard. Any symbols to be exported from a module must be defined with 'var'. The property access will work as previously for the time being, but please fix your code anyway.
JS ERROR: Extension [email protected]: TypeError: extension.imports.Settings.Class is not a constructor
@/home/brendan/.local/share/gnome-shell/extensions/[email protected]/extension.js:10:18
_callExtensionInit@resource:///org/gnome/shell/ui/extensionSystem.js:435:13
loadExtension@resource:///org/gnome/shell/ui/extensionSystem.js:360:27
_loadExtensions/<@resource:///org/gnome/shell/ui/extensionSystem.js:611:18
collectFromDatadirs@resource:///org/gnome/shell/misc/fileUtils.js:27:28
_loadExtensions@resource:///org/gnome/shell/ui/extensionSystem.js:590:19
_enableAllExtensions@resource:///org/gnome/shell/ui/extensionSystem.js:617:18
_sessionUpdated@resource:///org/gnome/shell/ui/extensionSystem.js:637:14
init@resource:///org/gnome/shell/ui/extensionSystem.js:55:14
_initializeUI@resource:///org/gnome/shell/ui/main.js:288:22
start@resource:///org/gnome/shell/ui/main.js:165:5
@resource:///org/gnome/shell/ui/init.js:6:17
```
Warning:

```
Some code accessed the property 'defaultFormat' on the module 'DateMenuDate'. That property was defined with 'let' or 'const' inside the module. This was previously supported, but is not correct according to the ES6 standard. Any symbols to be exported from a module must be defined with 'var'. The property access will work as previously for the time being, but please fix your code anyway.
```
```
JS ERROR: TypeError: Object is of type Gtk.Box - cannot convert to GtkWindow
Class/this.showWindow@/home/brendan/.local/share/gnome-shell/extensions/[email protected]/EditWindow.js:111:10
create/<@/home/brendan/.local/share/gnome-shell/extensions/[email protected]/FormatTarget.js:59:14
run@resource:///org/gnome/Shell/Extensions/js/dbusService.js:186:20
main@resource:///org/gnome/Shell/Extensions/js/main.js:21:13
run@resource:///org/gnome/gjs/modules/script/package.js:206:19
start@resource:///org/gnome/gjs/modules/script/package.js:190:8
@/usr/share/gnome-shell/org.gnome.Shell.Extensions:1:17
Caused by: Error: This JS object wrapper isn't wrapping a GObject. If this is a custom subclass, are you sure you chained up to the parent _init properly?
```
```
JS WARNING: [/home/brendan/.local/share/gnome-shell/extensions/[email protected]/FormatTarget.js 62]: Too many arguments to method Gtk.Box.append: expected 1, got 4
```
```
Some code accessed the property 'name' on the module 'DateMenuDate'. That property was defined with 'let' or 'const' inside the module. This was previously supported, but is not correct according to the ES6 standard. Any symbols to be exported from a module must be defined with 'var'. The property access will work as previously for the time being, but please fix your code anyway.
Some code accessed the property 'name' on the module 'DateMenuDay'. That property was defined with 'let' or 'const' inside the module. This was previously supported, but is not correct according to the ES6 standard. Any symbols to be exported from a module must be defined with 'var'. The property access will work as previously for the time being, but please fix your code anyway.
Some code accessed the property 'name' on the module 'StatusBar'. That property was defined with 'let' or 'const' inside the module. This was previously supported, but is not correct according to the ES6 standard. Any symbols to be exported from a module must be defined with 'var'. The property access will work as previously for the time being, but please fix your code anyway.
```
```
Some code called array.toString() on a Uint8Array instance. Previously this would have interpreted the bytes of the array as a string, but that is nonstandard. In the future this will return the bytes as comma-separated digits. For the time being, the old behavior has been preserved, but please fix your code anyway to explicitly call ByteArray.toString(array).
(Note that array.toString() may have been called implicitly.)
0 readFile() ["/home/brendan/.local/share/gnome-shell/extensions/[email protected]/prefs.js":86:8]
1 buildPrefsWidget() ["/home/brendan/.local/share/gnome-shell/extensions/[email protected]/prefs.js":102:27]
2 _init() ["resource:///org/gnome/Shell/Extensions/js/extensionPrefsDialog.js":32:43]
3 ExtensionPrefsDialog() ["resource:///org/gnome/Shell/Extensions/js/extensionPrefsDialog.js":10:3]
4 OpenExtensionPrefsAsync/<() ["resource:///org/gnome/Shell/Extensions/js/extensionsService.js":129:32]
5 asyncCallback() ["resource:///org/gnome/gjs/modules/core/overrides/Gio.js":115:21]
6 run() ["resource:///org/gnome/Shell/Extensions/js/dbusService.js":186:19]
7 main() ["resource:///org/gnome/Shell/Extensions/js/main.js":21:12]
8 run() ["resource:///org/gnome/gjs/modules/script/package.js":206:18]
9 start() ["resource:///org/gnome/gjs/modules/script/package.js":190:7]
10 <TOP LEVEL> ["/usr/share/gnome-shell/org.gnome.Shell.Extensions":1:16]
```

https://github.com/GNOME/gjs/blob/master/doc/ByteArray.md
```
Some code accessed the property 'create' on the module 'FormatTarget'. That property was defined with 'let' or 'const' inside the module. This was previously supported, but is not correct according to the ES6 standard. Any symbols to be exported from a module must be defined with 'var'. The property access will work as previously for the time being, but please fix your code anyway.
JS ERROR: Failed to open preferences: TypeError: extension.imports.FormatTarget.create is not a function
buildPrefsWidget/<@/home/brendan/.local/share/gnome-shell/extensions/[email protected]/prefs.js:142:107
buildPrefsWidget@/home/brendan/.local/share/gnome-shell/extensions/[email protected]/prefs.js:142:50
_init@resource:///org/gnome/Shell/Extensions/js/extensionPrefsDialog.js:32:44
ExtensionPrefsDialog@resource:///org/gnome/Shell/Extensions/js/extensionPrefsDialog.js:10:4
OpenExtensionPrefsAsync/<@resource:///org/gnome/Shell/Extensions/js/extensionsService.js:129:33
asyncCallback@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:115:22
run@resource:///org/gnome/Shell/Extensions/js/dbusService.js:186:20
main@resource:///org/gnome/Shell/Extensions/js/main.js:21:13
run@resource:///org/gnome/gjs/modules/script/package.js:206:19
start@resource:///org/gnome/gjs/modules/script/package.js:190:8
@/usr/share/gnome-shell/org.gnome.Shell.Extensions:1:17
JS ERROR: TypeError: prefsWindow is null
buildPrefsWidget/<@/home/brendan/.local/share/gnome-shell/extensions/[email protected]/prefs.js:109:3
run@resource:///org/gnome/Shell/Extensions/js/dbusService.js:186:20
main@resource:///org/gnome/Shell/Extensions/js/main.js:21:13
run@resource:///org/gnome/gjs/modules/script/package.js:206:19
start@resource:///org/gnome/gjs/modules/script/package.js:190:8
@/usr/share/gnome-shell/org.gnome.Shell.Extensions:1:17
```
@ZimbiX ZimbiX closed this by deleting the head repository Dec 28, 2022
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.

4 participants