I just started using mesonpy and I went through the tutorial and hit a temporary wall that I think could be clarified. When creating a new file but before comiting the file to the git repository, the editable installs worked and the pip install . works. But running pipx run build or python -m build . resulted in
../src/meson.build:10:3: ERROR: File bar.pyx does not exist.
even though the files existed.
If you haven not staged the changes then you get no warning that explains the reason why this is happening.
If you have staged changes, the issue appears earlier in the output with the warning WARNING: Repository has uncommitted changes that will not be included in the dist tarball.
../meson.build:3:0: ERROR: Nonexistent build file 'src/meson.build' also led me down a different rabbit trail that took some time to figure out.
I don't personally think we need to change anything in mesonpy or meson unless catching this is easily done. But I think the https://meson-python.readthedocs.io/en/latest/how-to-guides/config-settings.html wiki page could be reworked into a "Building your package" page that includes a warning about this. I'd be happy to submit a PR with whatever you suggest.
I just started using mesonpy and I went through the tutorial and hit a temporary wall that I think could be clarified. When creating a new file but before comiting the file to the git repository, the editable installs worked and the
pip install .
works. But runningpipx run build
orpython -m build .
resulted inor
even though the files existed.
If you haven not staged the changes then you get no warning that explains the reason why this is happening.
If you have staged changes, the issue appears earlier in the output with the warning
WARNING: Repository has uncommitted changes that will not be included in the dist tarball
.../meson.build:3:0: ERROR: Nonexistent build file 'src/meson.build'
also led me down a different rabbit trail that took some time to figure out.I don't personally think we need to change anything in mesonpy or meson unless catching this is easily done. But I think the https://meson-python.readthedocs.io/en/latest/how-to-guides/config-settings.html wiki page could be reworked into a "Building your package" page that includes a warning about this. I'd be happy to submit a PR with whatever you suggest.