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

detect when setuptools is downlevel and abort the isntall with a good error #1975

Closed
beckjake opened this issue Dec 4, 2019 · 2 comments · Fixed by #1978
Closed

detect when setuptools is downlevel and abort the isntall with a good error #1975

beckjake opened this issue Dec 4, 2019 · 2 comments · Fixed by #1978
Labels
dependencies Changes to the version of dbt dependencies enhancement New feature or request
Milestone

Comments

@beckjake
Copy link
Contributor

beckjake commented Dec 4, 2019

Describe the feature

dbt requires a version of setuptools greater than v40.1.0 to install. We should check for this version and raise a useful error message if the user is downlevel.

Describe alternatives you've considered

We can just ignore this and let users get errors about not finding find_namespace_packages at install time.

Additional context

dbt requires the find_namespace_packages function from setuptools, which was introduced in v40.1.0 (see here). We currently crash with a pretty unhelpful error message about cannot import name 'find_namespace_packages'. Instead we should check and raise an error instructing users to run python -m pip install -U seuptools.

Who will this benefit?

Users trying to install dbt, especially those new to python/pip.

@beckjake beckjake added enhancement New feature or request triage labels Dec 4, 2019
@drewbanin drewbanin added dependencies Changes to the version of dbt dependencies and removed triage labels Dec 4, 2019
@drewbanin drewbanin added this to the 0.15.1 milestone Dec 4, 2019
@drewbanin
Copy link
Contributor

really good idea @beckjake - is this something we can hit for 0.15.1? I just put it in that milestone, but we can change to 0.15.2 if needed

@beckjake
Copy link
Contributor Author

beckjake commented Dec 4, 2019

Yeah, totally! It should be a trivial change, just a quick tweak to setup.py to catch the ImportError I would guess. If it's harder than that we can kick it out.

beckjake added a commit that referenced this issue Dec 5, 2019
…evel-setuptools

fail more gracefully when setuptools is downlevel (#1975)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Changes to the version of dbt dependencies enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants