Patches item #2787889, was opened at 2009-05-06 16:29 Message generated for change (Comment added) made by siebrand You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=603140&aid=2787889...
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: rewrite Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: liangent (liangent) Assigned to: Nobody/Anonymous (nobody) Summary: getcurrenttime()
Initial Comment: maybe this is better (less cost)
Index: pywikibot/pywikibot/site.py =================================================================== --- pywikibot/pywikibot/site.py (revision 6836) +++ pywikibot/pywikibot/site.py (working copy) @@ -794,10 +794,10 @@
""" r = api.Request(site=self, - action="parse", + action="expandtemplates", text="{{CURRENTTIMESTAMP}}") result = r.submit() - return re.search('\d+', result['parse']['text']['*']).group() + return re.search('\d+', result['expandtemplates']['*']).group()
def getcurrenttime(self): """Return a Timestamp object representing the current server time."""
----------------------------------------------------------------------
Comment By: siebrand (siebrand)
Date: 2009-10-02 11:53
Message: This request may already be outdated, but please attach a proper patch. Otherwise this patch will be rejected for certain after 2 weeks.
----------------------------------------------------------------------
You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=603140&aid=2787889...
pywikipedia-bugs@lists.wikimedia.org