Open sevendays opened 4 years ago
I found the root issue. The CSV file had the lines arranged like this:
Requirement reference,Requirement version,Design element
#F001,f1cf87320d9ddf5da0c58212c0fa4c4b3cfd84ad,root_system
But this does not match the regex defined in doorstop\core\reference_finder.py:
pattern = r"(\b|\W){}(\b|\W)".format(re.escape(keyword))
The regex wants something before the actual keyword. See example: https://regex101.com/r/2LryAs/2
A correct regex might be this one, with a quantifier:
pattern = r"(\b|\W)*{}(\b|\W)".format(re.escape(keyword))
Example: https://regex101.com/r/AOYY4E/1
As a workaround I'm rearranging the CSV columns in order to let the keyword appear in the second column (not at the line beginning). But I believe that this is a bug, and the documentation does not mention that the keyword should not be at the beginning of the line.
I'm editing the bug title since it is misleading.
I'm trying to use the new
references
behaviour as described in the wiki: https://doorstop.readthedocs.io/en/latest/reference/item/#references-new-array-behaviorMy requirement is:
The file
F_allocation.csv
is in the git repository root (I have tried both/
and\
for relative paths).Running
doorstop
raises no errors, and draws the requirement tree.However, running
doorstop publish F Fmd
crashes: