Ruff linting#32
Conversation
|
Please don't spend too much time on |
|
I do not plan to spend more time in a near future, and for most repo it took me 5 to 15 minutes to fork + creates issues + make change + PR, this one took me maybe 30 or 45 minutes, this is OK. But let me know if there is some other repos with heavy rework planned before monorepo that I should skip. |
This should be the only one! |
Co-authored-by: Erik Schamper <1254028+Schamper@users.noreply.github.com>
|
@Schamper is there anything else that needs to be done on this pr? I am going to change this project in the style of the other projects and thought of using these changes as a base |
This is a temporary measure with a lot of untill it gets refactored to something more sane and functional
|
I pushed the other changes to completely fix the ruff linting to this branch. It also contains the typehints, tho those are up to change once the actual refactoring of the project takes place. |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #32 +/- ##
==========================================
+ Coverage 80.90% 81.28% +0.38%
==========================================
Files 9 17 +8
Lines 885 919 +34
==========================================
+ Hits 716 747 +31
- Misses 169 172 +3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
|
||
| if TYPE_CHECKING: | ||
| from dissect.eventlog.utils import KeyValueCollection | ||
|
|
There was a problem hiding this comment.
I was wondering, do we have references to documentation explaning what these classes model?
There was a problem hiding this comment.
I added a docstring with a reference to what I initially used to get to these answers
This PR replace flake/blake/isort with ruff, as used in other dissect project.
Partially fix #26
This would require additional works, especially regarding typing but this will probably be easier to review in a different PR.
Regarding Ignored rules, I have the following statistics of what should be fixed if PT, ANN, RUF AND C4 are enabled.
I do not plan to work on it in a near time and fixing some of these issue would require dig more in the codebase, to ensure it does not break anything.
Even if it does not fully fix the issue, is better than nothing. IMO Original issue should be amended to specify work left to do, and this commit added to
.git-blame-ignore-revs