Closed wanghan-iapcm closed 1 month ago
dpgen2/conf/alloy_conf.py
8-8: `typing.Optional` imported but unused (F401) Remove unused import: `typing.Optional` --- 17-17: `dargs.Variant` imported but unused (F401) Remove unused import: `dargs.Variant` --- 224-224: Loop control variable `ii` not used within loop body (B007) Rename unused `ii` to `_ii` --- 274-274: Do not compare types, use `isinstance()` (E721) --- 274-274: Do not compare types, use `isinstance()` (E721) --- 276-276: Do not compare types, use `isinstance()` (E721) --- 277-277: Do not compare types, use `isinstance()` (E721) --- 277-277: Do not compare types, use `isinstance()` (E721)
dpgen2/conf/alloy_conf.py (3)
`57-57`: Updated type hint for `replicate` parameter to include `Tuple[int, int, int]`. This change allows for more flexible input types, aligning with the PR's objective to fix type hint issues that were causing failures in Pyright. --- `167-167`: Updated type hint for `replicate` parameter in `AlloyConf` class. This change is consistent with the update in `AlloyConfGenerator` and helps in maintaining uniformity across the codebase. --- `357-357`: Updated type hint for `replicate` parameter in `generate_alloy_conf_file_content` function. This ensures that the function's signature is consistent with the changes made in the class definitions, supporting the new tuple format for the `replicate` parameter.
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 84.47%. Comparing base (
fa4c0db
) to head (04794b7
). Report is 4 commits behind head on master.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
which causes pyright failures.
Summary by CodeRabbit
replicate
parameter to accept aTuple[int, int, int]
for more flexible alloy configuration generation.