Skip to content

Comments

[20.09] pythonPackages.pymc3: fix build, init pythonPackages.fastprogress at 1.0.0#100955

Merged
jonringer merged 3 commits intoNixOS:release-20.09from
risicle:ris-theano-tmpdir-redirect-fix-r20.09
Oct 19, 2020
Merged

[20.09] pythonPackages.pymc3: fix build, init pythonPackages.fastprogress at 1.0.0#100955
jonringer merged 3 commits intoNixOS:release-20.09from
risicle:ris-theano-tmpdir-redirect-fix-r20.09

Conversation

@risicle
Copy link
Contributor

@risicle risicle commented Oct 18, 2020

Motivation for this change

ZHF: #97479

This is a modified & combined backport of #99587 and #100867.

Because 20.09 is missing #97597 and #93560 (and I think including them at this stage might be a bit risky), importing/using theano from within a nix build environment (i.e. with NIX_ENFORCE_PURITY=1) will only succeed if the tmpdir used is actually literally /tmp, which you can't really do from a sandboxed build. So this uses libredirect to convince the compiler wrapper we are actually working with /tmp.

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.

@risicle
Copy link
Contributor Author

risicle commented Oct 18, 2020

@ofborg build python37Packages.pymc3

@ofborg ofborg bot added 6.topic: python Python is a high-level, general-purpose programming language. 8.has: package (new) This PR adds a new package labels Oct 18, 2020
@ofborg ofborg bot requested a review from bcdarwin October 18, 2020 10:59
@ofborg ofborg bot added 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 11-100 This PR causes between 11 and 100 packages to rebuild on Linux. labels Oct 18, 2020
Copy link
Member

@das-g das-g left a comment

Choose a reason for hiding this comment

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

Please use correct grammar in comments.

(modified cherry pick of commit 4a9dba6)

some tricks are required to make this work because NixOS#93560 and NixOS#97597
didn't make it into this branch, but this example shows what is required
to import theano from within a nix build environment on this branch.
(modified cherry-pick of commit 3c3295a)
@risicle risicle force-pushed the ris-theano-tmpdir-redirect-fix-r20.09 branch from 264840d to f447235 Compare October 18, 2020 18:24
@risicle
Copy link
Contributor Author

risicle commented Oct 18, 2020

Er.. not sure if you're serious, but ok...

@das-g
Copy link
Member

das-g commented Oct 18, 2020

Result of nixpkgs-review pr 100955 1

10 packages built:
  • python27Packages.Lasagne
  • python27Packages.Theano (python27Packages.TheanoWithoutCuda)
  • python27Packages.TheanoWithCuda
  • python37Packages.Theano (python37Packages.TheanoWithoutCuda)
  • python37Packages.TheanoWithCuda
  • python37Packages.fastprogress
  • python37Packages.pymc3
  • python38Packages.Theano (python38Packages.TheanoWithoutCuda)
  • python38Packages.TheanoWithCuda
  • python38Packages.fastprogress

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.

LGTM

Result of nixpkgs-review pr 100955 1

10 packages built:
  • python27Packages.Lasagne
  • python27Packages.Theano (python27Packages.TheanoWithoutCuda)
  • python27Packages.TheanoWithCuda
  • python37Packages.Theano (python37Packages.TheanoWithoutCuda)
  • python37Packages.TheanoWithCuda
  • python37Packages.fastprogress
  • python37Packages.pymc3
  • python38Packages.Theano (python38Packages.TheanoWithoutCuda)
  • python38Packages.TheanoWithCuda
  • python38Packages.fastprogress

@twhitehead
Copy link
Contributor

@risicle BTW, just wanted to say thanks for working this all out. Have been reading through the various threads and can see this was quite a mess for you to straighten out. 👍

@risicle
Copy link
Contributor Author

risicle commented Oct 22, 2020

No problem - you got the real fix in place.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: python Python is a high-level, general-purpose programming language. 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 11-100 This PR causes between 11 and 100 packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants