diff --git a/setup.py b/setup.py index 7588c000f..9120c7fe0 100644 --- a/setup.py +++ b/setup.py @@ -196,6 +196,7 @@ def _write_version_files(): print("INFO: Didn't find sha. Is this a git repo?") with open(_ROOT_DIR / "src/torchcodec/version.py", "w") as f: + f.write("# Note that this file is generated during install.\n") f.write(f"__version__ = '{version}'\n") diff --git a/src/torchcodec/__init__.py b/src/torchcodec/__init__.py index 2b83eb035..e96aa5b33 100644 --- a/src/torchcodec/__init__.py +++ b/src/torchcodec/__init__.py @@ -10,6 +10,7 @@ from . import decoders, samplers # noqa try: + # Note that version.py is generated during install. from .version import __version__ # noqa: F401 except Exception: pass