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

Duplicates #48

Closed
VanClement1 opened this issue Aug 15, 2023 · 12 comments
Closed

Duplicates #48

VanClement1 opened this issue Aug 15, 2023 · 12 comments
Labels
bug Something isn't working

Comments

@VanClement1
Copy link

Is there any way to not have it populate duplicates? Sometimes VSCode will remember terminals that were open if it was the last workspace to be used. It would be nice if your extension could check to see if the terminal name already exists before it tries to open it again.

@lonix1
Copy link

lonix1 commented Aug 19, 2023

New user here. Agreed. This is driving me crazy...

And this extension is really clever - even when I close those terminals, it detects that they are closed and reopens them faster than I can close them again! Funny.

@jscheffner
Copy link
Owner

Hey, thanks for reporting, I didn't experience this myself yet. When I find the time I will work on a fix.

@jscheffner jscheffner added the bug Something isn't working label Sep 11, 2023
@jscheffner
Copy link
Owner

@VanClement1 Can you please share the steps to reproduce this? For me this isn't happening and the extension is already checking existing terminals before opening them.

@lonix1
Copy link

lonix1 commented Nov 16, 2023

I don't experience this anymore - either the extension has been updated or vscode has been updated in some way.

@VanClement1
Copy link
Author

It is just that sometimes when I open a window or workspace from the recent vscode list, it keeps the terminals that were open previously and populates them again

@aeb-dev
Copy link

aeb-dev commented Jan 26, 2024

We are having the same problem. Sometimes it just re-creates the terminals with the same names.

@VanClement1
Copy link
Author

We are having the same problem. Sometimes it just re-creates the terminals with the same names.

Yeah, I can't find a way to re-create the bug reliably. It just seems to happen when it wants to. I usually always open from the recents list if that makes any difference

@jscheffner
Copy link
Owner

The extension is already checking if the terminal exists before it creates a new one. So if this sometimes doesn't work it's probably because vscode creates the terminals after the extension does.

Unfortunately it's a bit hard to debug because I can't reproduce it.

@aeb-dev
Copy link

aeb-dev commented Jan 26, 2024

It is probably something like that. Would it possible to delay the creation of terminals maybe? It might be a stupid idea I have no idea how extensions run

@jscheffner
Copy link
Owner

I am able to reproduce it now by running > Developer: Reload Window

Yes, delaying it might help but I'll also think about alternative solutions. It's also nice if the terminals are created fast.

@jscheffner
Copy link
Owner

I finally found some time to look into it and I think I fixed it. I changed the activation event of the extension and it should now only activate after the startup of vscode finished. This is anyway better for the performance of vscode.

I did not publish the fix yet, I want to try it out and see if the extension still behaves properly. I will publish it in the next days.

@jscheffner
Copy link
Owner

I just released the fix. Please check if it really fixed the issue for you, for me it did.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants