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.pycategories: init at 1.2.0 #63503

Merged
merged 1 commit into from Jun 25, 2019

Conversation

dmvianna
Copy link
Contributor

Motivation for this change

Add new package.

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.

@risicle
Copy link
Contributor

risicle commented Jun 19, 2019

Why are you not exposing infix as a top-level package? That way it could be used independently or by another package that depends on it.

@dmvianna
Copy link
Contributor Author

About infix: the author of this package marked it as unmaintained. We use it in pycategories, and would possibly absorb infix into it in case it needed to be altered.

@jonringer
Copy link
Contributor

Even if it's stale, it does represent a package on pypi, there may be other packages that may also want to use it.

I'm sure someone else will have stronger opinions on the matter of adding unmaintained packages.

@dmvianna
Copy link
Contributor Author

dmvianna commented Jun 20, 2019

I chose to make it private following a suggestion by @worldofpeace. I do agree that this is useful code, even if unmaintained.

@jonringer
Copy link
Contributor

given the nature of the package, makes sense. Although it probably would be more correct for you all to not rely on it all together :) but I understand not wanting to redo the work.

@worldofpeace
Copy link
Contributor

@dmvianna can you rebase instead of merging? It's part of our contribution guidelines https://nixos.org/nixpkgs/manual/#submitting-changes-making-patches

@dmvianna
Copy link
Contributor Author

Thanks for the heads up. I can do it going forward, but I cannot fix past history without messing this thread, right?

@worldofpeace
Copy link
Contributor

Thanks for the heads up. I can do it going forward, but I cannot fix past history without messing this thread, right?

True, though I think you mean force pushing would mess up the thread? I've never had a problem in that case (github isn't exactly careful with keeping pr threads readable)

@dmvianna
Copy link
Contributor Author

Just so you know, I created an issue upstream to fix the tests in the Pipy package. I prefer we maintain total compatibility with that.

@worldofpeace
Copy link
Contributor

Just so you know, I created an issue upstream to fix the tests in the Pipy package. I prefer we maintain total compatibility with that.

Responding to that issue here

I package the git repository, rather than the Pipy package. That seems wrong, as I would have to make sure I was using in Nix the same commit you used in Pipy, or things would be very confusing.

I don't see a reason why it would be difficult to match the versions, the repo has the tags https://gitlab.com/danielhones/pycategories/-/tags/v1.1.0 which should correspond with what's on PyPI. But actually having the tests in the sdist would be best 👍

@jonringer
Copy link
Contributor

jonringer commented Jun 20, 2019

@worldofpeace I'm not familiar with gitlab support with nix, IIRC github is supported because there's ways to pull down tarballs, not sure if you can do the same with gitlab.

@dmvianna you're correct that it will "mess up" your commit history, but github handles it's fairly well i would just do something simjlar to:

git rebase HEAD~4 -i # you will be given a list of the commits and how to edit them
# specifically, pick the oldest commit in this case, and then squash the others
# once you save, you will be given another prompt to write the new commit message
git push dmvianna pycategories-1.1.0 --force

@worldofpeace
Copy link
Contributor

@worldofpeace I'm not familiar with gitlab support with nix, IIRC github is supported because there's ways to pull down tarballs, not sure if you can do the same with github.

@risicle Already addressed that there's a fetcher function for this #63503 (comment) fetchFromGitLab.

@jonringer
Copy link
Contributor

oh, i wasn't aware this was available, awesome! :)

@dmvianna
Copy link
Contributor Author

I am deeply sorry about the reviewer spam I created.

@worldofpeace
Copy link
Contributor

I am deeply sorry about the reviewer spam I created.

Ah don't worry about that, we're pretty much used to it now. It's more of a bug that GitHub has ATM.

Hopefully this is saner. pycategories-1.2.0 includes the tests in the source distribution. Will address the other comments later. @worldofpeace would you be OK with making infix a separate, public package? It is available from pypi after all.

I supplied the rest of the requested changes. As for infix being public I don't think it being published on PyPI any different than being published on GitHub.

@worldofpeace worldofpeace merged commit 2aaf191 into NixOS:master Jun 25, 2019
@worldofpeace
Copy link
Contributor

Thanks a lot for fixing that upstream @dmvianna

Likewise thanks to our reviewers.

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

4 participants