Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 09:38
    kloczek commented #3362
  • 09:11
    abravalheri commented #3362
  • 08:56

    abravalheri on pep660

    Ensure members of the subcomman… Fix grammar problems with parag… [Doc] Ensure members of the bui… (compare)

  • 08:56
    abravalheri closed #3429
  • 07:53
    kloczek commented #3362
  • 06:58
    abravalheri commented #3362
  • 06:56
    abravalheri commented #3362
  • 06:54
    abravalheri commented #3362
  • 06:43
    kloczek commented #3362
  • 06:34
    abravalheri commented #3362
  • 05:48
    kloczek commented #3362
  • 01:04

    jaraco on main

    Bump version: 63.0.0 → 63.1.0 (compare)

  • 01:04

    jaraco on v63.1.0

    (compare)

  • 01:04

    jaraco on main

    Improve handling if runtime_lib… Add test capturing expectations Remove warnings on namespace pa… and 6 more (compare)

  • 01:04

    jaraco on distutils-152c13d

    (compare)

  • 01:04
    jaraco closed #3430
  • 00:20
    jaraco edited #3430
  • 00:20
    jaraco edited #3430
  • 00:18
    jaraco synchronize #3430
  • 00:18

    jaraco on distutils-152c13d

    Merge with pypa/distutils@152c1… (compare)

Paul Ganssle
@pganssle
It might be that they don't care about portability (as in, what the shebang does in a virtualenv) in this case, but we do allow specifying the target directory for other things, and it kinda sucks to say, "Oh this just won't work in a virtualenv"
Plus there is the --script-dir argument, which I gather allows you to, at runtime, specify a target for all scripts.
Ronny Pfannschmidt
@RonnyPfannschmidt
@pganssle practically speaking - they have to make it a non-binary package (disallowing wheels) and inject a new command for the installation which handles the alternative script install location
whats the context of the script? something like a git addon?
Paul Ganssle
@pganssle
I don't follow why you can't have wheels. data_files is able to install things in libexec just fine.
Ronny Pfannschmidt
@RonnyPfannschmidt
@pganssle you wanted to sort out the shebangs?
thats not part of the toolchain that does wheels and puts them in place
so you either add a own installer, or prevent wheels
Paul Ganssle
@pganssle
I just want it to have feature parity with console_scripts.
I'd like to be able to recommend what to do if they want something that does whatever console_scripts / scripts does, but installs to a different location than bin/
Ronny Pfannschmidt
@RonnyPfannschmidt
thats simply not part of the current tool chain, and there is no standard for it properly ratifying it
Cody Piersall
@codypiersall
I have a Python package I need to depend on that is hosted in at an internal git repository. It has a setup.py, but not at the root of it's repository. Can I specify the location to the setup script somehow?
Axel Huebl
@ax3l
Hi there, does someone know I can get the list of user-requested extras inside my setup.py?
I need to know what a user selected in order to accordingly set a CMake option: pypa/setuptools#1712
Jason R. Coombs
@jaraco
@ax3l That’s not possible as far as I know. If the current project depends on it to decide how to build itself, then it’s not really an extra (as intended). Extras are intended for install-time dependency resolution, not build-time. You’ll want to structure your project so it can support running with and without the extras at run-time… maybe that means building with and without the libs the extras might require, or maybe it means pushing that functionality into the extras themselves.
nvm. I see the conversation is happening in Github.
Axel Huebl
@ax3l
@jaraco thanks for the feedback. yep, I am not using extras anymore since I cannot easily separate this into a runtime dependency
Jason R. Coombs
@jaraco
Cool. Wish the system had been able to readily address your use-case, but glad you found something workable.
Axel Huebl
@ax3l
Yep, I probably misunderstood its design idea. Would be awesome to express build variants as well.
Paul Ganssle
@pganssle
I'm planning on merging pypa/setuptools#1706 then cutting a new minor release.
@jaraco @benoit-pierre Any objections?
Anything you want to see merged before the release?
(I don't have an enormous amount of time for this, so anything that requires too much work is equivalent to just delaying the release)
Jason R. Coombs
@jaraco
@pganssle No objections, and I’m not aware of any other blocker issues, so proceed as you see fit.
dimahassania
@dimahassania
how does setuptools choose which cmdclass to run ? depending on the install method (using -e), my custom command doesn't run
Jason R. Coombs
@jaraco
@dimahassania pip install -e invokes setup.py develop.
sdraper-CS
@sdraper-CS

Hello. I'm experiencing a problem where the end symptom is setuptools complaining setuptools-scm was unable to detect version for.... Ultimately this is during a conda environment create, via pip as an intermediary. I can reproduce it with pip directly just attempting to install one package. The package in question is being installed from a github repo via SSH. It is not in the root of the repo. The setup.py looks like this:

import os
from setuptools import setup

setup(
    name            = 'c12e_data',
    packages        = ['c12e.data'],
    use_scm_version = {
        'root'       : '..',
        'relative_to': os.path.dirname(__file__)
    },

    install_requires = [
        'typing_extensions'
    ],

    tests_require = [
        'hypothesis',
        'pytest >= 3.8.1, < 4.0',
        'c12e_testing'
    ],

    extras_require = {
        's3': ['boto3 >= 1.0.0, < 2.0.0']
    },

    setup_requires = [
        'setuptools_scm',
        'pytest-runner'
    ]
)

This is in the c12e_data directory within the git repo root. The conda environment.yml pins the versions of pip and setuptools according to:

channels:
  - conda-forge
  - pytorch
  - defaults
dependencies:
  - pip=19.0.1
  - python=3.6.8
  - setuptools=40.7.3
  - toolz=0.9.0
  - scikit-learn
  - pip:
    - git+ssh://git@github.com/CognitiveScale/c12e-python.git@v1.0.4#subdirectory=c12e_data

The really odd thing is that this exact install was working fine a few weeks ago, and so far as I can tell nothing has changed (the git tag specified is old and unchanged, the versions of pip and setuptools are pinned and unchanged). All I can think of is that some unpinned transitive dependency (of setuptools or something) must have changed.

I have spent several hours following various issue threads and checking with respect to them (including detailed debug output from pip and setuptools but not gotten anywhere. Has anyone seen anything similar recently?
Paul Ganssle
@pganssle
Did you try pinning setuptools_scm to an older version in your pyproject.toml? Seems like it is most likely to be a change in that package.
Setuptools has no dependencies.
sdraper-CS
@sdraper-CS
Yes - that was indeed the problem. Issue has been reported on setuptools_scm git. Thanks
drocsid
@drocsid
Hi yeah I'm not terribly well versed in python but inherited a broken python project. Inside the project I have a setup.py file that follows:
# -*- coding: utf-8 -*-

from setuptools import setup, find_packages

setup(
    name='int-airflow',
    version='1.0.270',
    license='MIT',
    packages=find_packages(exclude=('tests', 'tests.*', 'hql')),
    install_requires=[
        'apache-airflow>=1.7.0,<1.11.0'
    ],
    classifiers=[
        'Programming Language :: Python :: 2.7'
    ]
)
The project tells me to python setup.py build which fails fast and gives no errors
but when I try python setup.py test then it seems like it tries to grab the dependencies and fails
drocsid
@drocsid
Using /Users/colinwilliams/code/int-airflow/.eggs/pytzdata-2019.1-py2.7.egg
Traceback (most recent call last):
  File "setup.py", line 18, in <module>
    'Programming Language :: Python :: 2.7'
  File "/Users/colinwilliams/code/int-airflow/env/lib/python2.7/site-packages/setuptools/__init__.py", line 145, in setup
    return distutils.core.setup(**attrs)
  File "/usr/local/Cellar/python@2/2.7.16/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/core.py", line 151, in setup
    dist.run_commands()
  File "/usr/local/Cellar/python@2/2.7.16/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py", line 953, in run_commands
    self.run_command(cmd)
  File "/usr/local/Cellar/python@2/2.7.16/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py", line 972, in run_command
    cmd_obj.run()
  File "/Users/colinwilliams/code/int-airflow/env/lib/python2.7/site-packages/setuptools/command/test.py", line 217, in run
    installed_dists = self.install_dists(self.distribution)
  File "/Users/colinwilliams/code/int-airflow/env/lib/python2.7/site-packages/setuptools/command/test.py", line 208, in install_dists
    ir_d = dist.fetch_build_eggs(dist.install_requires)
  File "/Users/colinwilliams/code/int-airflow/env/lib/python2.7/site-packages/setuptools/dist.py", line 717, in fetch_build_eggs
    replace_conflicting=True,
  File "/Users/colinwilliams/code/int-airflow/env/lib/python2.7/site-packages/pkg_resources/__init__.py", line 791, in resolve
    raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.ContextualVersionConflict: (tzlocal 2.0.0b2 (/Users/colinwilliams/code/int-airflow/.eggs/tzlocal-2.0.0b2-py2.7.egg), Requirement.parse('tzlocal<2.0.0.0,>=1.5.0.0'), set(['pendulum']))
So I have two issues. 1)The version conflict, and 2) python setup.py build doesn't install the deps , since I only get the install, etc with python setup.py test
drocsid
@drocsid
I'm not sure if the version conflict is caused by the classifiers line or just the airflow dependency itself...
Ian
@ionox0
Will python setup.py install install the dependencies of listed dependencies automatically?
Paul Ganssle
@pganssle
@ionox0 Do not use setup.py install, use pip install instead.
And yes, pip will install transitive dependencies automatically.
Ian
@ionox0
thank you, I also realized I was missing the extras part of the package that I was trying to install
toil vs toil[cwl]
drocsid
@drocsid

@ionox0 or channel I'm trying to use airflow[qds] from an inherited setup.py project but not sure how to specify. You mention something similar above. My setup.py setup() has

install_requires=[
        'apache-airflow>=1.7.0,<1.11.0',
        'jinja2>=2.10.0',
        'werkzeug>=0.15.0'

    ],

but I don't know how to add the qds module. Can anybody help? I've tried to search this out but am just getting more confused.

Ian
@ionox0
'apache-airflow[qds]>=1.7.0,<1.11.0’
does that work?
im no expert
drocsid
@drocsid
I didn't think it did let me try again
So I try that and the pip install -e . but then when I bring up airflow I get
line 32, in <module>
    from qds_sdk.qubole import Qubole
ImportError: No module named qds_sdk.qubole
Done.
so it allows the install but it looks like it doesn't let me load the qds module.
Ian
@ionox0
might need to use extras_require?
drocsid
@drocsid
I tried that also already