Skip to content

Commit deecc99

Browse files
committed
rmdir instead of copy, because of modtime woes
1 parent afc5d1e commit deecc99

1 file changed

Lines changed: 14 additions & 11 deletions

File tree

docs/developer/release/release_build.py

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -219,17 +219,20 @@ def build_checker_framework_release(
219219
print(f"Copying from: {dev_website_relative_dir}\n to: {DEV_SITE_DIR}")
220220
ensure_group_access(dev_website_relative_dir)
221221
ensure_user_access(dev_website_relative_dir)
222-
# When run with copy_function=shutil.copy2 (the default), it raises Error if
223-
# it cannot set the modification time. On Unix systems, only the owner or
224-
# root (not someone in the group) can set the modification time. shutil.copy
225-
# doesn't preserve modification time, so use it instead of shutil.copy2.
226-
# An alternative would be to delete the destination before calling copytree.
227-
shutil.copytree(
228-
str(dev_website_relative_dir),
229-
str(DEV_SITE_DIR),
230-
copy_function=shutil.copy,
231-
dirs_exist_ok=True,
232-
)
222+
223+
# # This did not work, so do the deletion instead.
224+
# # When run with copy_function=shutil.copy2 (the default), it raises Error if
225+
# # it cannot set the modification time. On Unix systems, only the owner or
226+
# # root (not someone in the group) can set the modification time. shutil.copy
227+
# # doesn't preserve modification time, so use it instead of shutil.copy2.
228+
# # An alternative would be to delete the destination before calling copytree.
229+
# shutil.copytree(
230+
# str(dev_website_relative_dir),
231+
# str(DEV_SITE_DIR),
232+
# copy_function=shutil.copy,
233+
# dirs_exist_ok=True,
234+
# )
235+
os.rmdir(DEV_SITE_DIR)
233236

234237

235238
def commit_to_interm_projects(cf_version: str) -> None:

0 commit comments

Comments
 (0)