Skip to content

Commit 12b4770

Browse files
thanay-sisirclaude
andcommitted
Removed housekeeping.py changes to keep PR single-feature
Now check the changes I have done..... Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 83f1f5f commit 12b4770

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

utils/housekeeping.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,18 +9,20 @@
99

1010
def zip_python_code(output_filename):
1111
"""
12-
Zips all .py files in the current repository and saves it to the
12+
Zips all .py files in the current repository and saves it to the
1313
specified output filename.
1414
1515
Args:
16-
output_filename: The name of the output zip file.
16+
output_filename: The name of the output zip file.
1717
Defaults to "python_code_backup.zip".
1818
"""
1919

2020
with zipfile.ZipFile(output_filename, 'w') as zipf:
2121
files = glob.glob('models/**/*.py', recursive=True) + glob.glob('utils/**/*.py', recursive=True) + glob.glob('tasks/**/*.py', recursive=True) + glob.glob('*.py', recursive=True)
2222
for file in files:
23-
zipf.write(file, arcname=file)
23+
root = '/'.join(file.split('/')[:-1])
24+
nm = file.split('/')[-1]
25+
zipf.write(os.path.join(root, nm))
2426

2527
def set_seed(seed=42, deterministic=True):
2628
"""

0 commit comments

Comments
 (0)