Skip to content

Conversation

@eramongodb
Copy link
Contributor

@eramongodb eramongodb commented Oct 4, 2023

A minor improvement to the poetry.sh script that works around unintuitive Poetry Python binary selection behavior post-install. The venv created by Poetry doesn't always use the correct Python binary post-install, even if a specific Python binary was used to run the install script. See the linked PR in the comment for further details.

The separate call to with-lock makes me frown, but I could not find a straightforward solution to combine both the Poetry install and run commands, as with-lock does not support using shell functions as the executed command, and Poetry itself doesn't support specifying the Python binary in the install command (user requests for --python <path/to/python> seem to have been rejected; see linked PR). I don't think this will cause issues in practice (it's not that likely that we run into a race condition here), so proposed as-is, but if there's a more elegant solution here that I missed, I'd be happy to apply it.

@eramongodb eramongodb self-assigned this Oct 4, 2023
Copy link
Contributor

@vector-of-bool vector-of-bool left a comment

Choose a reason for hiding this comment

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

This is almost correct, but will probably break subtly in the future. See comment for details.

@eramongodb eramongodb merged commit 843fd5f into mongodb:master Oct 5, 2023
@eramongodb eramongodb deleted the cdriver-poetry branch October 5, 2023 20:02
vector-of-bool pushed a commit to vector-of-bool/mongo-c-driver that referenced this pull request Nov 3, 2023
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.

3 participants