Skip to content

Commit 8343029

Browse files
committed
validation: allow bundled example CSVs in release artifacts
1 parent eb368dd commit 8343029

1 file changed

Lines changed: 13 additions & 5 deletions

File tree

‎validation/check_artifacts.py‎

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -83,14 +83,22 @@ def artifact_failures(directory: Path) -> list[str]:
8383
package_files = {path.removeprefix("src/") for path in _python_files(_PACKAGE)} | {
8484
"ml4t/backtest/py.typed"
8585
}
86-
expected_wheel = package_files | {
87-
f"{dist_info}/METADATA",
88-
f"{dist_info}/WHEEL",
89-
f"{dist_info}/licenses/LICENSE",
90-
f"{dist_info}/RECORD",
86+
package_data = {
87+
path.relative_to(_ROOT).as_posix() for path in (_PACKAGE / "example_data").glob("*.csv")
9188
}
89+
expected_wheel = (
90+
package_files
91+
| {path.removeprefix("src/") for path in package_data}
92+
| {
93+
f"{dist_info}/METADATA",
94+
f"{dist_info}/WHEEL",
95+
f"{dist_info}/licenses/LICENSE",
96+
f"{dist_info}/RECORD",
97+
}
98+
)
9299
expected_sdist = (
93100
_python_files(_PACKAGE)
101+
| package_data
94102
| _python_files(_TESTS)
95103
| set().union(*(_data_files(path) for path in _APPROVED_TEST_DATA))
96104
| {

0 commit comments

Comments
 (0)