Skip to content

Display quota errors in VS Code extension #117

Closed

Description

@bpmct

This is what I see instead

Screenshot 2023-07-21 at 12 22 11 PM

The quotas error:

Screenshot 2023-07-21 at 12 22 27 PM

Activity

  1. matifali commented on Dec 16, 2024

    @matifali
    Contributor

    @code-asher we already stream build logs from terarform to VSCode. I wonder how the Commit quota information is being displayed. Do we need changes in coder/coder to support this?

  2. code-asher commented on Dec 17, 2024

    @code-asher
    Member

    We recently made a change to use the cli to start the workspace and display the stderr if it fails, so it is possible this will actually show up in the error now.

    I think it could also make sense to have the ability to review the build log on error. Right now we immediately close it on error so it is not possible to review it to see what might have gone wrong.

  3. matifali commented on Dec 18, 2024

    @matifali
    Contributor

    So we can instead parse the error log for any errors and show them via extension. We can do it along with coder/coder#15447

  4. code-asher commented on Dec 18, 2024

    @code-asher
    Member

    Here is what it looks like now:

    error: insufficient quota

  5. matifali commented on Dec 19, 2024

    @matifali
    Contributor

    This is nice that we have it already. Can we make this error more notable by highlighting the Quota issue instead of "Failed to Open Workspace"?

  6. code-asher commented on Dec 20, 2024

    @code-asher
    Member

    Part of me prefers the way it is now, because the action it tried to do was open the workspace, and the message then describes why that action failed.

    But, if we feel this is obscuring the error and moving the stderr above is better, then that seems reasonable enough to me. Do note though that stderr could be anything though, it could be about quotas or anything else, and a dynamic title also feels a little weird to me.

  7. code-asher commented on Dec 20, 2024

    @code-asher
    Member

    It also seems unfortunate that we display the "run coder start --help" part when the user has no way to actually do that. I wonder if the cli needs a kind of "plugin" mode that displays different error messages when running as part of a plugin (and maybe it would output in json instead as well, so we could parse and use the errors however we want, instead of dealing with arbitrary text, maybe the flag could be --json).

  8. matifali commented on Dec 21, 2024

    @matifali
    Contributor

    Yeah. IMO we should only show coder<subcommand> --help if the command or argument is not valid and otherwise just print the error message.
    We can move the discussion to coder/coder.

    Also we can close this issue as resolved because we do show the error message now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions