[Distutils] Re: disable building wheel for a package

2018-09-19 Thread Tzu-ping Chung
> On 19/9, 2018, at 16:02, Paul Moore wrote: > > On Wed, 19 Sep 2018 at 00:52, Dan Ryan wrote: >> >>> so the people benefiting >>> are those who want a supported API for that functionality, and it >>> seems only reasonable to expect them to do the job of moving the code, >>> rather than expect

[Distutils] Re: disable building wheel for a package

2018-09-19 Thread Paul Moore
On Wed, 19 Sep 2018 at 00:52, Dan Ryan wrote: > > > so the people benefiting > > are those who want a supported API for that functionality, and it > > seems only reasonable to expect them to do the job of moving the code, > > rather than expecting the pip developers to do so. > > This is where I t

[Distutils] Re: disable building wheel for a package

2018-09-18 Thread Dan Ryan
> so the people benefiting > are those who want a supported API for that functionality, and it > seems only reasonable to expect them to do the job of moving the code, > rather than expecting the pip developers to do so. This is where I think we disagree and I feel the rhetoric is a bit harmful --

[Distutils] Re: disable building wheel for a package

2018-09-18 Thread Paul Moore
Agreed. Furthermore, if people are of the opinion that pip's implementation is suitable, copying it out into packaging is likely not going to be at all controversial. Of course, it's not going to be any direct advantage to pip if that's done (we get the same functionality, just in a different place

[Distutils] Re: disable building wheel for a package

2018-09-18 Thread Donald Stufft
> On Sep 18, 2018, at 4:31 PM, Dan Ryan wrote: > > As a consequence even though there are other libraries that may provide some > of this functionality, pip has the reference implementation and that > contains some significant additional logic. I don't imagine that pip is > going to simply adopt

[Distutils] Re: disable building wheel for a package

2018-09-18 Thread Dan Ryan
.mo...@gmail.com] > Sent: Tuesday, September 18, 2018 3:25 PM > To: Thomas Kluyver > Cc: Distutils > Subject: [Distutils] Re: disable building wheel for a package > > On Tue, 18 Sep 2018 at 19:54, Thomas Kluyver > wrote: > > > > On Fri, Sep 14, 2018, at 4:26 PM, Pa

[Distutils] Re: disable building wheel for a package

2018-09-18 Thread Paul Moore
On Tue, 18 Sep 2018 at 19:54, Thomas Kluyver wrote: > > On Fri, Sep 14, 2018, at 4:26 PM, Paul Moore wrote: > > I don't think it's "hard to predict". I *do* think it's badly > > documented/not standardised. > > ... > > Better would be to have a supported library that exposes the logic pip > > use

[Distutils] Re: disable building wheel for a package

2018-09-18 Thread Thomas Kluyver
On Fri, Sep 14, 2018, at 4:26 PM, Paul Moore wrote: > I don't think it's "hard to predict". I *do* think it's badly documented/not > standardised. > ... > Better would be to have a supported library that exposes the logic pip > uses (or as I said above, the standard-defined logic) to determine > s

[Distutils] Re: disable building wheel for a package

2018-09-15 Thread Paul Moore
On Sat, 15 Sep 2018 at 08:26, Jeroen Demeyer wrote: > > On 2018-09-14 18:36, Paul Moore wrote: > > And actually, > > https://packaging.python.org/guides/distributing-packages-using-setuptools/#data-files > > is a reasonably clear explanation of the current behaviour > > I actually rewrote that pa

[Distutils] Re: disable building wheel for a package

2018-09-15 Thread Jeroen Demeyer
On 2018-09-14 18:36, Paul Moore wrote: And actually, https://packaging.python.org/guides/distributing-packages-using-setuptools/#data-files is a reasonably clear explanation of the current behaviour I actually rewrote that paragraph recently, so I'm glad that you find it reasonably clear :-)

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Nathaniel Smith
On Fri, Sep 14, 2018, 07:27 Daniel Holth wrote: > No one wants wheel to be able to install things outside of the virtualenv. > What people have repeatedly asked for is the ability to install things > somewhere besides $VIRTUAL_ENV/lib/python#.#/site-packages/, places like > $VIRTUAL_ENV/etc/ for

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Donald Stufft
FWIW I think it’s perfectly reasonable to expand the categories we have, it might also let us do things like exclude some categories from being installed on systems they don’t make sense on. e.g. installing a man page on Windows probably doesn’t make very much sense, so we could just exclude it.

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Paul Moore
On Fri, 14 Sep 2018 at 17:05, Jeroen Demeyer wrote: > > On 2018-09-14 16:39, Paul Moore wrote: > > My understanding (and I'm not an expert here, so hopefully someone > > else will confirm or correct) is that yes, the data directory is > > installed to "the installation root", which is $VIRTUAL_ENV

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Jeroen Demeyer
On 2018-09-14 16:39, Paul Moore wrote: My understanding (and I'm not an expert here, so hopefully someone else will confirm or correct) is that yes, the data directory is installed to "the installation root", which is $VIRTUAL_ENV for a virtualenv, and "something else" for non-virtualenvs (I thin

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Jeroen Demeyer
On 2018-09-14 15:49, sashk wrote: Do I understand correctly, that when using relative paths in the data_files and installing package into virtual environment, installation prefix is sys.prefix and it is the same as $VIRTUAL_ENV? Indeed, unless you specifically configure things in a non-default

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Daniel Holth
A corner case is where the package is importable because it is on $PYTHONPATH and so the $virtual_env at runtime is different than the one at install time. That is why it might be useful to store the data directory per-package. wheel.install.get_install_paths(package_name) shows where things would

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Paul Moore
On Fri, 14 Sep 2018 at 16:03, Daniel Holth wrote: > > It can be hard to predict where data went at runtime. I don't think it's "hard to predict". I *do* think it's badly documented/not standardised. See my previous note - pip installs into the install_data location that setuptools/distutils choos

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Daniel Holth
It can be hard to predict where data went at runtime. Maybe we could record its path in .dist-info during the install. I think it may also not be clear how to put files into wheel's data directory from setup.py. If we added more categories it would allow the installer to override e.g. just the con

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Tzu-ping Chung
I’m wondering though, why? The wheel format already offers a data directory, couldn’t it be used for most of the things mentioned? > On 14/9/2018, at 22:25, Daniel Holth wrote: > > No one wants wheel to be able to install things outside of the virtualenv. > What people have repeatedly asked f

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Paul Moore
On Fri, 14 Sep 2018 at 14:51, sashk wrote: > No, I'm not installing anything into standard unix locations. My package is > for internal use, so we had a luxury to write it specifically for use with > virtual environment. > > We need to install Jupyter kernels (and other files) into > $VIRTUAL_E

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Daniel Holth
No one wants wheel to be able to install things outside of the virtualenv. What people have repeatedly asked for is the ability to install things somewhere besides $VIRTUAL_ENV/lib/python#.#/site-packages/, places like $VIRTUAL_ENV/etc/ for example. Should all the config files, documentation, data,

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread sashk
  14.09.2018, 08:37, "Paul Moore" :On Fri, 14 Sep 2018 at 12:43, Jeroen Demeyer wrote: On 2018-09-14 12:55, Alex Grönholm wrote: > I'm curious: what data does it attempt to install and where? Have you > created a ticket for this somewhere? The OP mentioned absolute paths. Howev

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Paul Moore
On Fri, 14 Sep 2018 at 12:43, Jeroen Demeyer wrote: > > On 2018-09-14 12:55, Alex Grönholm wrote: > > I'm curious: what data does it attempt to install and where? Have you > > created a ticket for this somewhere? > > The OP mentioned absolute paths. However, it really sounds like a bad > idea to h

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Paul G
Yes that feels very dangerous to me. From the github thread it sounds like setuptools *does* support it. I would be inclined to deprecate support for that in setuptools if that's the case (though obviously since setup.py is a regular python file you can write your own code to do whatever you wan

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Jeroen Demeyer
On 2018-09-14 12:55, Alex Grönholm wrote: I'm curious: what data does it attempt to install and where? Have you created a ticket for this somewhere? The OP mentioned absolute paths. However, it really sounds like a bad idea to hard-code an absolute installation path. Let's consider it a featu

[Distutils] Re: disable building wheel for a package

2018-09-14 Thread Alex Grönholm
I'm curious: what data does it attempt to install and where? Have you created a ticket for this somewhere? ke, 2018-09-12 kello 15:56 -0400, sashk kirjoitti: > > > > > I agree with Nathaniel - the correct solution is to fix your > > > package > > > so that can be built as a wheel which correctl

[Distutils] Re: disable building wheel for a package

2018-09-13 Thread Paul Moore
On Wed, 12 Sep 2018 at 21:03, sashk wrote: > Package need to install several non-python files into specific path and we > are using data_files. Because wheel doesn't support absolute path[1], these > files are installed into wrong location under site-packages. I need some kind > of solution fo

[Distutils] Re: disable building wheel for a package

2018-09-12 Thread sashk
  I agree with Nathaniel - the correct solution is to fix your packageso that can be built as a wheel which correctly installs as you wish.If that's not possible due to limitations in the wheel format or thewheel building process, please file issues explaining your use caseand the problems you're h

[Distutils] Re: disable building wheel for a package

2018-09-12 Thread Paul Moore
On Wed, 12 Sep 2018 at 18:33, Nathaniel Smith wrote: > > On Wed, Sep 12, 2018, 09:53 sashk wrote: >> >> Hi, >> >> With latest version of pip, it now forces to build wheel for every package, >> which causes incompatibilities (due to use of data_files and copying into >> not standard path) . I've

[Distutils] Re: disable building wheel for a package

2018-09-12 Thread Nathaniel Smith
On Wed, Sep 12, 2018, 09:53 sashk wrote: > Hi, > > With latest version of pip, it now forces to build wheel for every > package, which causes incompatibilities (due to use of data_files and > copying into not standard path) . I've attempted to add --binary=:all: > --no-binary mypackage to the pip