rda-python-common 1.0.37__tar.gz → 1.0.38__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.37 → rda_python_common-1.0.38}/PKG-INFO +1 -1
  2. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/pyproject.toml +1 -1
  3. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/PgLOG.py +4 -3
  4. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/PgOPT.py +4 -2
  5. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common.egg-info/PKG-INFO +1 -1
  6. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/LICENSE +0 -0
  7. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/README.md +0 -0
  8. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/setup.cfg +0 -0
  9. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/PgCMD.py +0 -0
  10. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/PgDBI.py +0 -0
  11. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/PgFile.py +0 -0
  12. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/PgLock.py +0 -0
  13. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/PgSIG.py +0 -0
  14. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/PgSplit.py +0 -0
  15. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/PgUtil.py +0 -0
  16. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common/__init__.py +0 -0
  17. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common.egg-info/SOURCES.txt +0 -0
  18. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common.egg-info/dependency_links.txt +0 -0
  19. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common.egg-info/requires.txt +0 -0
  20. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/src/rda_python_common.egg-info/top_level.txt +0 -0
  21. {rda_python_common-1.0.37 → rda_python_common-1.0.38}/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.37
3
+ Version: 1.0.38
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.37"
7
+ version = "1.0.38"
8
8
  authors = [
9
9
  { name="Zaihua Ji", email="zji@ucar.edu" },
10
10
  ]
@@ -251,7 +251,7 @@ def send_customized_email(logmsg, emlmsg, logact = 0):
251
251
  entries = {
252
252
  'fr' : ["From", 1, None],
253
253
  'to' : ["To", 1, None],
254
- 'cc' : ["Cc", 0, None],
254
+ 'cc' : ["Cc", 0, ''],
255
255
  'sb' : ["Subject", 1, None]
256
256
  }
257
257
 
@@ -293,7 +293,8 @@ def send_email(subject = None, receiver = None, msg = None, sender = None, logac
293
293
  return send_python_email(subject, receiver, msg, sender, None, logact)
294
294
 
295
295
  #
296
- # send an email via python module smtplib; if empty msg send email message saved in PGLOG['EMLMSG'] instead
296
+ # send an email via python module smtplib; if empty msg send email message saved
297
+ # in PGLOG['EMLMSG'] instead. pass cc = '' for skipping 'Cc: '
297
298
  #
298
299
  def send_python_email(subject = None, receiver = None, msg = None, sender = None, cc = None, logact = 0):
299
300
 
@@ -321,7 +322,7 @@ def send_python_email(subject = None, receiver = None, msg = None, sender = None
321
322
  emlmsg['From'] = sender
322
323
  emlmsg['To'] = receiver
323
324
  logmsg = "Email " + receiver
324
- if not cc: cc = PGLOG['CCDADDR']
325
+ if cc == None: cc = PGLOG['CCDADDR']
325
326
  if cc:
326
327
  emlmsg['Cc'] = cc
327
328
  logmsg += " Cc'd " + cc
@@ -1682,8 +1682,10 @@ def send_request_email_notice(pgrqst, errmsg, fcount, rstat, readyfile = None, p
1682
1682
  einfo['GLOBUS_TASK_URL'] = "https://app.globus.org/activity/" + pgrqst['task_id']
1683
1683
 
1684
1684
  for ekey in einfo:
1685
- ebuf = re.sub(r'<{}>'.format(ekey), einfo[ekey], ebuf)
1686
-
1685
+ if ekey == 'CCD' and not einfo['CCD']:
1686
+ ebuf = re.sub(r'Cc:\s*<CCD>\s*', '', ebuf)
1687
+ else:
1688
+ ebuf = re.sub(r'<{}>'.format(ekey), einfo[ekey], ebuf)
1687
1689
 
1688
1690
  if PgLOG.PGLOG['DSCHECK'] and not pgpart:
1689
1691
  tbl = "dscheck"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rda_python_common
3
- Version: 1.0.37
3
+ Version: 1.0.38
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