-
Notifications
You must be signed in to change notification settings - Fork 222
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
docs: Python Tutorial: Dependencies, PyPI, Order, Grammar #1313
Conversation
I was searching the documentation for a way to install optional dependencies from PyPI using pixi and got helped on the Discord. I figured the Python tutorial is the most straightforward place to add this, while the functionality is still being developed. I have taken this chance to slightly adjust the flow of the tutorial and used Grammarly Premium to work through the grammar and sprinkle in some commas.
docs/tutorials/python.md
Outdated
|
||
## pixi.toml and pyproject.toml | ||
We support two manifests formats, `pyproject.toml` and `pixi.toml`. In this tutorial we will use the `pyproject.toml` format. Because it is the most common format for python projects. | ||
Pixi builds upon the conda ecosystem, which allows you to create a Python environment with all the dependencies you need. This is especially useful when you are working with multiple Python interpreters and bindings to C and C++ libraries. Let's give it a go! For example, GDAL from PyPI does not have binary C dependencies, but the condom package does. However, some packages are only available through PyPI, which is why we can explicitly add those as a fallback to be solved together by pixi. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What package does? 😨
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Quite a few honestly.
My employer for example almost exclusively publishes them on PyPI so far. The framework my website uses (Nikola) only has a "community package on conda" last updated over a year ago and the recommended install is pip. In my world most people try to use pip first before conda and because of some clunkiness around conda itself (despite mamba) steered away from using conda.
But I'm definitely not an expert on this. Just my limited experience.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just noticed from this comment that it say "condom" package, I think it should be "conda" 😃
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh lord. That's embarrassing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@JesperDramsch, yeah I got the sentence as it is the hard truth we have to concur with pixi. I was indeed joking on the name 😅
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ruben-arts heh, I'm too autistic to catch that sorry 😅
docs: reformat and extend python tutorial
He @JesperDramsch, Thanks for helping us improve the tutorial. I gave it another pass. The amount of line changes in my commit have to do with that I like the "single sentence per line" principle. Which wasn't used in the tutorial yet. |
Thanks for the follow up @ruben-arts those single-line changes make absolute sense to me. I wasn't sure if I should change them all, as that would've been an artificially huge PR from a newcomer, so glad you took those on. |
LGTM and @ruben-arts will merge! |
Thanks everyone! |
I was searching the documentation for a way to install optional dependencies from PyPI using pixi and got helped on the Discord.
I figured the Python tutorial is the most straightforward place to add this, while the functionality is still being developed.
I have taken this chance to slightly adjust the flow of the tutorial and used Grammarly Premium to work through the grammar and sprinkle in some commas.