element-hq / element-hq/synapse

Warn that poetry will self-sabotage with zero-length setup.py files if interrupted.

Open
#14,788 0 comments 0 reactions 0 assignees View on GitHub
A-Docs O-Uncommon S-Tolerable T-Task
Dominant language
Python
Stars
4.6k
Forks
600
Avg merge
5d 22h
Merged PRs (30d)
51

Description

This issue has been migrated from [#14788](https://github.com/matrix-org/synapse/issues/14788).

---

Repro steps:

* Run `poetry install --extras all -v` on a git checkout
* Interrupt it due to https://github.com/python-poetry/poetry-core/pull/499 not having been merged, and the fact that it gets stuck traversing a massive media store directory tree.
* Don't notice that it's left a zero-length `setup.py` file in the root of the checkout
* Run `poetry install --extras all -v` again
* Discover it fails cryptically with:
```
Obtaining file:///home/matrix/synapse
Preparing metadata (setup.py): started
Preparing metadata (setup.py): finished with status 'done'
ERROR: No .egg-info directory found in /tmp/pip-pip-egg-info-81uum26d
```
* Eventually figure out that you have to delete `setup.py` to make poetry stop mysteriously failing.

Filing this in case we want to update the Synapse guide to reflect this - or failing that, to leave a breadcrumb trail for others to find. Or i guess we could ask poetry to fix this horrific behaviour; i had to `strace` the wretched thing to figure out what the root cause was.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.