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 new startup behavior option #44

Merged
merged 1 commit into from
Jan 31, 2025

Conversation

jmcphers
Copy link
Contributor

This repository uses the interpreters.automaticStartup feature, which is being deprecated in favor of an option with finer controls. This change adds the new option.

Supports posit-dev/positron#6145.

Copy link
Collaborator

@testlabauto testlabauto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

jmcphers added a commit to posit-dev/positron that referenced this pull request Jan 30, 2025
This change adds a new option that can be used to gain more control of
how Positron starts an interpreter for each language.

<img width="614" alt="image"
src="https://github.com/user-attachments/assets/cb609ebb-d170-4fda-95da-009d5cb07db4"
/>

The default value, _auto_, gives the automatic behavior we have today;
the others (enumerated in documentation elsewhere) are new behaviors.

In addition, this PR adds a new feature that allows a language pack to
tell Positron which runtime to start for a workspace _before_
discovering all the runtimes on the machine. This happens during the
_Starting_ phase of the startup lifecycle.

Addresses #3575.


### Release Notes

#### New Features

- New "startup behavior" option to control whether specific languages
will start a console in new Positron windows (#3575).

#### Bug Fixes

- N/A


### QA Notes

This new option replaces the old `interpreters.automaticStartup` option
(I think having both would be too confusing). If memory serves we're
using that today in the `qa-example-content` repro. PR updating this
option here: posit-dev/qa-example-content#44

As a debugging aid, I've added a way to show and clear which runtimes
are "affiliated" with the workspace. The new `Interpreter: Clear Saved
Interpreter` command can be used to show you which R/Python/etc.
versions Positron has saved as the ones for your workspace.

<img width="623" alt="image"
src="https://github.com/user-attachments/assets/dbd27b05-c914-4e4c-b759-13c2c45720e6"
/>

We will ultimately need more and better UI for choosing what interpreter
is associated with your project; this command should be seen as a
stopgap/debugging aid.

I've also added a couple of options to the Zed test language runtime so
that in a dev build you can try out the 'recommended for workspace'
workflow.

<img width="375" alt="image"
src="https://github.com/user-attachments/assets/5fca1868-cbb5-4ff8-a365-64f438ee333c"
/>

---------

Signed-off-by: Jonathan <[email protected]>
Co-authored-by: sharon <[email protected]>
@jonvanausdeln jonvanausdeln merged commit 0dede06 into main Jan 31, 2025
@jonvanausdeln jonvanausdeln deleted the feature/startup-behavior-option branch January 31, 2025 18:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants