You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Investigate environment detection in our overall environment UX to see if there are scenarios where discovery is unnecessary #19102
changed the title [-]Investigate environment detection in our overall environment UX to see if there are scenarios where discovery is unnecessary[/-][+]Only trigger auto environment discovery once in the first session for a particular scope[/+]on May 13, 2022
changed the title [-]Only trigger auto environment discovery once in the first session for a particular scope[/-][+]Investigate environment detection in our overall environment UX to see if there are scenarios where discovery is unnecessary[/+]on May 13, 2022
Certain components (like diagnostics) call for hasInterpreters() API, which requires that discovery is triggered atleast once for it to work. See if we can avoid calling it and make sure information returned by it is reliable enough.
Activity
karrtikr commentedon May 13, 2022
Auto-triggering discovery is probably not needed. Only a couple places need it:
karrtikr commentedon May 13, 2022
Question: Is triggering it once in the first session even needed, if an interpreter is already selected?
Perhaps not from a user perspective (#18647), but yes, the discovery API is only considered to be ready for query once refresh has been triggered.
Reasons for doing it in the first session:
Select Interpretersection in the getting started section already has environments populated.[-]Investigate environment detection in our overall environment UX to see if there are scenarios where discovery is unnecessary[/-][+]Only trigger auto environment discovery once in the first session for a particular scope[/+][-]Only trigger auto environment discovery once in the first session for a particular scope[/-][+]Investigate environment detection in our overall environment UX to see if there are scenarios where discovery is unnecessary[/+]karrtikr commentedon May 16, 2022
We also need to make sure legacy jupyter integration APIs still work.
karrtikr commentedon May 17, 2022
Proposed approach, only auto-trigger discovery if:
Note we also need to make sure that the selected environment has the latest version, now that discovery isn't run by default.
karrtikr commentedon May 18, 2022
Verification steps:
If Jupyter is not installed or disabled, verify we auto-trigger discovery only if:
If Jupyter is installed, discovery is always triggered.
karrtikr commentedon May 19, 2022
Certain components (like diagnostics) call for
hasInterpreters()API, which requires that discovery is triggered atleast once for it to work. See if we can avoid calling it and make sure information returned by it is reliable enough.rchiodo commentedon Jun 1, 2022
/verified?
It does trigger discovery just when opening 'Select interpreters'? Is this expected?
Otherwise behaves as you outlined.
karrtikr commentedon Jun 1, 2022
Yep, that's what the above point means in #19102 (comment), only happens the first time though.