rda-python-dsarch 1.0.21__tar.gz → 1.0.22__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (18) hide show
  1. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/PKG-INFO +1 -1
  2. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/pyproject.toml +1 -1
  3. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch/dsarch.py +19 -19
  4. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch.egg-info/PKG-INFO +1 -1
  5. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/LICENSE +0 -0
  6. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/MANIFEST.in +0 -0
  7. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/README.md +0 -0
  8. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/setup.cfg +0 -0
  9. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch/PgArch.py +0 -0
  10. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch/PgMeta.py +0 -0
  11. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch/__init__.py +0 -0
  12. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch/dsarch.usg +0 -0
  13. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch.egg-info/SOURCES.txt +0 -0
  14. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch.egg-info/dependency_links.txt +0 -0
  15. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch.egg-info/entry_points.txt +0 -0
  16. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch.egg-info/requires.txt +0 -0
  17. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/src/rda_python_dsarch.egg-info/top_level.txt +0 -0
  18. {rda_python_dsarch-1.0.21 → rda_python_dsarch-1.0.22}/tests/test_dsarch.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rda_python_dsarch
3
- Version: 1.0.21
3
+ Version: 1.0.22
4
4
  Summary: RDA Python package for utility program dsarch archive RDA data
5
5
  Author-email: Zaihua Ji <zji@ucar.edu>
6
6
  Project-URL: Homepage, https://github.com/NCAR/rda-python-dsarch
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "rda_python_dsarch"
7
- version = "1.0.21"
7
+ version = "1.0.22"
8
8
  authors = [
9
9
  { name="Zaihua Ji", email="zji@ucar.edu" },
10
10
  ]
@@ -444,7 +444,7 @@ def archive_web_files():
444
444
  vsnctl = 1 if pgrec and pgrec['vindex'] and pgrec['data_size'] else 0
445
445
  chksum = PgOPT.params['MC'][i]
446
446
  if warch and (vsnctl or not override):
447
- info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol'])
447
+ info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
448
448
  if info:
449
449
  if pgrec and chksum and pgrec['checksum'] and pgrec['checksum'] == chksum:
450
450
  PgLOG.pglog("Web-{}: Same-Checksum ARCHIVED at {}:{}".format(winfo, info['date_modified'], info['time_modified']), PgOPT.PGOPT['emllog'])
@@ -512,7 +512,7 @@ def archive_web_files():
512
512
  if not fnames: fnames = PgOPT.get_field_keys(tname, None, "G") # get setting fields if not yet
513
513
  info = None
514
514
  if warch:
515
- info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol'])
515
+ info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
516
516
  elif oarch:
517
517
  info = PgFile.check_object_file(ofile, bucket, 1, PgOPT.PGOPT['emerol'])
518
518
  elif pgrec:
@@ -674,7 +674,7 @@ def archive_help_files():
674
674
 
675
675
  chksum = PgOPT.params['MC'][i]
676
676
  if harch and not OVERRIDE:
677
- info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol'])
677
+ info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
678
678
  if info:
679
679
  if pgrec and chksum and pgrec['checksum'] and pgrec['checksum'] == chksum:
680
680
  PgLOG.pglog("Help-{}: Same-Checksum ARCHIVED at {}:{}".format(hinfo, info['date_modified'], info['time_modified']), PgOPT.PGOPT['emllog'])
@@ -732,7 +732,7 @@ def archive_help_files():
732
732
  if not fnames: fnames = PgOPT.get_field_keys(tname, None, "G") # get setting fields if not yet
733
733
  info = None
734
734
  if harch:
735
- info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol'])
735
+ info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
736
736
  elif oarch:
737
737
  info = PgFile.check_object_file(ofile, bucket, 1, PgOPT.PGOPT['emerol'])
738
738
  elif pgrec:
@@ -895,7 +895,7 @@ def archive_saved_files():
895
895
  vsnctl = 1 if pgrec and pgrec['vindex'] and pgrec['data_size'] else 0
896
896
  chksum = PgOPT.params['MC'][i]
897
897
  if sarch and (vsnctl or not override):
898
- info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol'])
898
+ info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
899
899
  if info:
900
900
  if pgrec and chksum and pgrec['checksum'] and pgrec['checksum'] == chksum:
901
901
  PgLOG.pglog("Saved-{}: Same-Checksum ARCHIVED at {}:{}".format(sinfo, info['date_modified'], info['time_modified']), PgOPT.PGOPT['emllog'])
@@ -959,7 +959,7 @@ def archive_saved_files():
959
959
  if not fnames: fnames = PgOPT.get_field_keys(tname, None, "G") # get setting fields if not yet
960
960
  info = None
961
961
  if sarch:
962
- info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol'])
962
+ info = PgFile.check_local_file(afile, 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
963
963
  elif oarch:
964
964
  info = PgFile.check_object_file(ofile, bucket, 1, PgOPT.PGOPT['emerol'])
965
965
  elif pgrec:
@@ -1059,7 +1059,7 @@ def crosscopy_web_files(aname):
1059
1059
  ofile = PgLOG.join_paths(dsid, wfile)
1060
1060
  warch = oarch = 1
1061
1061
  PgLOG.pglog(winfo + ": Cross {} Web file ...".format(aname), PgLOG.WARNLG)
1062
- info = PgFile.check_local_file(afile, 0, PgOPT.PGOPT['emerol'])
1062
+ info = PgFile.check_local_file(afile, 0, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
1063
1063
  if info:
1064
1064
  warch = 0
1065
1065
  elif info is not None:
@@ -1231,7 +1231,7 @@ def crosscopy_help_files(aname):
1231
1231
  if pgrec and PgOPT.params['HF'][i] != hfile: PgOPT.params['HF'][i] = hfile
1232
1232
  harch = oarch = 1
1233
1233
  PgLOG.pglog(hinfo + ": Cross {} Help file ...".format(aname), PgLOG.WARNLG)
1234
- info = PgFile.check_local_file(afile, 0, PgOPT.PGOPT['emerol'])
1234
+ info = PgFile.check_local_file(afile, 0, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
1235
1235
  if info:
1236
1236
  harch = 0
1237
1237
  elif info is not None:
@@ -1385,7 +1385,7 @@ def crosscopy_saved_files(aname):
1385
1385
  if pgrec and PgOPT.params['SF'][i] != sfile: PgOPT.params['SF'][i] = sfile
1386
1386
  sarch = oarch = 1
1387
1387
  PgLOG.pglog(sinfo + ": Cross {} Saved file ...".format(aname), PgLOG.WARNLG)
1388
- info = PgFile.check_local_file(afile, 0, PgOPT.PGOPT['emerol'])
1388
+ info = PgFile.check_local_file(afile, 0, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
1389
1389
  if info:
1390
1390
  sarch = 0
1391
1391
  elif info is not None:
@@ -1951,12 +1951,12 @@ def get_backup_member_file(pgrec, tarfile, tardir):
1951
1951
  tarcmd = "tar -xvf {} -C {} {}".format(tarfile, tardir, mfile)
1952
1952
  PgLOG.pgsystem(tarcmd, PgOPT.PGOPT['extlog'], 5)
1953
1953
  afile = '{}/{}'.format(tardir, mfile)
1954
- ainfo = PgFile.check_local_file(afile, 0, PgOPT.PGOPT['extlog'])
1954
+ ainfo = PgFile.check_local_file(afile, 0, PgOPT.PGOPT['extlog']|PgLOG.PFSIZE)
1955
1955
 
1956
1956
  if ainfo and mfile != wfile:
1957
1957
  nfile = '{}/{}'.format(tardir, wfile)
1958
1958
  PgFile.move_local_file(nfile, afile, PgOPT.PGOPT['extlog'])
1959
- ainfo = PgFile.check_local_file(nfile, 0, PgOPT.PGOPT['extlog'])
1959
+ ainfo = PgFile.check_local_file(nfile, 0, PgOPT.PGOPT['extlog']|PgLOG.PFSIZE)
1960
1960
 
1961
1961
  return ainfo
1962
1962
 
@@ -2177,7 +2177,7 @@ def crosscopy_backup_files():
2177
2177
  #
2178
2178
  def validate_gladearch(file, ofile, i):
2179
2179
 
2180
- info = PgFile.check_local_file(file, 6, PgOPT.PGOPT['errlog'])
2180
+ info = PgFile.check_local_file(file, 6, PgOPT.PGOPT['errlog']|PgLOG.PFSIZE)
2181
2181
  if not info:
2182
2182
  PgLOG.pglog("Error archiving {} to {}".format(ofile, file), PgLOG.LGEREX)
2183
2183
  elif PgOPT.OPTS['SZ'][2]&2 and PgOPT.params['SZ'] and info['data_size'] != PgOPT.params['SZ'][i]:
@@ -2842,7 +2842,7 @@ def set_one_webfile(i, pgrec, file, flds, type, info = None, ndsid = None, sact
2842
2842
  record['uid'] = PgOPT.PGOPT['UID']
2843
2843
  if not (info and info['date_modified']):
2844
2844
  info = PgFile.check_local_file(PgArch.get_web_path(i, file, 1, type),
2845
- 1, PgOPT.PGOPT['emerol'])
2845
+ 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
2846
2846
  if info:
2847
2847
  record['data_size'] = info['data_size']
2848
2848
  record['date_modified'] = info['date_modified']
@@ -2891,7 +2891,7 @@ def set_one_webfile(i, pgrec, file, flds, type, info = None, ndsid = None, sact
2891
2891
  record['uid'] = PgOPT.PGOPT['UID']
2892
2892
  if 'status' not in record: record['status'] = 'P'
2893
2893
  if not info:
2894
- info = PgFile.check_local_file(PgArch.get_web_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol'])
2894
+ info = PgFile.check_local_file(PgArch.get_web_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
2895
2895
  stat = check_file_flag(file, info, record)
2896
2896
  if not stat: return stat
2897
2897
  if info:
@@ -2922,7 +2922,7 @@ def check_file_flag(file, info, record, pgrec = None):
2922
2922
 
2923
2923
  if not info: return PgLOG.SUCCESS
2924
2924
 
2925
- fflag = 'F' if info['fileflag'] else 'P'
2925
+ fflag = 'F' if info['isfile'] else 'P'
2926
2926
  if 'fileflag' in record:
2927
2927
  if fflag != record['fileflag']:
2928
2928
  return PgLOG.pglog("{}: Cannot set File Flag '{}' to '{}'".format(file, fflag, record['fileflag']), PgOPT.PGOPT['emlerr'])
@@ -3011,7 +3011,7 @@ def set_one_helpfile(i, pgrec, file, flds, type, info = None, ndsid = None):
3011
3011
  if pgrec and (pgrec['status'] == 'D' or PgOPT.PGOPT['ACTS']&PgOPT.OPTS['AH'][0]):
3012
3012
  record['uid'] = PgOPT.PGOPT['UID']
3013
3013
  if not (info and info['date_modified']):
3014
- info = PgFile.check_local_file(PgArch.get_help_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol'])
3014
+ info = PgFile.check_local_file(PgArch.get_help_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
3015
3015
  if info:
3016
3016
  record['data_size'] = info['data_size']
3017
3017
  record['date_modified'] = info['date_modified']
@@ -3050,7 +3050,7 @@ def set_one_helpfile(i, pgrec, file, flds, type, info = None, ndsid = None):
3050
3050
  record['uid'] = PgOPT.PGOPT['UID']
3051
3051
  if 'status' not in record: record['status'] = 'P'
3052
3052
  if not (info or 'url' in record):
3053
- info = PgFile.check_local_file(PgArch.get_help_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol'])
3053
+ info = PgFile.check_local_file(PgArch.get_help_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
3054
3054
  stat = check_file_flag(file, info, record, pgrec)
3055
3055
  if not stat: return stat
3056
3056
  if info:
@@ -3186,7 +3186,7 @@ def set_one_savedfile(i, pgrec, file, flds, type, info = None, ndsid = None, sac
3186
3186
  if pgrec and PgOPT.PGOPT['ACTS']&PgOPT.OPTS['AS'][0]:
3187
3187
  record['uid'] = PgOPT.PGOPT['UID']
3188
3188
  if not (info and info['date_modified']):
3189
- info = PgFile.check_local_file(PgArch.get_saved_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol'])
3189
+ info = PgFile.check_local_file(PgArch.get_saved_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
3190
3190
  if info:
3191
3191
  record['data_size'] = info['data_size']
3192
3192
  record['date_modified'] = info['date_modified']
@@ -3236,7 +3236,7 @@ def set_one_savedfile(i, pgrec, file, flds, type, info = None, ndsid = None, sac
3236
3236
  record['uid'] = PgOPT.PGOPT['UID']
3237
3237
  if 'status' not in record: record['status'] = 'P'
3238
3238
  if not info:
3239
- info = PgFile.check_local_file(PgArch.get_saved_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol'])
3239
+ info = PgFile.check_local_file(PgArch.get_saved_path(i, file, 1, type), 1, PgOPT.PGOPT['emerol']|PgLOG.PFSIZE)
3240
3240
  stat = check_file_flag(file, info, record, pgrec)
3241
3241
  if not stat: return stat
3242
3242
  if info:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rda_python_dsarch
3
- Version: 1.0.21
3
+ Version: 1.0.22
4
4
  Summary: RDA Python package for utility program dsarch archive RDA data
5
5
  Author-email: Zaihua Ji <zji@ucar.edu>
6
6
  Project-URL: Homepage, https://github.com/NCAR/rda-python-dsarch