rda-python-common 1.0.36__tar.gz → 1.0.37__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.

Potentially problematic release.


This version of rda-python-common might be problematic. Click here for more details.

Files changed (21) hide show
  1. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/PKG-INFO +1 -1
  2. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/pyproject.toml +1 -1
  3. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/PgLOG.py +7 -9
  4. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common.egg-info/PKG-INFO +1 -1
  5. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/LICENSE +0 -0
  6. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/README.md +0 -0
  7. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/setup.cfg +0 -0
  8. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/PgCMD.py +0 -0
  9. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/PgDBI.py +0 -0
  10. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/PgFile.py +0 -0
  11. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/PgLock.py +0 -0
  12. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/PgOPT.py +0 -0
  13. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/PgSIG.py +0 -0
  14. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/PgSplit.py +0 -0
  15. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/PgUtil.py +0 -0
  16. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common/__init__.py +0 -0
  17. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common.egg-info/SOURCES.txt +0 -0
  18. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common.egg-info/dependency_links.txt +0 -0
  19. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common.egg-info/requires.txt +0 -0
  20. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/src/rda_python_common.egg-info/top_level.txt +0 -0
  21. {rda_python_common-1.0.36 → rda_python_common-1.0.37}/test/test_common.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rda_python_common
3
- Version: 1.0.36
3
+ Version: 1.0.37
4
4
  Summary: RDA Python common library codes shared by other RDA python packages
5
5
  Author-email: Zaihua Ji <zji@ucar.edu>
6
6
  Project-URL: Homepage, https://github.com/NCAR/rda-python-common
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "rda_python_common"
7
- version = "1.0.36"
7
+ version = "1.0.37"
8
8
  authors = [
9
9
  { name="Zaihua Ji", email="zji@ucar.edu" },
10
10
  ]
@@ -402,15 +402,11 @@ def pglog(msg, logact = MSGLOG):
402
402
  if logact&EMLLOG: logact &= ~EMLLOG
403
403
  if not logact&ERRLOG: logact &= ~EMEROL
404
404
 
405
- if msg: msg = msg.lstrip() # remove leading whitespaces for logging message
406
-
405
+ msg = msg.lstrip() if msg else '' # remove leading whitespaces for logging message
407
406
  if logact&EXITLG:
408
407
  ext = "Exit 1 in {}\n".format(os.getcwd())
409
- if not msg:
410
- msg = ext
411
- else:
412
- msg = msg.rstrip()
413
- msg += "; " + ext
408
+ if msg: msg = msg.rstrip() + "; "
409
+ msg += ext
414
410
  else:
415
411
  if msg and not re.search(r'(\n|\r)$', msg): msg += "\n"
416
412
  if logact&RETMSG: retmsg = msg
@@ -418,7 +414,8 @@ def pglog(msg, logact = MSGLOG):
418
414
  if logact&EMLALL:
419
415
  if logact&SNDEML or not msg:
420
416
  title = (msg if msg else "Message from {}-{}".format(PGLOG['HOSTNAME'], get_command()))
421
- msg = send_email(title.rstrip())
417
+ msg = title + '\n' + msg
418
+ send_email(title.rstrip())
422
419
  elif msg:
423
420
  set_email(msg, logact)
424
421
 
@@ -428,7 +425,8 @@ def pglog(msg, logact = MSGLOG):
428
425
  if not logact&EMLALL: set_email(msg, logact)
429
426
  title = "ABORTS {}-{}".format(PGLOG['HOSTNAME'], get_command())
430
427
  set_email((("ABORTS " + CPID['PID']) if CPID['PID'] else title), EMLTOP)
431
- msg += send_email(title)
428
+ msg = title + '\n' + msg
429
+ send_email(title)
432
430
 
433
431
  if logact&LOGERR: # make sure error is always logged
434
432
  msg = break_long_string(msg)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rda_python_common
3
- Version: 1.0.36
3
+ Version: 1.0.37
4
4
  Summary: RDA Python common library codes shared by other RDA python packages
5
5
  Author-email: Zaihua Ji <zji@ucar.edu>
6
6
  Project-URL: Homepage, https://github.com/NCAR/rda-python-common