Skip to content

Bug in v0.7.6 a494489: inconsistency of code-server terminal loading. #2845

Closed

Description

@sharkymark

Sometimes the integrated terminal in code-server loads, sometimes it does not.

This is a critical problem since I need to use the terminal to stay in flow, along with the editor. 2 other users have seen similar things including @bpmct and Phorcys (Discord handle)

I've tried clearing the browser cache, and it sometimes resolves. But it came back an hour later.

Expected Behavior

If I open a terminal in code-server, I should see a prompt.

Current Behavior

When I start a terminal, the sub-window appears, but just black and no prompt.

See DevTools errors.

image

Activity

  1. hfwang2020 commented on Jul 7, 2022

    @hfwang2020

    I have a similar problem

  2. sharkymark commented on Jul 7, 2022

    @sharkymark
    ContributorAuthor

    @hfwang2020 It is so weird. Today, for 30 minutes, I was able to see terminals across my workspaces. I am using caddy as a reverse proxy in front of GCP VM running Coder as a systemd service. But now it's back to no terminal.

    I am using the web terminal in the meantime, and if I have a JetBrains IDE in the same workspace, their terminal works fine.

  3. hfwang2020 commented on Jul 8, 2022

    @hfwang2020

    i also deploy the service in the vps and use nginx as reverse proxy.
    and when i run the Command 'Terminal: Create New Terminal'
    image

    i have tryed to reinstall it. but this proplem still exist. maybe i should deploy it in docker at the beginning...

  4. hfwang2020 commented on Jul 8, 2022

    @hfwang2020

    i also deploy the service in the vps and use nginx as reverse proxy. and when i run the Command 'Terminal: Create New Terminal' image

    i have tryed to reinstall it. but this proplem still exist. maybe i should deploy it in docker at the beginning...

    now i use another thinkpad which i connect the server first, it can open the terminal.

  5. self-assigned this
    on Jul 8, 2022
  6. kconley-sq commented on Jul 13, 2022

    @kconley-sq
    Contributor

    In versions prior to 0.7.6 I was able to eventually get the integrated terminal in code-server to appear (I think by refreshing the webpage a few times), but in 0.7.6 that workaround doesn't seem to work anymore, I can't get the terminal to ever appear.

    When I check the JS console I saw a few errors that looked relevant:

    Uncaught SyntaxError: Unexpected token '<' (at xterm.js:1:1)
    main.js:1 Uncaught SyntaxError: Unexpected token '<' (at main.js:1:1)
    main.js:1 Uncaught SyntaxError: Unexpected token '<' (at main.js:1:1)
    

    Maybe in my case this is due to how we're always installing the latest version of code-server in our agent startup script (following this example), and it seems like there may be an issue with the integrated terminal in the latest 4.5.0 version of Coder which I confirmed is what we're using:

    $ code-server --version
    4.5.0 02b9d7ee856e31d9008d1ff24a175ff03b49010e with Code 1.68.1
    

    I'll try using an older version of code-server and see if that gets us back to being able to open the terminal if we refresh the webpage enough times.

  7. kylecarbs commented on Jul 13, 2022

    @kylecarbs
    Member

    The issue you linked in code-server is the real issue. We're on it!

  8. jsjoeio commented on Jul 14, 2022

    @jsjoeio
    Contributor

    Update: we identified the issue in code-server and have merged a fix. We need to fix a few other things but hope to cut a release by next Friday. Then coder/coder can update the version of code-server and close this.

  9. jsjoeio commented on Jul 21, 2022

    @jsjoeio
    Contributor

    We released code-server 4.5.1 a couple days ago with the fix.

    Can someone confirm if this is still an issue?

  10. kylecarbs commented on Jul 21, 2022

    @kylecarbs
    Member

    This has been fixed! Update your code-server version y'all!

  11. jsjoeio commented on Aug 9, 2022

    @jsjoeio
    Contributor

    Hey all!

    Just wanted to follow up and let you know we've added a new e2e suite that runs code-server's tests (including one for the terminal) against a reverse proxy to prevent this kind of bug from happening again. See coder/code-server#5348

  12. ar06x commented on Aug 28, 2022

    @ar06x

    It appears that I am having this bug yet again.

  13. bpmct commented on Aug 29, 2022

    @bpmct
    Member

    Hi @Wolfy0615 - I am able to reproduce this as well. We are working on #2779 which should resolve these (now networking-related) issues in Coder.

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

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions