Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I customize Repl.it to not use poetry?

Tags:

python

repl.it

I am trying to create a Repl.it on my Python project, and when I run, it fails at not finding [tool.poetry] section. And yes my project has a pyproject.toml file.

Repl.it: Updating package configuration

--> /usr/local/bin/python3 -m poetry add halo vistir distlib click packaging tomlkit pip-shims pythonfinder python-cfonts appdirs

[RuntimeError]
[tool.poetry] section not found in pyproject.toml

add [-D|--dev] [--git GIT] [--path PATH] [-E|--extras EXTRAS] [--optional] [--python PYTHON] [--platform PLATFORM] [--allow-prereleases] [--dry-run] [--] <name> (<name>)...

exit status 1


Repl.it: Package operation failed.

The question is, how can I know what is happening in the initializing stage, how does it know what dependencies to install and how can I change the behavior? You can try this repo: github/frostming/pdm for reproduction.

like image 746
Frost Ming Avatar asked Mar 11 '20 07:03

Frost Ming


1 Answers

After importing project you could specify run button behaviour with bash command:

enter image description here

This will be saved to .replit. You could write tings like pip3 install -r requirements.txt && python3 main.py. Read more about available settings in .replit docs


Also there is another doc about dependencies with following quote:

In a pyproject.toml file, you list your packages along with other details about your project. For example, consider the following snippet from pyproject.toml:

...
[tool.poetry.dependencies]
python = "^3.8"
flask = "^1.1"
...
like image 112
Alex Kosh Avatar answered Sep 27 '22 18:09

Alex Kosh