Skip to content

Conversation

@ogenstad
Copy link
Contributor

@ogenstad ogenstad commented Jan 27, 2026

Summary by CodeRabbit

  • Improvements

    • The NoRecorder class now properly implements hash support, making instances hashable and compatible with sets and dictionaries for more flexible usage patterns.
  • Code Quality

    • Strengthened linting rules to enforce proper implementation of hashing methods, improving code consistency and preventing related issues across the codebase.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link

coderabbitai bot commented Jan 27, 2026

Walkthrough

The changes involve adding hash functionality to the NoRecorder class and updating the linting configuration. A __hash__ method is implemented in the NoRecorder class that returns hash(self.__class__), making instances hashable. Simultaneously, the PLW1641 rule (which warns about missing __hash__ implementations) is removed from the Ruff ignore list in pyproject.toml, enabling enforcement of this lint rule during code analysis.

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: adding a hash method to the NoRecorder class that already has eq, which directly addresses the PLW1641 lint rule.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@cloudflare-workers-and-pages
Copy link

Deploying infrahub-sdk-python with  Cloudflare Pages  Cloudflare Pages

Latest commit: 2b01488
Status: ✅  Deploy successful!
Preview URL: https://8a12623b.infrahub-sdk-python.pages.dev
Branch Preview URL: https://pog-plw1641.infrahub-sdk-python.pages.dev

View logs

@codecov
Copy link

codecov bot commented Jan 27, 2026

Codecov Report

❌ Patch coverage is 50.00000% with 1 line in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
infrahub_sdk/recorder.py 50.00% 1 Missing ⚠️
@@            Coverage Diff             @@
##           stable     #780      +/-   ##
==========================================
- Coverage   80.37%   80.36%   -0.01%     
==========================================
  Files         115      115              
  Lines        9863     9865       +2     
  Branches     1504     1504              
==========================================
+ Hits         7927     7928       +1     
- Misses       1414     1415       +1     
  Partials      522      522              
Flag Coverage Δ
integration-tests 41.41% <0.00%> (-0.01%) ⬇️
python-3.10 51.38% <0.00%> (-0.02%) ⬇️
python-3.11 51.36% <0.00%> (-0.02%) ⬇️
python-3.12 51.38% <0.00%> (+<0.01%) ⬆️
python-3.13 51.38% <0.00%> (+<0.01%) ⬆️
python-3.14 53.01% <0.00%> (-0.04%) ⬇️
python-filler-3.12 24.07% <50.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
infrahub_sdk/recorder.py 85.71% <50.00%> (-1.79%) ⬇️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ogenstad ogenstad marked this pull request as ready for review January 28, 2026 07:45
@ogenstad ogenstad requested a review from a team as a code owner January 28, 2026 07:45
@ogenstad ogenstad merged commit aeba8d8 into stable Jan 28, 2026
21 checks passed
@ogenstad ogenstad deleted the pog-PLW1641 branch January 28, 2026 09:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants