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

buildbot: 0.9.0.post1 -> 0.9.3 #22297

Merged
merged 3 commits into from Feb 9, 2017
Merged

Conversation

nand0p
Copy link
Contributor

@nand0p nand0p commented Jan 30, 2017

  • Fixes unneeded patching
  • Adds worker to build inputs now needed for tests
  • Replaces enableworker option with worker configuration module
  • Openssh required for tests
  • Fixes worker hardcoded paths
  • Tested on Nixos Unstable

@nand0p nand0p force-pushed the buildbot-0.9.3 branch 11 times, most recently from c7b34ab to bd8623a Compare February 3, 2017 03:01
@nand0p nand0p changed the title [WIP] buildbot: 0.9.0.post1 -> 0.9.3 buildbot: 0.9.0.post1 -> 0.9.3 Feb 3, 2017
@nand0p
Copy link
Contributor Author

nand0p commented Feb 3, 2017

@FRidh @copumpkin ready_for_review


# NOTE: wheel is used due to buildbot circular dependency
format = "wheel";

src = fetchurl {
url = "https://pypi.python.org/packages/02/d0/fc56ee27a09498638a47dcc5637ee5412ab7a67bfb4b3ff47e041f3d7b66/${name}-py2-none-any.whl";
Copy link
Member

Choose a reason for hiding this comment

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

you might want to check out the new pythonPackages.fetchPypi function.

Copy link
Contributor Author

@nand0p nand0p Feb 3, 2017

Choose a reason for hiding this comment

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

seems to get a 404 with fetchPypi:

- src = fetchurl {
- url = "https://pypi.python.org/packages/02/d0/fc56ee27a09498638a47dcc5637ee5412ab7a67bfb4b3ff47e041f3d7b66/${name}-py2-none-any.whl";
- sha256 = "14ghch67k6090736n89l401swz7r9hnk2zlmdb59niq8lg7dyg9q";
+ src = pythonPackages.fetchPypi {
+ inherit pname version format;
+ sha256 = "1yggg6mcykcnv41srl2sp2zwx2r38vb6a8jgxh1a4825mspm2jf7";

this results in:

curl: (22) The requested URL returned error: 404
error: cannot download buildbot_www-0.9.3-py2.py3-none-any.whl from any mirror
builder for ‘/nix/store/3kscl522lv3n73dlcskjlr4rxckaldkb-buildbot_www-0.9.3-py2.py3-none-any.whl.drv’ failed with exit code 1

Copy link
Member

Choose a reason for hiding this comment

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

That's because the package is named buildbot-www and not buildbot_www.
This is a bit frustrating, Nixpkgs guidelines say the name should be buildbot_www but in pythonPackages I push for the original name.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

looks like same error with buildbot-www

curl: (22) The requested URL returned error: 404
error: cannot download buildbot-www-0.9.3-py2.py3-none-any.whl from any mirror
builder for ‘/nix/store/k9pxvisj91gkydfhkhypw4czyzvxfhw4-buildbot-www-0.9.3-py2.py3-none-any.whl.drv’ failed with exit code 1

Copy link
Member

Choose a reason for hiding this comment

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

Oh, interesting, the name is buildbot_www-0.9.3-py2-none-any.whl , so

fetchPypi {
  pname = "buildbot_www"; # or maybe inherit
  inherit version;
  python = "py2"; # Apparently its only compatible with Python 2.
  sha256 =  "c74951afae4520a202ec4f2265d646238bcebfb85ad0ac03d9964dcfaa79ef79";
};

should work.

In case any of the optional arguments has to be changed its perhaps not worth using this function instead of just using the link. What you choose is up to you.

@nand0p
Copy link
Contributor Author

nand0p commented Feb 6, 2017

@FRidh updated buildbot_www with fetchPypi. this is working now.

'';

postFixup = ''
makeWrapper $out/bin/.buildbot-worker-wrapped $out/bin/buildbot-worker --set PYTHONPATH "$PYTHONPATH"
Copy link
Member

Choose a reason for hiding this comment

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

why is this needed? Is the current wrapper not working?

Copy link
Contributor Author

@nand0p nand0p Feb 6, 2017

Choose a reason for hiding this comment

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

looks like wrapper is not needed here.

@@ -0,0 +1,18 @@
{ stdenv, pkgs }:

pkgs.python27Packages.buildPythonPackage rec {
Copy link
Member

Choose a reason for hiding this comment

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

Don't pass in pkgs, nor pythonpackages. Instead, have the packages as parameters.

@@ -0,0 +1,26 @@
{ stdenv, pkgs }:
Copy link
Member

Choose a reason for hiding this comment

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

same here

@nand0p nand0p force-pushed the buildbot-0.9.3 branch 4 times, most recently from 77f1f88 to db57ca7 Compare February 7, 2017 15:10
@nand0p
Copy link
Contributor Author

nand0p commented Feb 7, 2017

@FRidh fixed up passing packages as parameters. tested and working.

UPDATE: unrelated failure in travis ci https://travis-ci.org/NixOS/nixpkgs/jobs/199250310
3.58s$ ./maintainers/scripts/travis-nox-review-pr.sh nixpkgs-verify nixpkgs-manual nixpkgs-tarball nixpkgs-unstable
=== Verifying that nixpkgs evaluates...
error: value is a string while a list was expected, at /home/travis/build/NixOS/nixpkgs/pkgs/development/interpreters/python/mk-python-derivation.nix:93:19

@FRidh
Copy link
Member

FRidh commented Feb 7, 2017

@nand0p
In case a Python package is called from python-packages.nix, the package expression should have as parameters the individual packages that it needs.

In case a Python application is called from all-packages.nix, the package expression should have as as parameters the Python interpreter (python, so you use python.pkgs or python.withPackages), or the Python package set pythonXXPackages.

- Fixes unneeded patching
- Adds worker to build inputs now needed for tests
- Replaces enableworker option with worker configuration module
- Openssh required for tests
- Fixes worker hardcoded paths
- Tested on Nixos Unstable
@nand0p
Copy link
Contributor Author

nand0p commented Feb 7, 2017

@FRidh fixed

@nand0p
Copy link
Contributor Author

nand0p commented Feb 7, 2017

@FRidh @copumpkin looks like CI is failing unrelated. can we override and merge?

$ ./maintainers/scripts/travis-nox-review-pr.sh nixpkgs-verify nixpkgs-manual nixpkgs-tarball nixpkgs-unstable
=== Verifying that nixpkgs evaluates...
error: value is a string while a list was expected, at /home/travis/build/NixOS/nixpkgs/pkgs/development/interpreters/python/mk-python-derivation.nix:93:19
The command "./maintainers/scripts/travis-nox-review-pr.sh nixpkgs-verify nixpkgs-manual nixpkgs-tarball nixpkgs-unstable" exited with 1.

src = fetchurl {
url = "mirror://pypi/t/${pname}/${name}.tar.gz";
sha256 = "1aci3f3rmb5mdf4s6s4k4kghmnyy784cxgi3pz99m5jp274fs25h";
};
Copy link
Member

Choose a reason for hiding this comment

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

tests aren't run

homepage = http://github.com/twisted/treq;
description = "A requests-like API built on top of twisted.web's Agent";
license = licenses.mit;
maintainers = maintainers.nando0p;
Copy link
Member

Choose a reason for hiding this comment

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

Isn't this expected to be a list?

Copy link
Member

Choose a reason for hiding this comment

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

yep

Fernando J Pando added 2 commits February 9, 2017 10:08
Tested on NixOS unstable
Tested on NixOS unstable
@nand0p
Copy link
Contributor Author

nand0p commented Feb 9, 2017

@FRidh updated treq to explicitly disable tests and commented with the error. I have another PR in the works which addresses broken tests with buildbot dependencies (including treq), so hopefully this will not block merging, and we can fix iteratively.

@copumpkin
Copy link
Member

Looks good to me. @FRidh any objections to merging?

@copumpkin
Copy link
Member

@FRidh oh, I missed that you'd already approved this earlier. I'll just merge now, since the only remaining issues seem to be fixed.

@copumpkin copumpkin merged commit 7439fe0 into NixOS:master Feb 9, 2017
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.

None yet

3 participants