Skip to content

Conversation

Daraan
Copy link
Contributor

@Daraan Daraan commented Sep 30, 2025

I have a situation where I have a non-list of config files. Looking at the source, any Sequence and even Iterable should be ok as they are instantly consumed.

This PR changes the type of config_files: list[PathLike] to config_files: Iterable[PathLike].


Furthermore chaning the type (to at least Sequence) does not raise type errors for users when they pass a pure list to config_files:

import os

my_config_paths: list[os.PathLike] = []

config_files_argument: list[str | os.PathLike] = config_paths  # type error as list is invariant, should use a covariant type

@codecov-commenter
Copy link

codecov-commenter commented Sep 30, 2025

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.61%. Comparing base (4eea684) to head (858b1bb).
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #167   +/-   ##
=======================================
  Coverage   94.61%   94.61%           
=======================================
  Files           4        4           
  Lines         724      724           
=======================================
  Hits          685      685           
  Misses         39       39           

☔ 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.

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