Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Task statuses and problems don't restore after reload #155246

Closed
meganrogge opened this issue Jul 14, 2022 · 7 comments · Fixed by #156699
Closed

Task statuses and problems don't restore after reload #155246

meganrogge opened this issue Jul 14, 2022 · 7 comments · Fixed by #156699
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders tasks Task system issues terminal-persistence Relating to process reconnection or process revive verified Verification succeeded
Milestone

Comments

@meganrogge
Copy link
Contributor

#155120 (comment)

@meganrogge meganrogge self-assigned this Jul 14, 2022
@meganrogge meganrogge added bug Issue identified by VS Code Team member as probable bug tasks Task system issues terminal-persistence Relating to process reconnection or process revive labels Jul 14, 2022
@meganrogge meganrogge added this to the July 2022 milestone Jul 14, 2022
@meganrogge
Copy link
Contributor Author

also reported here #155163

@meganrogge
Copy link
Contributor Author

happening bc there's no problem matcher on the configurationProperties

@meganrogge
Copy link
Contributor Author

actually, this is now working - I was just seeing the strange issue in which my VS Code build task doesn't work. @Tyriar could you pls confirm statuses work after reload for the VS Code build task in today's insider's?

status.mov

@Tyriar
Copy link
Member

Tyriar commented Jul 15, 2022

@meganrogge I see a spinners when I reload on Windows:

image

Probably also something that needs #152634

@meganrogge
Copy link
Contributor Author

yeah @Tyriar if you make a change and save, it'll update the status. before that wasn't happening, which is the bug I'd like help verifying is fixed. works for xterm.js for me

@meganrogge
Copy link
Contributor Author

actually I think it shouldn't be spinning on reload since we will know the status it should have initially. i'll investigate

@Tyriar
Copy link
Member

Tyriar commented Jul 21, 2022

This is a little hard to solve actually, note that active problems are also not restored. When reconnecting to the terminal we restore the buffer using initialText which doesn't end up firing onLineData. We also shouldn't be persisting the status on the pty host because consider the following:

  • Fail build, status syncs to pty host
  • Restart
  • Pass build during restart
  • We would restore the fail status here if we persisted to the pty host.

We handle the above problem for shell integration by running shell integration in parallel also on the pty host, we wouldn't want to do that with tasks as it would be too expensive and we also don't have the infrastructure set up for that.

I think the fix here should be similar to #152634, there should be some mechanism in tasks that allows scanning up to find certain patterns. For #152634 we want to scan up a few lines in the buffer and to re-evaluate endsPattern if possible, for this issue we want to scan up a reasonable amount on reconnect to find a beginsPattern and reparse that and all lines after to activate statuses and problem matchers.

I'm going to move this to August as the fix is a little too involved for me to tackle atm. It's a little annoying but it's also easily worked around (save a change).

@Tyriar Tyriar modified the milestones: July 2022, August 2022 Jul 21, 2022
@Tyriar Tyriar changed the title task statuses don't update after reload Task statuses and problems don't restore after reload Jul 21, 2022
@vscodenpa vscodenpa added unreleased Patch has not yet been released in VS Code Insiders insiders-released Patch has been released in VS Code Insiders and removed unreleased Patch has not yet been released in VS Code Insiders labels Aug 2, 2022
@connor4312 connor4312 added the verified Verification succeeded label Aug 25, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Sep 16, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders tasks Task system issues terminal-persistence Relating to process reconnection or process revive verified Verification succeeded
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants