Re: [Distutils] Proposal: "Install and save"

2016-07-31 Thread Wes Turner
I've created a GitHub issue for this feature request: "pip install/upgrade --save" https://github.com/pypa/pip/issues/3884 On Sun, Jul 31, 2016 at 2:29 PM, Wes Turner wrote: > On Jul 31, 2016 12:25 PM, "Jeremy Stanley" wrote: > > > > On 2016-07-30

Re: [Distutils] Proposal: "Install and save"

2016-07-31 Thread Wes Turner
On Jul 31, 2016 12:25 PM, "Jeremy Stanley" wrote: > > On 2016-07-30 20:23:14 -0500 (-0500), Wes Turner wrote: > > pbr also supports "environment markers" > > which we would want to preserve when round-tripping (reading in, modifying, > > and writing out) requirements.txt files;

Re: [Distutils] Proposal: "Install and save"

2016-07-31 Thread Jeremy Stanley
On 2016-07-30 20:23:14 -0500 (-0500), Wes Turner wrote: > pbr also supports "environment markers" > which we would want to preserve when round-tripping (reading in, modifying, > and writing out) requirements.txt files; > though IDK if environment markers are part of any Python Packaging Spec? > >

Re: [Distutils] Proposal: "Install and save"

2016-07-30 Thread Wes Turner
pbr also supports "environment markers" which we would want to preserve when round-tripping (reading in, modifying, and writing out) requirements.txt files; though IDK if environment markers are part of any Python Packaging Spec? from http://docs.openstack.org/developer/pbr/#environment-markers :

Re: [Distutils] Proposal: "Install and save"

2016-07-30 Thread Wes Turner
pipup has "save to a requirements.txt" functionality https://github.com/revsys/pipup It looks like it doesn't yet handle hash-checking mode (which is from peep, IIRC): - https://pip.pypa.io/en/stable/reference/pip_install/#hash-checking-mode -

Re: [Distutils] Proposal: "Install and save"

2016-07-24 Thread Brett Cannon
On Sat, 23 Jul 2016 at 10:36 Daniel Holth wrote: > Not yet. Someone should fix that  > There is an issue tracking that if someone gets adventurous enough to write up a PR: https://github.com/pypa/pip/issues/3691 . -Brett > > On Sat, Jul 23, 2016, 11:37 Alex Grönholm

Re: [Distutils] Proposal: "Install and save"

2016-07-24 Thread Nick Coghlan
On 24 July 2016 at 13:50, Chris Angelico wrote: > On Sun, Jul 24, 2016 at 12:53 PM, Nick Coghlan wrote: >> Personally, I could definitely see a feature like "pip-newdep >> requirements.in '' ''" being relevant in pip-tools as a >> shorthand for something

Re: [Distutils] Proposal: "Install and save"

2016-07-24 Thread Chris Angelico
On Sun, Jul 24, 2016 at 1:50 PM, Chris Angelico wrote: > then requirements.txt would look like > the output of 'pip freeze' but only for the packages listed in > requirements.in? Oops, should have read the readme first. It's listing the dependencies of those packages, too.

Re: [Distutils] Proposal: "Install and save"

2016-07-24 Thread Chris Angelico
On Sun, Jul 24, 2016 at 12:53 PM, Nick Coghlan wrote: > Personally, I could definitely see a feature like "pip-newdep > requirements.in '' ''" being relevant in pip-tools as a > shorthand for something like: > > echo '' >> requirements.in && echo '' >> > requirements.in &&

Re: [Distutils] Proposal: "Install and save"

2016-07-24 Thread Chris Angelico
On Sat, Jul 23, 2016 at 11:32 PM, Alex Grönholm wrote: > I'm -1 on this because requirements.txt is not really the standard way to > list dependencies. > In the Python world, setup.py is the equivalent of Node's package.json. But > as it is > Python code, it cannot so

Re: [Distutils] Proposal: "Install and save"

2016-07-24 Thread Philippe Ombredanne
On Sat, Jul 23, 2016, 17:04, Thomas Kluyver wrote: > As I understand it, in the Javascript world package.json is used in > both > cases. Is that something Python should try to emulate? Is it hard to > achieve given the limitations of setup.py that you pointed out? Thomas: this is not entirely

Re: [Distutils] Proposal: "Install and save"

2016-07-23 Thread Nick Coghlan
On 24 July 2016 at 00:04, Thomas Kluyver wrote: > As I understand it, in the Javascript world package.json is used in both > cases. Is that something Python should try to emulate? Is it hard to > achieve given the limitations of setup.py that you pointed out? There are

Re: [Distutils] Proposal: "Install and save"

2016-07-23 Thread Daniel Holth
Not yet. Someone should fix that  On Sat, Jul 23, 2016, 11:37 Alex Grönholm wrote: > pip doesn't yet support pyproject.toml does it? > > > 23.07.2016, 17:43, Daniel Holth kirjoitti: > > Here is my attempt. The SConstruct (like a Makefile) builds the extension. > The

Re: [Distutils] Proposal: "Install and save"

2016-07-23 Thread Alex Grönholm
pip doesn't yet support pyproject.toml does it? 23.07.2016, 17:43, Daniel Holth kirjoitti: Here is my attempt. The SConstruct (like a Makefile) builds the extension. The .toml file gives the static metadata. No need to put the two in the same file.

Re: [Distutils] Proposal: "Install and save"

2016-07-23 Thread Daniel Holth
Here is my attempt. The SConstruct (like a Makefile) builds the extension. The .toml file gives the static metadata. No need to put the two in the same file. https://bitbucket.org/dholth/cryptacular/src/tip/SConstruct https://bitbucket.org/dholth/cryptacular/src/tip/pyproject.toml On Sat, Jul

Re: [Distutils] Proposal: "Install and save"

2016-07-23 Thread Alex Grönholm
23.07.2016, 17:04, Thomas Kluyver kirjoitti: On Sat, Jul 23, 2016, at 02:32 PM, Alex Grönholm wrote: I'm -1 on this because requirements.txt is not really the standard way to list dependencies. In the Python world, setup.py is the equivalent of Node's package.json. But as it is Python code, it

Re: [Distutils] Proposal: "Install and save"

2016-07-23 Thread Thomas Kluyver
On Sat, Jul 23, 2016, at 02:32 PM, Alex Grönholm wrote: > I'm -1 on this because requirements.txt is not really the standard way > to list dependencies. > In the Python world, setup.py is the equivalent of Node's package.json. > But as it is > Python code, it cannot so easily be programmatically

Re: [Distutils] Proposal: "Install and save"

2016-07-23 Thread Alex Grönholm
I'm -1 on this because requirements.txt is not really the standard way to list dependencies. In the Python world, setup.py is the equivalent of Node's package.json. But as it is Python code, it cannot so easily be programmatically modified. 22.07.2016, 20:48, Chris Angelico kirjoitti: In

[Distutils] Proposal: "Install and save"

2016-07-23 Thread Chris Angelico
In teaching my students how to use third-party Python modules, I generally recommend starting every project with "python3 -m venv env", and then install dependencies into the virtual environment. They then need a requirements.txt to keep track of them. There are two workflows for that: $ pip