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

Pip: Do not raise PathDependenciesNotReachable for missing setup.py #5392

Merged
merged 2 commits into from
Jul 19, 2022

Conversation

jurre
Copy link
Member

@jurre jurre commented Jul 18, 2022

Previously, Dependabot would assume that for every requirements.txt with
a self-reference (-e .), we should expect a setup.py to be present. The
self-reference is considered a path dependency that needs a setup.py.

However, nowadays it's valid to have a requirements.txt without a
setup.py. This change accounts for that by still attempting to pull in a
setup.py if it exists, but to not raise and error when it doesn't.

Closes #5324
Resolves #4483

@jurre jurre requested a review from a team as a code owner July 18, 2022 20:44
@jurre jurre force-pushed the jurre/pip-does-not-require-setup-py branch from 4c04a86 to 5e99b8a Compare July 18, 2022 20:51
Previously, Dependabot would assume that for every requirements.txt with
a self-reference ('`-e .`), we should expect a `setup.py` to be present. The
self-reference is considered a path dependency that needs a setup.py.

However, nowadays it's valid to have a requirements.txt without a
setup.py. This change accounts for that by still attempting to pull in a
setup.py if it exists, but to not raise and error when it doesn't.
@jurre jurre force-pushed the jurre/pip-does-not-require-setup-py branch from 5e99b8a to e0b33c6 Compare July 19, 2022 04:40
This is unrelated to other changes in this PR, but blinker released a
new version today, and this breaks one of our tests.

We should replace it with a reference to something we own, or lock the
constraints so that we don't run into this, but this get's us green for
now at least.
Copy link

@DanielNoord DanielNoord left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As far as I can see this should work. Thanks for all the work you did here @jurre 😄

@jurre jurre merged commit 6df5fea into main Jul 19, 2022
@jurre jurre deleted the jurre/pip-does-not-require-setup-py branch July 19, 2022 18:31
@DanielNoord
Copy link

DanielNoord commented Jul 20, 2022

@jurre Do repositories automatically update to a new version of dependabot as soon as it is released? If so, not all problems seem to have been resolved 😅

I still get failing runs on https://github.com/DanielNoord/pydocstringformatter.

  proxy | 2022/07/20 15:59:55 [024] 404 https://api.github.com:443/repos/DanielNoord/pydocstringformatter/contents/setup.py?ref=fa41767f4a14fbd80464d084e6dcb62a00df44a3
updater | ERROR <job_422750561> Error during file fetching; aborting
updater | INFO <job_422750561> Finished job processing
updater | INFO Results:
updater | Dependabot encountered '1' error(s) during execution, please check the logs for more details.
updater | time="2022-07-20T15:59:56Z" level=info msg="task complete" container_id=job-422750561-file-fetcher exit_code=0 job_id=422750561 step=fetcher
updater | time="2022-07-20T15:59:56Z" level=warning msg="failed during fetch, skipping updater" job_id=422750561

Edit: Never mind I misread the git history on main. This PR was released after the latest release commit. My bad!

@jurre
Copy link
Member Author

jurre commented Jul 20, 2022

Edit: Never mind I misread the git history on main. This PR was released after the latest release commit. My bad!

Yeah I'll try to get a release out in the next few days, but I'm currently traveling, so might be a little slower than normally

@brrygrdn brrygrdn mentioned this pull request Jul 21, 2022
@DanielNoord
Copy link

Thanks @jurre this is now working as expected 😄

lukpueh added a commit to lukpueh/tuf that referenced this pull request Aug 30, 2022
setup.py was removed in favor of setup.cfg in theupdateframework#1626 and re-added
later in theupdateframework#1832 to work around a Dependabot issue theupdateframework#1828. This issue
seems to have been fixed upstream in dependabot/dependabot-core#5392.

Fixes theupdateframework#2089

Signed-off-by: Lukas Puehringer <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Dependabot trying to download setup.py after move to pyproject.toml
5 participants