Review of "Token Grill" version 1

Details Page Preview

Monitor AI usage across multiple accounts and providers from the GNOME top bar.

Extension Homepage
https://github.com/sh02sahil/token-grill

No comments.

FAQ

Files

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

Shexli (experimental) warning 5

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

  • extension.js:355
    file.load_contents(null)
  • extension.js:2213
    Gio12.File.new_for_path(path).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

  • extension.js:1962
    this._item = new PopupMenu.PopupBaseMenuItem({ reactive: false, can_focus: false, style_class: "tokengrill-popover-item" })
  • extension.js:1951
    this.cards = new PopupMenu.PopupMenuSection()

EGO-L-001 warning

extension must not create GObject instances or modify shell before enable()

Resource creation or signal/source setup was found outside `enable()`.

Only use initialization for static resources

  • extension.js:1437
    new CodexCollector()
  • extension.js:1438
    new ClaudeCollector()
  • extension.js:1439
    new KiroCollector()

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:1962
    this._item = new PopupMenu.PopupBaseMenuItem({ reactive: false, can_focus: false, style_class: "tokengrill-popover-item" })
  • extension.js:1951
    this.cards = new PopupMenu.PopupMenuSection()
  • extension.js:2253
    this.settings = extension.getSettings()

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:1761
    meter.connect("repaint", (area) => drawMeter(area, card.window?.percent ?? null, pressureColor(card.window)))
  • extension.js:1760
    root.connect("clicked", () => this._actions.selectWindow?.(this._instance, canonical))
  • extension.js:1780
        root.connect("clicked", () => {
          if (!root._available) return;
          root._expanded = !root._expanded;
          details.visible = root._expanded;
          chevron.rotation_angle_z = root._expanded ? 90 : 0;
        })
  • extension.js:1998
    settings.connect("clicked", () => this.controller.openPreferences())

All Versions

Version Status
1 Unreviewed