Feature Request
Hi,
I've recently switched from Pipenv to Poetry and so far this is working fine. It's a bit of an annoyance that VSCode does not recognise Poetry virtualenvs automatically like it does with Pipenv, but it's not Poetry's fault and I have a workaround for that anyway. However, there is something I don't understand about the behaviour of poetry new.
Right now, when I want to create a new project, I need to:
- Run
poetry new to create the folder structure for the project with the right names for the folder and package;
- Delete the automatically created
pyproject.toml file in order for the next step to work;
- run
poetry init to create the pyproject.toml I actually want interactively;
- run
poetry install --no-root to initialise the virtual environment.
The problem is that the project.toml created by poetry new lacks various fields like the license and description, and it's a bit weird to have to fill them by hand after poetry new when the poetry init command exists and works so well. But I can't just run poetry init after poetry new because it complains about an already existing pyproject.toml.
In fact, while I understand why one would want poetry init as a separate command, I don't understand why poetry new doesn't automatically call poetry init once it created the folder structure, so that one can build the pyproject.toml interactively. I understand why someone would not always want to do that, but poetry provides the --no-interaction option for that. So why isn't the default behaviour of poetry new to call poetry init, so that one can create the folder structure and the wanted pyproject.toml file in one go? I would expect that to be the most common workflow when creating a new project, so I find it weird that it's not supported out of the box and that I have to go through a weird uncomfortable step (having to erase an automatically created file) in order to make it work.
So I guess my feature request would be to make poetry new run poetry init to create the pyproject.toml file, either by default (with the --no-interaction option to bypass it) or using an option (maybe --init) if you really do not want to change the default behaviour. What do you think?
Feature Request
Hi,
I've recently switched from Pipenv to Poetry and so far this is working fine. It's a bit of an annoyance that VSCode does not recognise Poetry virtualenvs automatically like it does with Pipenv, but it's not Poetry's fault and I have a workaround for that anyway. However, there is something I don't understand about the behaviour of
poetry new.Right now, when I want to create a new project, I need to:
poetry newto create the folder structure for the project with the right names for the folder and package;pyproject.tomlfile in order for the next step to work;poetry initto create thepyproject.tomlI actually want interactively;poetry install --no-rootto initialise the virtual environment.The problem is that the
project.tomlcreated bypoetry newlacks various fields like the license and description, and it's a bit weird to have to fill them by hand afterpoetry newwhen thepoetry initcommand exists and works so well. But I can't just runpoetry initafterpoetry newbecause it complains about an already existingpyproject.toml.In fact, while I understand why one would want
poetry initas a separate command, I don't understand whypoetry newdoesn't automatically callpoetry initonce it created the folder structure, so that one can build thepyproject.tomlinteractively. I understand why someone would not always want to do that, butpoetryprovides the--no-interactionoption for that. So why isn't the default behaviour ofpoetry newto callpoetry init, so that one can create the folder structure and the wantedpyproject.tomlfile in one go? I would expect that to be the most common workflow when creating a new project, so I find it weird that it's not supported out of the box and that I have to go through a weird uncomfortable step (having to erase an automatically created file) in order to make it work.So I guess my feature request would be to make
poetry newrunpoetry initto create thepyproject.tomlfile, either by default (with the--no-interactionoption to bypass it) or using an option (maybe--init) if you really do not want to change the default behaviour. What do you think?