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

Update vscode python #121072

Merged
merged 3 commits into from
May 8, 2021
Merged

Update vscode python #121072

merged 3 commits into from
May 8, 2021

Conversation

kinnison
Copy link
Contributor

@kinnison kinnison commented Apr 28, 2021

Motivation for this change

Microsoft updated their Python extension for vscode in April 2021. This isn't a straightforward upgrade since it splits some of the functionality out into their Jupyter extension (which is also unfree :( )

However if we don't update then anyone installing their vscode extensions via nix will suffer with vscode bugging them about the extension being updatable until they eventually crack and end up with an extension installed in their homedir rather than declaratively.

I tested this via swapping out my "unstable" nixpkgs flake in my system configuration and rebuilding to confirm the new python extension was installed along with the Jupyter one automatically.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Before: 651M
  • After 660M
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@kinnison kinnison requested a review from jonringer as a code owner April 28, 2021 20:07
@kinnison kinnison force-pushed the update-vscode-python branch from 584a942 to c93888b Compare April 28, 2021 20:12
@ofborg ofborg bot added 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 1-10 labels Apr 28, 2021
@r-rmcgibbo
Copy link

Result of nixpkgs-review pr 121072 at c93888b3 run on x86_64-linux 1

2 packages built successfully:
  • vscode-extensions.ms-python.python
  • vscode-extensions.ms-toolsai.jupyter

kinnison added 3 commits May 2, 2021 21:12
This splits off part of the Python extension into Microsoft's jupyter
extension, so this is necessary but not sufficient.

Signed-off-by: Daniel Silverstone <[email protected]>
This is a necessary dependency of the new Python extension for
VSCode.

Signed-off-by: Daniel Silverstone <[email protected]>
In order for the ms-python.python extension to work these days,
we also need the ms-toolsai.jupyter extension.  To permit easy
upgrades and to honour the principle of least surprise, we
wrapper the Python extension to include the Jupyter one.  The
reverse is not true, you *can* have the Jupyter extension without
the Python one, so the reverse is not also done.

Signed-off-by: Daniel Silverstone <[email protected]>
@kinnison kinnison force-pushed the update-vscode-python branch from c93888b to b71773e Compare May 2, 2021 20:12
@kinnison
Copy link
Contributor Author

kinnison commented May 2, 2021

I have confirmed the closure sizes, checked again against CONTRIBUTING and rebased against current master.

@kinnison
Copy link
Contributor Author

kinnison commented May 3, 2021

@jonringer Do you need me to do anything else for this, or is it simply a case of "when you have time to consider it again" ?

@kinnison kinnison mentioned this pull request May 8, 2021
Copy link
Contributor

@lukegb lukegb left a comment

Choose a reason for hiding this comment

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

LGTM - mind bumping the Jupyter version and giving it a quick test? Then I'll merge.

pkgs/misc/vscode-extensions/default.nix Show resolved Hide resolved
@lukegb lukegb merged commit b2544d1 into NixOS:master May 8, 2021
@kinnison kinnison deleted the update-vscode-python branch May 8, 2021 17:32
SuperSandro2000 added a commit that referenced this pull request Jun 25, 2021
vscode-extensions.ms-python.python: revert #121072
@Janik-Haag Janik-Haag added the 12. first-time contribution This PR is the author's first one; please be gentle! label Jun 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
8.has: package (new) This PR adds a new package 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 1-10 12. first-time contribution This PR is the author's first one; please be gentle!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants