Skip to content

Commit

Permalink
Make version error terser and ignore pyright issue
Browse files Browse the repository at this point in the history
  • Loading branch information
tkkuehn committed Aug 8, 2023
1 parent d19c80f commit 2923cc0
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions snakebids/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,8 @@ def _get_app_version(self: SnakeBidsApp) -> str | None:
return metadata.version(self.snakemake_dir.name)
except metadata.PackageNotFoundError:
logger.warning(
"This Snakebids app's version could not be found. This will not generally "
"affect the app's functioning, but its version will be recorded as "
'"unknown" in the output config file. If you\'ve installed the app into '
"your python environment, this is likely caused by the app maintainer's "
"version implementation being non-standard, and only the app maintainer "
"could correct the versioning. In that case, this message can be ignored."
"App version not found; will be recorded in output as 'unknown'. "
"If this is unexpected, please contact the app maintainer."
)
return None

Expand Down Expand Up @@ -143,7 +139,9 @@ class SnakeBidsApp:
"""

snakemake_dir: Path = attr.ib(converter=lambda path: Path(path).resolve())
snakemake_dir: Path = attr.ib(
converter=lambda path: Path(path).resolve() # type: ignore
)
plugins: list[Callable[[SnakeBidsApp], None | SnakeBidsApp]] = attr.Factory(list)
skip_parse_args: bool = False
parser: argparse.ArgumentParser = create_parser()
Expand Down

0 comments on commit 2923cc0

Please sign in to comment.