I have a simple project layout myproject on main [$!?] is v1.0.0 via v18.14.0 via v3.10.9 ❯ tree -L 1 . ├── build ├── deploy ├── Dockerfile ├── poetry.lock ├── pyproject.toml ├── README.md ├── scripts.py └── src The pyproject.toml is: [tool.poetry] name = "myproject" version = "0.1.0" description = "" authors = [""] [tool.poetry.scripts] test = "scripts:test" The scripts.py is: import subprocess def test(): """ Run all unittests. """ subprocess.run( ['python', '-u', '-m', 'pytest'] ) if __name__ == '__main__': test() When I run poetry run test: myproject on main [$!?] is v1.0.0 via v18.14.0 via v3.10.9 No file/folder found for package myproject Continue reading...