community-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1690555 - /comdev/projects.apache.org/scripts/cronjobs/countaccounts.py
Date Sun, 12 Jul 2015 23:58:12 GMT
Author: sebb
Date: Sun Jul 12 23:58:11 2015
New Revision: 1690555

URL: http://svn.apache.org/r1690555
Log:
Ensure generated files don't have spurious trailing spaces

Modified:
    comdev/projects.apache.org/scripts/cronjobs/countaccounts.py

Modified: comdev/projects.apache.org/scripts/cronjobs/countaccounts.py
URL: http://svn.apache.org/viewvc/comdev/projects.apache.org/scripts/cronjobs/countaccounts.py?rev=1690555&r1=1690554&r2=1690555&view=diff
==============================================================================
--- comdev/projects.apache.org/scripts/cronjobs/countaccounts.py (original)
+++ comdev/projects.apache.org/scripts/cronjobs/countaccounts.py Sun Jul 12 23:58:11 2015
@@ -1,5 +1,11 @@
 #!/usr/bin/env python
 
+import sys
+# The output from json.dumps() has a trailing space in Python2, it is absent in Python3
+# So ensure we always use the same python version as the crontab
+if sys.hexversion < 0x030000F0:
+    raise RuntimeError("This script requires Python3")
+
 """
 Extracts data showing the number of accounts created each month.
 



Mime
View raw message