Review of "system-monitor-next" version 82

Details Page Preview

Display system information in GNOME Shell status bar, such as memory, CPU, disk and battery usages, network rates… Please see the extension homepage for prerequisite packages that must be installed first. If you get an error after updating, try restarting GNOME Shell or logging out and logging back in.

Extension Homepage
https://github.com/mgalgs/gnome-shell-system-monitor-next-applet

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) error 1 warning 5

Shexli found 6 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

  • common.js:22
    file.load_contents(null)
  • extension.js:1910
    Gio.File.new_for_path('/proc/net/dev').load_contents(null)
  • extension.js:1915
    Gio.File.new_for_path(
                                '/sys/class/net/' + ifc + '/operstate').load_contents(null)

EGO-A-004 warning

extension files should not contain excessive ungated console logging

File contains 6 ungated console.log/warn/error calls (threshold: 5).

No excessive logging

  • extension.js:1406
    console.error(e)
  • extension.js:1568
    console.error(e)
  • extension.js:1940
    console.error('Please install Network Manager Gobject Introspection Bindings: ' + e)
  • extension.js:1957
    console.error('Please install Network Manager Gobject Introspection Bindings')
  • extension.js:2396
    console.error(err.message)
  • extension.js:2404
    console.error('gpu_usage.sh invocation failed')

EGO-P-003 error

GSettings schema XML must be present in package

Extension appears to use GSettings but no `.gschema.xml` file is included in the package.

GSettings Schemas

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

  • extension.js:290
    this.actor = new St.DrawingArea({style_class: extension._Style.get('sm-chart'), reactive: false})
  • extension.js:534
    this.actor = new St.DrawingArea({style_class: this.extension._Style.get('sm-chart'), reactive: false})
  • extension.js:715
    this.actor = new Clutter.Actor()
  • extension.js:968
            this.label = new St.Label({text: _(this.elt_short || this.elt),
                style_class: Style.get('sm-status-label')})
  • extension.js:976
    this.label_bin = new St.Bin({child: this.label})
  • extension.js:995
    this.text_box = new St.BoxLayout()
  • extension.js:2520
            this.actor = new St.Icon({
                icon_name: 'org.gnome.SystemMonitor-symbolic',
                style_class: 'system-status-icon'
            })

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

  • extension.js:2614
    this._Schema = this.getSettings()
  • extension.js:290
    this.actor = new St.DrawingArea({style_class: extension._Style.get('sm-chart'), reactive: false})
  • extension.js:534
    this.actor = new St.DrawingArea({style_class: this.extension._Style.get('sm-chart'), reactive: false})
  • extension.js:715
    this.actor = new Clutter.Actor()
  • extension.js:785
    this.actor = new St.BoxLayout({reactive: true})
  • extension.js:968
            this.label = new St.Label({text: _(this.elt_short || this.elt),
                style_class: Style.get('sm-status-label')})
  • extension.js:976
    this.label_bin = new St.Bin({child: this.label})
  • extension.js:995
    this.text_box = new St.BoxLayout()
  • extension.js:2520
            this.actor = new St.Icon({
                icon_name: 'org.gnome.SystemMonitor-symbolic',
                style_class: 'system-status-icon'
            })

EGO-L-003 warning

signals connected by extension should be disconnected in disable()

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

Disconnect all signals

  • extension.js:2631
    this._MountsMonitor.connect()
  • extension.js:2668
            this._Schema.connect('changed::background', (schema, key) => {
                this._Background = color_from_string(this._Schema.get_string(key));
            })
  • extension.js:2709
    this._Schema.connect('changed::disk-usage-style', change_usage)
  • extension.js:2713
            tray.menu.connect(
                'open-state-changed',
                (menu, isOpen) => {
                    if (isOpen) {
                        this.__sm.pie.actor.queue_repaint();
    
                        this.menuTimeout = GLib.timeout_add_seconds(
                            GLib.PRIORITY_DEFAULT,
           
  • extension.js:302
    this.actor.connect('repaint', this._draw.bind(this))
  • extension.js:301
    themeContext.connect('notify::scale-factor', this.rescale.bind(this))
  • extension.js:557
    this.actor.connect('repaint', this._draw.bind(this))
  • extension.js:549
    interfaceSettings.connect('changed', this.set_text_scaling.bind(this))
  • extension.js:544
    themeContext.connect('notify::scale-factor', this.set_scale.bind(this))
  • extension.js:789
    this.actor.connect('enter-event', this.on_enter.bind(this))
  • extension.js:790
    this.actor.connect('leave-event', this.on_leave.bind(this))
  • extension.js:1004
    Schema.connect('changed::' + this.elt + '-style', change_style.bind(this))
  • extension.js:926
                Schema.connect('changed::' + name, (schema, key) => {
                    this.clutterColor = color_from_string(Schema.get_string(key));
                })
  • extension.js:929
                Schema.connect('changed::' + name, () => {
                    this.chart.actor.queue_repaint();
                })
  • extension.js:946
            Schema.connect(
                'changed::' + this.elt + '-display', (schema, key) => {
                    this.actor.visible = Schema.get_boolean(key);
                })
  • extension.js:953
            Schema.connect(
                'changed::' + this.elt + '-refresh-time',
                (schema, key) => {
                    this.restart_update_timer(l_limit(Schema.get_int(key)));
                })
  • extension.js:958
    Schema.connect('changed::' + this.elt + '-graph-width', this.resize.bind(this))
  • extension.js:971
    Schema.connect('changed::' + this.elt + '-show-text', change_text.bind(this))
  • extension.js:974
    Schema.connect('changed::' + this.elt + '-show-menu', change_menu.bind(this))
  • extension.js:941
            Schema.connect('changed::background', () => {
                this.chart.actor.queue_repaint();
            })
  • extension.js:1008
            Schema.connect('changed::graph-cooldown-delay-m', () => {
                this.restart_cooldown_timer();
            })
  • extension.js:992
    Schema.connect('changed::rotate-labels', change_rotate_labels)
  • extension.js:961
                Schema.connect('changed::thermal-threshold',
                    () => {
                        this.reset_style();
                        this.restart_update_timer();
                    })
  • extension.js:1160
    extension._Schema.connect('changed::' + this.elt + '-time', this.update_tips.bind(this))
  • extension.js:1710
    extension._Schema.connect('changed::freq-display-mode', this.update.bind(this))
  • extension.js:1932
    this.extension._Schema.connect('changed::' + this.elt + '-speed-in-bits', this.update_units.bind(this))
  • extension.js:2230
    extension._Schema.connect('changed::' + this.elt + '-sensor-label', this.refresh.bind(this))
  • extension.js:2305
    extension._Schema.connect('changed::' + this.elt + '-sensor-label', this.refresh.bind(this))
  • extension.js:2525
            this.extension._Schema.connect(
                'changed::icon-display',
                () => {
                    this.actor.visible = this.extension._Schema.get_boolean('icon-display');
                }
            )

All Versions