PMXBOT Log file Viewer

Help | Karma | Search:

#pypa logs for Friday the 19th of August, 2016

(Back to #pypa overview) (Back to channel listing) (Animate logs)
[03:29:12] <askhader> I'm getting this error when trying to install lxml via pip on MacOS10.12 https://gist.github.com/sorter/0aa4b1c2dcfea221acfb49b4e18ec2c9
[03:29:29] <askhader> Is there a development library I'm missing?
[04:02:00] <tdsmith> askhader: i can reproduce on 10.11
[04:02:02] <tdsmith> dunno what's up
[04:03:03] <tdsmith> seems wrong
[04:09:07] <tdsmith> introduced recently in commit 8687eb00 (Stefan Behnel 2016-08-18
[04:10:59] <tdsmith> https://bugs.launchpad.net/lxml/+bug/1614693
[06:25:37] <_pHI_> i noticed that my default install location for "pip install pkg" is (e.g.) /usr/local/include/python2.7 whereas Ubuntu has /usr/include/python2.7 by default. Is there a switch to pip that would install into the latter dir?
[06:26:44] <apollo13> _pHI_: that would be a bad idea
[06:27:23] <mgedmin> pip-installed packages installing C header files? I'm curious
[06:27:51] <apollo13> even then there is CPATH and the likes you make it findable properly without interfering with $system
[06:32:18] <_pHI_> mgedmin: yes, for example pybind11
[06:32:56] <apollo13> _pHI_: and why exactly would those files need to be in /usr/something instead of properly in /usr/local?
[06:33:16] <_pHI_> then `python-config --cflags --ldflags` is all i need to call
[06:33:24] <_pHI_> this only returns the /usr includes etc.
[06:33:50] <apollo13> that is for linking against python
[06:34:03] <apollo13> not for other software that installs header files
[06:34:07] <_pHI_> I see
[06:34:08] <_pHI_> ok
[06:34:59] <_pHI_> is there something similar for pip, i.e. to retrieve where a particular package's (say, headers) was installed
[06:35:08] <_pHI_> similar to that python-config call
[06:35:09] <apollo13> no
[06:35:16] <apollo13> since you could install with --prefix and whatnot
[06:35:35] <apollo13> you might be able to query the egg-info/dist-info but that is out of my league
[06:35:46] <apollo13> and certainly not doable via a simple something-config call
[06:35:50] <_pHI_> ok
[06:36:33] <_pHI_> it's not clear to me how to get that /usr/local/python* folder in a portable way, though..
[06:36:54] <_pHI_> since the user may have called "pip install" with a python 2.x distro -> /usr/local/include/python2.7
[06:37:04] <_pHI_> s/python2.7/python2.x
[06:38:12] <apollo13> _pHI_: the user could also have just installed it to ~/.local/lib/python2.7
[06:38:27] <_pHI_> yes, right, that is true.
[06:38:32] <apollo13> use /usr/local/include/python2.7 as default and let the user override it
[06:38:44] <apollo13> then again, if something installs headers into /usr/local/include/python2.7, that seems broken by design
[06:39:05] <_pHI_> hmm.
[06:39:12] <_pHI_> gotta deal with it, though (to use pybind11)
[06:40:20] <_pHI_> shouldn't pip uninstall <pkg> somehow magically know where that package went to during installation?
[06:40:37] <_pHI_> surprised that it does not expose package location through some command line call, then.
[06:41:08] <apollo13> it does
[06:41:31] <apollo13> but you can query python for those locations
[06:41:44] <apollo13> just not via a simple script, you have to use the sysconfig module or so
[06:41:46] <_pHI_> can you pls tell me how/what you mean
[06:41:50] <_pHI_> oh
[06:43:08] <_pHI_> interesting:
[06:43:13] <_pHI_> from distutils.sysconfig import get_python_inc
[06:43:18] <_pHI_> get_python_inc()
[06:43:40] <_pHI_> well, nevermind, wrong call (-> /usr/include/python2.7), not /usr/local
[06:44:15] <apollo13> correct call
[06:44:31] <apollo13> but again, this is the python sysconfig, for linking and building __against__ python
[06:44:38] <_pHI_> yes, right..
[06:44:43] <apollo13> not some arbritrary 3rd party package which is packaged inproperly
[06:45:33] <apollo13> 'platinclude': '/usr/local/include/python2.7',
[06:45:33] <apollo13> 'platlib': '/usr/local/lib/python2.7/dist-packages',
[06:45:44] <apollo13> see what get_paths() provides
[06:46:36] <_pHI_> interesting. for those I get all those /usr/local locations....
[06:47:10] <_pHI_> either for 'platinclude' and 'include'. both show that /usr/local/include/python2.7 location.
[06:48:41] <_pHI_> so perhaps i should go with this one (say in my CMake to set header location correctly)
[06:59:34] <_pHI_> python -c "from sysconfig import get_path; print(get_path('include'))"
[12:25:22] <lystra> Hi.Hopefully this is the correct forum for this question. If not, I apologize. Usually, when I build a Python module that is written in C to link against some external library I modify setup.cfg to pass in the path of my external library to be used for CPPFLAGS/LDFLAGS like so: http://pastebin.com/Eudbb9pm. This works fine for building the shared Python library. Should this also work when "python setup.py test" tries to build a shared libr
[12:25:23] <lystra> ary during the test process? Doesn't seem to be working with cryptography-1.4 module.
[14:48:33] <askhader> Can anyone help point me in the right direction towards fixing this lxml install error? https://gist.github.com/sorter/7a6f021bae67559657a68d07500ececb
[14:52:51] <dstufft> askhader: probably need to install libxml-dev or something like that
[15:03:06] <askhader> I'm running on macOS
[15:04:53] <Wooble> askhader: lxml recommends using "STATIC_DEPS=true sudo pip install lxml" (which is bad advice, but possibly close to correct if you take out the sudo)
[15:05:47] <askhader> I'll try it
[15:06:07] <Wooble> (lxml inconsistently releasing wheels is my favorite python ecosystem pet peeve.)
[15:07:09] <askhader> wheels?
[15:07:43] <Wooble> askhader: they're a built distribution format so you don't have to muck about with compilers and dependencies.
[15:08:02] <Wooble> 3.6.3 has manylinux wheels for the first time, but no OS X or windows yet.
[15:10:11] <askhader> Wooble: I got this error https://gist.github.com/sorter/8fd7d5854ee01cab7bbad81e8476ed0e
[15:10:57] <Wooble> askhader: with STATIC_DEPS=true?
[15:15:41] <Wooble> (I no longer have access to a mac to check, but I think librt is a new dependency if it's not part of OS X; I've only had to install libxml2 and libxslt in the past...
[15:15:58] <askhader> Correct.
[15:16:06] <askhader> Understood I'll look into that angle.
[15:45:38] <brechtm> askhader: if you aren't using Homebrew, I can recommend that
[15:46:35] <brechtm> (it manages the installation/removal of open-source packages)
[16:08:02] <askhader> brechtm: I am using homebrew
[16:08:23] <brechtm> perfect :-)
[16:49:05] <skyraider> hi, i'm wondering how to include wheels in `install_requires` declarations. the result seems to be 'Could not find suitable distribution' and 'No local packages or working download links found', unless the package (which is on pypi) also has an sdist for the specified version.
[17:27:29] <gp_tablet> is there a simple way to print a resolved requirements.txt file to stdout?
[17:27:45] <gp_tablet> once all the the -r somefile.txt lines have been parsed and included?
[17:28:02] <gp_tablet> remote references are causing me problems building a docker file
[17:37:27] <gp_tablet> Is my best bet going to be using something like basecommand.RequirementCommand?
[18:49:29] <tdsmith> dstufft: askhader: Wooble: fwiw that build error is a lxml bug introduced just before their last release https://bugs.launchpad.net/lxml/+bug/1614693
[18:49:35] <tdsmith> apparently they don't test on os x
[18:54:59] <Wooble> neat
[18:55:30] <Wooble> apprently they already had 2 releases on the same day yesterday too.
[19:56:58] <gp_tablet> dang I got disconnected. if anyone responded to my question earlier I would appreciate it if you would repaste
[20:03:48] <Wooble> gp_tablet: (no one did answer, but I don't know the answer)
[20:04:52] <gp_tablet> wooble: thanks