Skip to content

Conversation

@tyll
Copy link
Member

@tyll tyll commented Jan 8, 2026

A small change to use more conscious language and more a more meaningful variable name.

Summary by Sourcery

Enhancements:

  • Rename internal variables in network connection removal logic to use more meaningful, conscious terminology.

@sourcery-ai
Copy link

sourcery-ai bot commented Jan 8, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Refactors variable naming in network_connections.py to use more inclusive and descriptive terminology while preserving existing behavior for selecting which NetworkManager profiles to keep or delete.

File-Level Changes

Change Details Files
Rename blacklist-related variable to a more descriptive and inclusive name without changing logic for determining which profiles are preserved.
  • Rename the local variable from black_list_names to kept_profiles in the absent action path.
  • Update the assignment when selecting all non-absent connection names to use kept_profiles instead of black_list_names.
  • Ensure the loopback device name 'lo' is added to kept_profiles so it is always preserved.
  • Adjust the membership check to test nm_profile IDs against kept_profiles instead of black_list_names.
library/network_connections.py

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey - I've left some high level feedback:

  • To keep the type of kept_profiles consistent across both branches and avoid list vs. set semantics, initialize it as a set() when name is truthy (instead of []), since in the else branch it is a set and you are using membership checks that are more efficient on sets.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- To keep the type of `kept_profiles` consistent across both branches and avoid list vs. set semantics, initialize it as a `set()` when `name` is truthy (instead of `[]`), since in the `else` branch it is a set and you are using membership checks that are more efficient on sets.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@codecov
Copy link

codecov bot commented Jan 8, 2026

Codecov Report

❌ Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 43.22%. Comparing base (1b57520) to head (4cdbeee).
⚠️ Report is 61 commits behind head on main.

Files with missing lines Patch % Lines
library/network_connections.py 0.00% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #834      +/-   ##
==========================================
+ Coverage   43.11%   43.22%   +0.10%     
==========================================
  Files          12       12              
  Lines        3124     3123       -1     
==========================================
+ Hits         1347     1350       +3     
+ Misses       1777     1773       -4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@richm richm merged commit 3d7a3f8 into linux-system-roles:main Jan 8, 2026
30 of 35 checks passed
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.

2 participants