Skip to content

250 add frozen flag#254

Merged
nathanjmcdougall merged 6 commits into
usethis-python:mainfrom
harshithsaiv:250-add-frozen-flag
Feb 4, 2025
Merged

250 add frozen flag#254
nathanjmcdougall merged 6 commits into
usethis-python:mainfrom
harshithsaiv:250-add-frozen-flag

Conversation

@harshithsaiv

Copy link
Copy Markdown
Contributor

• Added support for a new --frozen flag for CLI commands.
The frozen attribute is now part of the global configuration (UsethisConfig) with a corresponding context manager update. The uv subprocess call now appends the "--frozen" flag when enabled.

• Updated _console.py to improve support on Windows, ensuring proper handling of error output and console functionality.

These changes resolve failing test cases related to the --frozen flag and address platform-specific console issues on Windows.

@nathanjmcdougall

nathanjmcdougall commented Feb 4, 2025

Copy link
Copy Markdown
Collaborator

Hi @harshithsaiv, thanks so much for this contribution - it is basically exactly how I would have done it. By addressing the UTF-8 issue, this also closes #49 - although I've added a commit which tweaks the way you've done it.

This project uses some linters, formatters and a type checker - these were failing in CI. If you run uv run pre-commit install in your environment, you will be able to run these checks locally with the command uv run pre-commit run --all-files.

However, I've done this manually for you in this case, so now we'll see whether the CI passes.

@codspeed-hq

codspeed-hq Bot commented Feb 4, 2025

Copy link
Copy Markdown

CodSpeed Performance Report

Merging #254 will not alter performance

Comparing harshithsaiv:250-add-frozen-flag (234fc86) with main (b1df02b)

Summary

✅ 1 untouched benchmarks

nathanjmcdougall added a commit that referenced this pull request Feb 4, 2025
See #254 - there are now multiple contributors.
This was referenced Feb 4, 2025
nathanjmcdougall added a commit that referenced this pull request Feb 4, 2025
See #254 - there are now multiple contributors.
@nathanjmcdougall nathanjmcdougall merged commit 2fad99a into usethis-python:main Feb 4, 2025
@nathanjmcdougall

Copy link
Copy Markdown
Collaborator

Great, all merged. I've also recognized your shared copyright with myself now via #255.

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.

Support --frozen flag for all tools For devs, ensure pytest can be called from CLI on Windows

2 participants