Review of "YouTube BGM" version 1

Details Page Preview

YouTube background music / playlists from Quick Settings (mpv + yt-dlp).

Extension Homepage
https://github.com/shie1/youtube-bgm

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 4 manual_review 1

Shexli found 5 issues that may need reviewer attention.

EGO-A-005 manual_review

extensions should not access the clipboard directly

Direct clipboard access via `St.Clipboard.get_default()` requires reviewer scrutiny.

Review Guidelines

  • extension.js:424
    St.Clipboard.get_default()

EGO-P-006 warning

unnecessary build and translation artifacts should not be shipped

Package contains files that often should not be shipped for review.

Don't include unnecessary files

  • .gitignore
    .gitignore
  • Makefile
    Makefile

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:220
    this._sliderHandlerId = this._volSlider.connect('notify::value', this._onVolSliderChanged)
  • extension.js:263
            this._settings.connect('changed::playlist-url', () => {
                this._urlRow.setUrl(this._settings.get_string('playlist-url'));
                if (!this.checked)
                    return;
                if (this._starting) {
                    this._pendingPlaylistReload = true;
                    ret
  • extension.js:234
            this._settings.connect('changed::volume', () => {
                if (this._volSliderDragging)
                    return;
                const v = this._settings.get_uint('volume') / 100.0;
                GObject.signal_handler_block(this._volSlider, this._sliderHandlerId);
                this._volSlider.va
  • extension.js:294
            dialog.connect('closed', () => {
                if (this._historyDialog === dialog)
                    this._historyDialog = null;
            })
  • extension.js:187
            this.menu.connect('open-state-changed', (menu, isOpen) => {
                if (isOpen)
                    this._syncNextButtonVisibility();
                if (!isOpen) {
                    this._urlRow.flush();
                    this._schedulePlaylistReload(0);
                }
            })

EGO-L-004 warning

main loop sources should be removed in disable()

Main loop sources assigned in `enable()` are missing matching removals in `disable()` or its helper methods.

Remove main loop sources

  • extension.js:432
                this._urlReloadDebounce = GLib.idle_add(GLib.PRIORITY_DEFAULT, () => {
                    this._urlReloadDebounce = 0;
                    this._reloadPlaylistIfUrlChanged().catch(e => logError(e, 'YouTube BGM playlist reload'));
                    return GLib.SOURCE_REMOVE;
                })
  • extension.js:214
                this._volumePersistId = GLib.timeout_add(GLib.PRIORITY_DEFAULT, 50, () => {
                    this._volumePersistId = 0;
                    this._settings.set_uint('volume', v);
                    return GLib.SOURCE_REMOVE;
                })
  • extension.js:480
                        GLib.idle_add(GLib.PRIORITY_DEFAULT, () => {
                            this._schedulePlaylistReload(0);
                            return GLib.SOURCE_REMOVE;
                        })

EGO-L-007 warning

main loop sources should be removed before being recreated

Main loop sources should be removed before creating a new source on the same field.

Remove main loop sources

  • extension.js:440
            this._urlReloadDebounce = GLib.timeout_add(GLib.PRIORITY_DEFAULT, d, () => {
                this._urlReloadDebounce = 0;
                this._reloadPlaylistIfUrlChanged().catch(e => logError(e, 'YouTube BGM playlist reload'));
                return GLib.SOURCE_REMOVE;
            })

All Versions

Version Status
1 Unreviewed