doorstop-dev / doorstop

Requirements management using version control.
https://doorstop.readthedocs.io
Other
465 stars 126 forks source link

Custom item validator per folder #617

Closed lbiaggi closed 5 months ago

lbiaggi commented 7 months ago

Hi @jacebrowning, we have been using doorstop to manage our ISO 26262 requirements, it is part of our core workflow.

We have improved certain areas of the software to match our requirements, and we think it would be useful to share with upstream these changes.

We made these changes because we didn't want to override most of the default behaviour from doorstop, and yet we wanted to be able to tweak certain validations for specific items.

neerdoc commented 7 months ago

@lbiaggi I've had a quick look and it looks very useful! I will do a deeper review and some testing as soon as possible.

lbiaggi commented 7 months ago

The changes looks good as far as I can see, and would possibly fix #564.

The only issue I have is that there are no tests included for the added functionality.

Please add relevant test cases for the added functionality.

Ok!

codecov-commenter commented 7 months ago

Codecov Report

Attention: Patch coverage is 57.14286% with 6 lines in your changes are missing coverage. Please review.

Project coverage is 96.16%. Comparing base (b94019a) to head (70f610d). Report is 2 commits behind head on develop.

Files Patch % Lines
doorstop/core/document.py 57.14% 5 Missing and 1 partial :warning:

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## develop #617 +/- ## ======================================== Coverage 96.15% 96.16% ======================================== Files 41 41 Lines 5173 5185 +12 Branches 1214 1217 +3 ======================================== + Hits 4974 4986 +12 + Misses 127 126 -1 - Partials 72 73 +1 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

lbiaggi commented 7 months ago

Can you re-review @neerdoc? I've inserted tests, updated the sample reqs project and documentation.

lbiaggi commented 7 months ago

@neerdoc no worries, I understand.

How can I propose more drastic changes? (I'm looking to improve and expand references type to be more generic and customizable, e.g., to support external links from another repo.) or at least an interface to create custom references.

neerdoc commented 7 months ago

How can I propose more drastic changes? (I'm looking to improve and expand references type to be more generic and customizable, e.g., to support external links from another repo.) or at least an interface to create custom references.

I would suggest that you first read through all open issues to get a good grasp of what other peoples' opinions are regarding where the software is going. Jump in to whatever discussions there already are and voice you suggestions. If you have new ideas, just open an issue on the subject and we will have a discussion about it!

lbiaggi commented 7 months ago

Should I rebase and fix the conflict?

neerdoc commented 7 months ago

Yes please, that would be very helpful!

lbiaggi commented 7 months ago

Done, if a conflict appears, and I did not update the PR, please ping me

lbiaggi commented 5 months ago

Friendly ping reminder @jacebrowning

jacebrowning commented 5 months ago

@lbiaggi sorry, I haven't had a chance to look at this until now.

I think we should stick to one feature per pull request (and corresponding issue for discussion, if applicable). Since there are three distinct features here, I'd like to see this split up into three separate pull requests that can be reviewed and applied independently.

lbiaggi commented 5 months ago

OK, but bear in mind that I rely on the first one to do the other two

Can I signalize they are dependent? (at least from the first)

jacebrowning commented 5 months ago

Yeah, you can identify that they are dependent or just open the base pull request first.

lbiaggi commented 5 months ago

@jacebrowning done

lbiaggi commented 5 months ago

@jacebrowning ping

jacebrowning commented 5 months ago

@lbiaggi this pull request still seems to contain multiple features: custom item validation and something about changing the SHA that I don't fully understand. I'd like to see this split into two separate pull requests for further review. Thanks!

lbiaggi commented 5 months ago

@lbiaggi this pull request still seems to contain multiple features: custom item validation and something about changing the SHA that I don't fully understand. I'd like to see this split into two separate pull requests for further review. Thanks!

Sorry, IMO they were the same feature because without the SHA, custom validator doesn't seem to be doing something interesting.

I'm not changing the SHA, I'm just calculating the SHA for each file reference...

I will do it now.

lbiaggi commented 5 months ago

@jacebrowning done, sorry for misinterpreting what you meant