Extension ignores expired token and fails in the wrong place
Original title: (Open Active File on GitLab fails with Cannot read property 'webUrl' of null)
Checklist
-
I'm using the latest version of the extension 3.34.0 (see the latest version in the right column of this page) - Extension version: Put your extension version here
-
I'm using the latest VS Code version (find the latest version here) - VS Code version: Version: 1.61.2 Commit: 6cba118ac49a1b88332f312a8f67186f7f3c1643 Date: 2021-10-19T15:49:28.381Z Electron: 13.5.1 Chrome: 91.0.4472.164 Node.js: 14.16.0 V8: 9.1.269.39-electron.0 OS: Darwin x64 20.6.0
-
I'm using a supported version of GitLab (see README for the supported version) - GitLab version: 14.4.0-ee
Summary
When I use the "Open Active File on GitLab" fails with Cannot read property 'webUrl' of null
Steps to reproduce
Use an expired token to set up the extension.
Open any file and execute the "Open Active File on GitLab" command.
What is the current bug behavior?
Nothing happens. No error, no browser window opened.
Before I updated it used to give this error:
Cannot read property 'webUrl' of null
TypeError: Cannot read property 'webUrl' of null
at getActiveFile (/Users/myusername/.vscode/extensions/gitlab.gitlab-workflow-3.33.0/out/src/openers.js:91:39)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
at async openActiveFile (/Users/myusername/.vscode/extensions/gitlab.gitlab-workflow-3.33.0/out/src/openers.js:103:33)
at async /Users/myusername/.vscode/extensions/gitlab.gitlab-workflow-3.33.0/out/src/extension.js:36:9
at async _executeContributedCommand (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/services/extensions/node/extensionHostProcess.js:94:110871)
What is the expected correct behavior?
It should open a browser window with the file I selected.
Relevant logs and/or screenshots
It looks like my logs are empty.
Edited by Tomas Vik (OOO back on 2025-01-02)