roedoejet / g2p

Grapheme-to-Phoneme transductions that preserve input and output indices, and support cross-lingual g2p!
https://g2p-studio.herokuapp.com
Other
119 stars 26 forks source link

misc repo maintenance stuff #369

Closed joanise closed 2 months ago

joanise commented 3 months ago

From https://jorisroovers.com/gitlint/latest/installation/:

By default, gitlint is installed with pinned dependencies. To install gitlint with looser dependency requirements, only install gitlint-core

We don't want gitlint's pinned requirements to cause trouble, which they did when I tried to install ReadAlongs/Studio in a sandbox where the latest g2p was already installed with .[dev].

github-actions[bot] commented 3 months ago
CLI load time: 0:00.05
PR head 16751a61cddfc164fe6a4c67650341089304b4c8
Imports that take more than 0.1 s:
import time: self [us] | cumulative | imported package
codecov[bot] commented 3 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 93.36%. Comparing base (14cb98a) to head (b071222).

:exclamation: Current head b071222 differs from pull request most recent head 16751a6. Consider uploading reports for the commit 16751a6 to get more accurate results

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #369 +/- ## ======================================= Coverage 93.36% 93.36% ======================================= Files 17 17 Lines 2427 2427 Branches 542 542 ======================================= Hits 2266 2266 Misses 92 92 Partials 69 69 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

joanise commented 3 months ago

This PR is growing with more stuff I discover as I try to clean it up...

1) it's been annoying me how PRs that don't touch code often lose a little bit a coverage. I think I found out why, and added some tests in test_studio.py to fix that.

2) mypy complained about a bunch of stuff. typing extensions: --install-types fixes that, added it to .pre-commit-config.yaml (it would be nice to have the pre-commit mypy see the pyproject.toml tool.hatch.envs.dev.scripts options, but I'm not sure that's realistic. -- Ah-ha! Found it: added install_types and non_interactive to [tool.mypy] in pyproject.toml.

dhdaines commented 2 months ago

From https://jorisroovers.com/gitlint/latest/installation/:

By default, gitlint is installed with pinned dependencies. To install gitlint with looser dependency requirements, only install gitlint-core

We don't want gitlint's pinned requirements to cause trouble, which they did when I tried to install ReadAlongs/Studio in a sandbox where the latest g2p was already installed with .[dev].

oh oops! my fault!

dhdaines commented 2 months ago
  1. mypy complained about a bunch of stuff. typing extensions: --install-types fixes that, added it to .pre-commit-config.yaml (it would be nice to have the pre-commit mypy see the pyproject.toml tool.hatch.envs.dev.scripts options, but I'm not sure that's realistic. -- Ah-ha! Found it: added install_types and non_interactive to [tool.mypy] in pyproject.toml.

Ah good! For a while there I had tried running mypy --install-types --non-interactive when creating the dev environment but this is a bad idea since it will actually run the mypy checks (and there is no way to disable this) so if you have any errors, creating the environment will fail.