add mode option -WS for action SW#73
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new -WS / -WithFileSize mode option intended to refresh (recheck) web-file size/timestamp metadata in the database, primarily for the -SW (SetWebFile) action.
Changes:
- Register new mode option
WS(WithFileSize) in the option table. - Update
set_one_webfile()to refresh file metadata when-WSis provided. - Update usage documentation and bump package version to
2.0.16.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
src/rda_python_dsarch/pg_arch.py |
Adds WS to the option registry so it can be parsed/recognized. |
src/rda_python_dsarch/dsarch.usg |
Documents the new -WS/-WithFileSize option and its intended usage with -SW. |
src/rda_python_dsarch/dsarch.py |
Enables metadata refresh for existing web-file records when -WS is present. |
pyproject.toml |
Version bump to 2.0.16. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| in the output. | ||
|
|
||
| -WS or -WithFileSize, rechecks Web file sizes and timestamps for | ||
| provided web files with -WF (-WebFile), and updates them into GDEXDB |
| -(SC|SetChecksum) - computes MD5 checksums for files on the GDEX | ||
| Server and saves them to GDEXDB | ||
| -(WS|WithFileSize) - gathers file size information for Web files on the GDEX | ||
| Server and saves them to GDEXDB |
Comment on lines
+2648
to
2651
| if pgrec and (pgrec['status'] == 'D' or 'WS' in self.params or self.PGOPT['ACTS']&self.OPTS['AW'][0]): | ||
| record['uid'] = self.PGOPT['UID'] | ||
| if not (info and info['date_modified']): | ||
| info = self.check_local_file(self.get_web_path(i, file, 1, type), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.