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

ruby: rubygems 2.7.7 -> 3.0.3 #60394

Merged
merged 2 commits into from May 1, 2019
Merged

ruby: rubygems 2.7.7 -> 3.0.3 #60394

merged 2 commits into from May 1, 2019

Conversation

alyssais
Copy link
Member

@alyssais alyssais commented Apr 28, 2019

With this change, we can finally easily upgrade Rubygems, and get off this ancient version. Patches no longer have to live on @zimbatm’s GitHub and be applied using a hack that can only handle a single patch. Hooray!

Attempt 2, following #57809.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • 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 nix-review --run "nix-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)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Copy link
Member

@zimbatm zimbatm left a comment

Choose a reason for hiding this comment

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

nice work. Just one comment and ofborg eval issue with the license field:

while evaluating 'handleEvalIssue' at /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/eval-0-gleber.ewr1.nix.ci/.gc-of-borg-outpaths.nix:26:37, called from /var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/mr-est/eval-0-gleber.ewr1.nix.ci/pkgs/stdenv/generic/check-meta.nix:158:8:
evaluation aborted with the following error message: 'Failed to evaluate rubygems: «unknown-meta»: has an invalid meta attrset:
        - key 'licenses' is unrecognized; expected one of: 
['available', 'badPlatforms', 'branch', 'broken', 'description', 'downloadPage', 'downloadURLRegexp', 'executables', 'homepage', 'hydraPlatforms', 'isBuildPythonPackage', 'isFcitxEngine', 'isGutenprint', 'isIbusEngine', 'knownVulnerabilities', 'license', 'longDescription', 'maintainers', 'name', 'outputsToInstall', 'platforms', 'position', 'priority', 'repositories', 'schedulingPriority', 'tag', 'tests', 'timeout', 'updateWalker', 'version']'

patches = [
./0001-add-post-extract-hook.patch
./0002-binaries-with-env-shebang.patch
./0003-gem-install-default-to-user.patch
Copy link
Member

Choose a reason for hiding this comment

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

in general we try to use fetchPatch when possible to avoid growing the nixpkgs repo unnecessarily

Copy link
Member Author

Choose a reason for hiding this comment

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

IMO "when possible" shouldn't include pointing to patch URL's on a single maintainer's GitHub fork – if this were the case, Nixpkgs wouldn't need to contain any patch files at all, but that's clearly not how things are?

Copy link
Member

Choose a reason for hiding this comment

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

To be fair I don't think we have a clear policy on that and it's probably not enforced consistently across nixpkgs.

Patches should be cached by the binary cache so having them on a fork shouldn't really be a problem.

Copy link
Member

Choose a reason for hiding this comment

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

Would it be better for you if we maintained the fork in the nix-community org?

Rather than rolling our own. This means that we can use all of the
extra functionality stdenv gives us, like being able to provide a list
of patches rather than just one.
I think it makes more sense to keep the patches in-tree than on
zimbatm's RubyGems fork.
@alyssais
Copy link
Member Author

alyssais commented Apr 29, 2019 via email

@artemist
Copy link
Member

Do you want to put this on staging, or is master fine? I've merged my larger package updates (like git) in staging and this seems to be approaching the "mass rebuild" category.

@zimbatm
Copy link
Member

zimbatm commented Apr 30, 2019

@alyssais if the patches don't apply cleanly on the new branch then it's a bit easier to create a new branch and rebase the patches onto upstream's release in my experience. Assuming that the maintainer has access to the fork.

Since you are the maintainer in that case, I think the minimum would be for you to get access to the fork, or relocate the fork in a good location. And if you prefer to inline the patches inside of nixpkgs then I'm happy to defer to your opinion as well.

@alyssais
Copy link
Member Author

I've merged my larger package updates (like git) in staging and this seems to be approaching the "mass rebuild" category.

This is nowhere near the size of a git upgrade, but if there's any question about whether something should go to staging, that's probably a good sign it should go to staging. :)

@alyssais alyssais changed the base branch from master to staging April 30, 2019 14:11
@alyssais
Copy link
Member Author

alyssais commented May 1, 2019

I still think the patches are better inline, and so I am going to go ahead with that.

@alyssais alyssais merged commit 3567b13 into NixOS:staging May 1, 2019
@alyssais alyssais deleted the rubygems branch May 1, 2019 23:23
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