Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace lru_cache with cache #3413

Merged
merged 3 commits into from
Aug 30, 2024
Merged

Replace lru_cache with cache #3413

merged 3 commits into from
Aug 30, 2024

Conversation

dekkers
Copy link
Contributor

@dekkers dekkers commented Aug 28, 2024

Changes

We don't use the LRU functionality of lru_cache so we can change it to the functools.cache

QA notes

Only the cache function is changed in bytes and bits, so a simple check that the basic KAT functionality of boefjes/normalizers and bits still work should be enough.


Checklist for code reviewers:

Copy-paste the checklist from the docs/source/templates folder into your comment.


Checklist for QA:

Copy-paste the checklist from the docs/source/templates folder into your comment.

@dekkers dekkers requested a review from a team as a code owner August 28, 2024 13:29
@underdarknl underdarknl added tech-debt octopoes Issues related to octopoes labels Aug 28, 2024
@dekkers dekkers self-assigned this Aug 28, 2024
Copy link
Contributor

@ammar92 ammar92 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice one. I've confirmed that there are no other references to lru_cache

@stephanie0x00
Copy link
Contributor

Checklist for QA:

  • I have checked out this branch, and successfully ran a fresh make reset.
  • I confirmed that there are no unintended functional regressions in this branch:
    • I have managed to pass the onboarding flow
    • Objects and Findings are created properly
    • Tasks are created and completed properly
  • I confirmed that the PR's advertised feature or hotfix works as intended.
  • I checked the logs for errors and/or warnings and made issues where necessary

What works:

Seems to work as expected. Onboarding works, enabled extra boefjes which also run. Normalizers run and parse data. The normalizer links work on the Tasks list.

What doesn't work:

n/a

Bug or feature?:

n/a

@underdarknl underdarknl merged commit e91ef99 into main Aug 30, 2024
25 checks passed
@underdarknl underdarknl deleted the replace-lru-cache-with-cache branch August 30, 2024 07:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
octopoes Issues related to octopoes tech-debt
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

4 participants