https://pantsbuild.org/ logo
#general
Title
# general
j

jolly-midnight-72759

10/16/2020, 1:50 AM
What is the best command to see which projects will throw a
pants.source.source_root.NoSourceRootError
? Right now I'm running my plugin command and getting these errors one by one because I have some mistakes in my
pants.toml
.
h

hundreds-father-404

10/16/2020, 1:55 AM
./pants roots
will show what Pants classifies as a source root in general. To trigger that particular error, You need to run something that considers source roots: *
test
*
lint
with Pylint in particular *
run
* `binary`/`package`/`setup-py`
Did you make changes to your
[source]
section recently in the upgrade?
j

jolly-midnight-72759

10/16/2020, 1:57 AM
I didn't have "/" in the
root_patterns
list.
Once I added that everything worked.
💯 1
(Although taking it out let me find all the places that we are breaking our pattern.)
./pants roots
doesn't throw an error if
root_patterns
is missing some patterns.
This is an edge case that has more to do with how long our repo has been using
pants
than it does with the upgrade.
👍 1
Some of what we are doing should of been refactored when we upgraded to v1.8.0. 🙂
👍 1
5 Views