Review of "Novus DayNight" version 2

Details Page Preview

Automatically switches GTK themes, color scheme, wallpapers, Night Light, and display brightness based on local sunrise/sunset times or a custom schedule. Optional location auto-detection uses GeoClue2 with fallback to ipinfo.io and nominatim.openstreetmap.org. Based on Automatic Theme Switcher by Amritashan S. Lal.

Extension Homepage
https://github.com/SGC-NOVUS/novus-daynight

No comments.

Diff Against

Files

Note: Binary files aren't shown on the web site. To see all files, please download the extension zipfile.

Shexli (experimental) warning 3

Shexli found 3 issues that may need reviewer attention.

EGO-X-004 warning

extensions should avoid synchronous file IO in shell code

Shell code should avoid synchronous file IO APIs like `GLib.file_get_contents()` and `Gio.File.load_contents()`.

File Operations

  • themeUtils.js:224
    dir.get_child(fileName).load_contents(null)

EGO-L-002 warning

objects created by extension should be destroyed in disable()

Objects assigned in `enable()` are missing matching `.destroy()` calls in `disable()` or its helper methods.

Destroy all objects

  • quickSettingsIndicator.js:26
            this._autoItem = new PopupMenu.PopupImageMenuItem(
                _('Automatic Schedule'),
                'emblem-synchronizing-symbolic'
            )
  • quickSettingsIndicator.js:40
            this._darkItem = new PopupMenu.PopupImageMenuItem(
                _('Night Mode (Dark)'),
                'weather-clear-night-symbolic'
            )
  • quickSettingsIndicator.js:33
            this._lightItem = new PopupMenu.PopupImageMenuItem(
                _('Day Mode (Light)'),
                'weather-clear-symbolic'
            )
  • quickSettingsIndicator.js:49
            this._prefsItem = new PopupMenu.PopupImageMenuItem(
                _('DayNight Settings…'),
                'preferences-system-symbolic'
            )

EGO-L-005 warning

owned object references should be released in disable()

Owned references that are cleaned up in `disable()` should also be released with `null` or `undefined`.

Destroy all objects

  • quickSettingsIndicator.js:26
            this._autoItem = new PopupMenu.PopupImageMenuItem(
                _('Automatic Schedule'),
                'emblem-synchronizing-symbolic'
            )
  • quickSettingsIndicator.js:40
            this._darkItem = new PopupMenu.PopupImageMenuItem(
                _('Night Mode (Dark)'),
                'weather-clear-night-symbolic'
            )
  • quickSettingsIndicator.js:33
            this._lightItem = new PopupMenu.PopupImageMenuItem(
                _('Day Mode (Light)'),
                'weather-clear-symbolic'
            )
  • quickSettingsIndicator.js:49
            this._prefsItem = new PopupMenu.PopupImageMenuItem(
                _('DayNight Settings…'),
                'preferences-system-symbolic'
            )

All Versions

Version Status
2 Unreviewed
1 Rejected