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

pythonPackages.debugpy: init at 1.0.0b12 #91448

Merged
merged 1 commit into from Jul 3, 2020

Conversation

kira-bruneau
Copy link
Contributor

Motivation for this change

Fixes #89592

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 server through dap-mode in Emacs
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@jonringer
Copy link
Contributor

is this meant to be a library (aka import debugpy) or application ($ debugpy ...)?

@kira-bruneau
Copy link
Contributor Author

kira-bruneau commented Jun 25, 2020

@jonringer It's meant as both. It's normally used as an application:

python -m debugpy --listen localhost:5678 myfile.py

but you can also start a server by using it as a library:

import debugpy
debugpy.listen(5678)
debugpy.wait_for_client()  # blocks execution until client is attached

However, it doesn't create a bin wrapper, it must be started with python -m.

@jonringer
Copy link
Contributor

However, it doesn't create a bin wrapper, it must be started with python -m.

I wonder why they didn't do that, it's like 4 lines in a setup.py

@kira-bruneau
Copy link
Contributor Author

@jonringer It looks like they have an issue open for it. I guess they never got around to it, even though it's trivial.

@leungbk
Copy link
Member

leungbk commented Jul 2, 2020

On the latest unstable channel, one test seems to be failing for me: tests/debugpy/test_exception.py::test_systemexit. Are you able to reproduce this?

@jonringer
Copy link
Contributor

On the latest unstable channel, one test seems to be failing for me: tests/debugpy/test_exception.py::test_systemexit. Are you able to reproduce this?

do you mind posting the failure. if it's specific to the nix sandbox, it's fine to skip it. But test failures may also indicate that something is truely broken.

@leungbk
Copy link
Member

leungbk commented Jul 2, 2020

do you mind posting the failure. if it's specific to the nix sandbox, it's fine to skip it. But test failures may also indicate that something is truely broken.

Hmm, I can't seem to reproduce the failure right now. I made a fresh Python build with debugpy just now in a clean environment with the latest master branch of nixpkgs, and all the tests passed. But last night when I was upgrading my packages (including this package, which OP had posted on NUR) with the latest nixos-unstable channel, I observed that one test case (test_systemexit) failing. I suppose we can ignore it for now, and if it comes up again, I'll report back.

@kira-bruneau
Copy link
Contributor Author

@leungbk I can't seem to reproduce the issue either, do you have the commit hash where it was a problem?

@kira-bruneau kira-bruneau changed the title pythonPackages.debugpy: init at 1.0.0b11 pythonPackages.debugpy: init at 1.0.0b12 Jul 3, 2020
@leungbk
Copy link
Member

leungbk commented Jul 3, 2020

@MetaDark The build failure occurred when I was upgrading my system packages (not the cleanest environment) on the latest nixos-unstable channel. But after visiting the commit appearing to correspond to that point in the unstable channel, I cannot reproduce the failure in a fresh environment with nothing but Python 3 and debugpy. Everything appears to build fine.

I'll bring it up in the future if it comes up again and I figure out how to reproduce. Sorry for the noise.

@jonringer
Copy link
Contributor

@GrahamcOfBorg build python3Packages.debugpy

Copy link
Contributor

@jonringer jonringer left a comment

Choose a reason for hiding this comment

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

diff LGTM
commits LGTM
has tests 👍

https://github.com/NixOS/nixpkgs/pull/91448
3 packages built:
python27Packages.debugpy python37Packages.debugpy python38Packages.debugpy

@jonringer
Copy link
Contributor

I think this looks good for now, most of my issues are with upstream not having an "entry_point" in their setup.py.

@jonringer jonringer merged commit a408cd9 into NixOS:master Jul 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

pythonPackages.debugpy: package request
3 participants