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

Add mechanisms to create a session from any registered runtime #6308

Open
12 tasks
dhruvisompura opened this issue Feb 11, 2025 · 0 comments
Open
12 tasks

Add mechanisms to create a session from any registered runtime #6308

dhruvisompura opened this issue Feb 11, 2025 · 0 comments
Assignees
Labels
area: console Issues related to Console category. area: ui Issues related to UI category. enhancement New feature or request

Comments

@dhruvisompura
Copy link
Contributor

dhruvisompura commented Feb 11, 2025

We'll need to make the following changes to the services:

  • Tweak runtimeSessionService to check all active sessions:
    - getConsoleSessionForRuntime: Return the active session for the provided runtime id, if one exists
    - getConsoleSessionForLanguage: Return the active session for the specified language id, if one exists
  • positronConsoleService
  • positronConsoleInstance

See docs for implementation details for panel views: https://code.visualstudio.com/docs/getstarted/getting-started#_access-the-terminal-from-the-panel-area

The UI will require the following new components:

  • Add + button to console panel which creates a duplicate session of the current active runtime via runtimeSessionService.startNewRuntimeSession and makes the new runtime session the active runtime. When a new runtime session is created we should also have a new console instance for the session.
    • This button should be located in the console panel toolbar
  • Add dropdown button next to + button which allows creating a session for any registered runtime from languageRuntimeService.registeredRuntimes.
    • This button will display the modal popup component containing a list of actions the user can take.

We'll want to restrict the number of sessions a user can create to 15 (an arbitrary number for now). We may want to make this a setting option that the user can change.

Testing

  • Verify a session can be viewed/shutdown from the debugging runtime pane
  • Verify a session can be shutdown via the console pane (the console UI tab should still stick around)
  • When creating a new session, verify there is an output channel for the newly created session
  • When creating a new session, verify the variables pane switches context to the new session. The variables pane should display variables for the new session only. The new session should be the active.
  • Verify the number of sessions a user can create is limited to 15
@dhruvisompura dhruvisompura added enhancement New feature or request area: console Issues related to Console category. area: ui Issues related to UI category. labels Feb 11, 2025
@dhruvisompura dhruvisompura added this to the 2025.03 Pre-Release milestone Feb 11, 2025
@dhruvisompura dhruvisompura self-assigned this Feb 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: console Issues related to Console category. area: ui Issues related to UI category. enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant