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.flake8-future-import: fix build #100533

Merged
merged 1 commit into from Oct 16, 2020

Conversation

@mweinelt
Copy link
Member

@mweinelt mweinelt commented Oct 14, 2020

Motivation for this change

Breaks esphome which subsequently requires platformio, which in turn requires esphome.

Was broken after python3.8 upgraded to 3.8.6 due to this change:

bpo-41314: Changed the release when from future import annotations becomes the default from 4.0 to 3.10 (following a change in PEP 563).

Reported upstream in xZise/flake8-future-import#24.

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)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.
@@ -20,7 +20,7 @@ buildPythonPackage rec {
# Upstream disables this test case naturally on python 3, but it also fails
# inside NixPkgs for python 2. Since it's going to be deleted, we just skip it
# on py2 as well.
patches = lib.optionals isPy27 [ ./skip-test.patch ];
patches = lib.optionals isPy38 [ ./fix-annotations-version.patch ] ++ lib.optionals isPy27 [ ./skip-test.patch ];
Copy link
Contributor

@jonringer jonringer Oct 15, 2020

getting kind of long

Suggested change
patches = lib.optionals isPy38 [ ./fix-annotations-version.patch ] ++ lib.optionals isPy27 [ ./skip-test.patch ];
patches = lib.optionals isPy38 [ ./fix-annotations-version.patch ]
++ lib.optionals isPy27 [ ./skip-test.patch ];

Was broken after python3.8 upgraded to 3.8.6 due to this change:

    bpo-41314: Changed the release when from future import annotations becomes the default from 4.0 to 3.10 (following a change in PEP 563).
@mweinelt mweinelt force-pushed the python/flake8-future-import branch from 85ef893 to 01d7285 Oct 15, 2020
@mweinelt
Copy link
Member Author

@mweinelt mweinelt commented Oct 15, 2020

Copy link
Contributor

@jonringer jonringer left a comment

LGTM

Result of nixpkgs-review pr 100533 1

3 packages built:
  • esphome
  • esptool
  • python38Packages.flake8-future-import

@jonringer jonringer merged commit c7129fb into NixOS:master Oct 16, 2020
17 checks passed
@mweinelt mweinelt deleted the python/flake8-future-import branch Oct 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants