Skip to content

Dev.ej/relax click#299

Merged
joanise merged 2 commits intomainfrom
dev.ej/relax-click
Apr 20, 2026
Merged

Dev.ej/relax click#299
joanise merged 2 commits intomainfrom
dev.ej/relax-click

Conversation

@joanise
Copy link
Copy Markdown
Member

@joanise joanise commented Apr 15, 2026

PR Goal?

Clean up dependencies

It was not hard to adapt the Studio to more recent versions of click:

  • adapting to more recent clicks just requires looking at results.stdout + results.stderr results.output instead of just results.stdout; doing so in a try catch lets me remain is compatible with old and new versions
  • give the --config option to align a default value of None so that we don't get click's new Sentinel.UNSET value now provided with an option with an argument but no default is not specified by the user.

Fixes?

Unnecessary lockage of dependencies in the past

Also disable silencing C stderr when running with Pytest: a) pytest already captures all output, and b) doing so again under pytest's feet breaks things.

Feedback sought?

sanity checking

Priority?

low

Tests added?

well covered by CI

How to test?

In a g2p sandbox, checkout and install NRC-ILT/g2p#485:

git checkout dev.ej/relax-click
pip install -e . --upgrade

In a Studio sandbox, checkout and install this PR, in the same venv you ran that g2p install in

git checkout dev.ej/relax-click
pip install -e .[dev] --upgrade

Then run the tests as you usually do, e.g.:

pytest

I also have branch dev.ej/misc-deps-cleanup which sets the g2p dependency on github@dev.ej/relax-click, so you can test on that branch. And I ran Matrix testing on that branch: see https://github.com/ReadAlongs/Studio/actions/runs/24367223612

Confidence?

high

Version change?

Yes, I plan to release a patch to publish these relaxed dependencies.

@semanticdiff-com
Copy link
Copy Markdown

semanticdiff-com Bot commented Apr 15, 2026

Review changes with  SemanticDiff

Changed Files
File Status
  tests/basic_test_case.py  60% smaller
  pyproject.toml Unsupported file format
  readalongs/cli.py  0% smaller
  tests/test_align_cli.py  0% smaller
  tests/test_make_xml_cli.py  0% smaller

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 15, 2026

CLI load time: 0:00.05
Pull Request HEAD: e8fd9247749e52158e2470af510dff45f7a2ef9e
No imports take more than 0.1 s.

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 15, 2026

Codecov Report

❌ Patch coverage is 94.44444% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 95.20%. Comparing base (a2b3ec1) to head (e8fd924).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
tests/basic_test_case.py 50.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #299   +/-   ##
=======================================
  Coverage   95.20%   95.20%           
=======================================
  Files          43       43           
  Lines        3673     3674    +1     
=======================================
+ Hits         3497     3498    +1     
  Misses        176      176           

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

@joanise joanise requested review from deltork and roedoejet April 15, 2026 14:14
stderr is no longer mixed with stdout, but it is always included in
result.output with old and new versions of click
@joanise joanise force-pushed the dev.ej/relax-click branch from a32af68 to e8fd924 Compare April 16, 2026 14:48
@joanise joanise merged commit 4ae6d24 into main Apr 20, 2026
7 of 8 checks passed
@joanise joanise deleted the dev.ej/relax-click branch April 20, 2026 18:47
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.

1 participant