Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Issue #27171: Fix typos in documentation, comments, and test function names | Martin Panter | 2016-06-02 | 1 | -2/+2 |
| | |||||
* | Issue #27076: Doc, comment and tests spelling fixes | Martin Panter | 2016-05-26 | 1 | -1/+1 |
| | | | | Most fixes to Doc/ and Lib/ directories by Ville Skyttä. | ||||
* | Issue#26616:Fixed a bug in datetime.astimezone() method. | Alexander Belopolsky | 2016-03-25 | 1 | -1/+6 |
| | |||||
* | Closes issue #23600: Wrong results from tzinfo.fromutc(). | Alexander Belopolsky | 2015-09-28 | 1 | -1/+1 |
| | |||||
* | Merge 3.4 (datetime rounding) | Victor Stinner | 2015-09-18 | 1 | -11/+63 |
|\ | |||||
| * | Issue #23517: Fix rounding in fromtimestamp() and utcfromtimestamp() methods | Victor Stinner | 2015-09-18 | 1 | -8/+63 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | of datetime.datetime: microseconds are now rounded to nearest with ties going to nearest even integer (ROUND_HALF_EVEN), instead of being rounding towards zero (ROUND_DOWN). It's important that these methods use the same rounding mode than datetime.timedelta to keep the property: (datetime(1970,1,1) + timedelta(seconds=t)) == datetime.utcfromtimestamp(t) It also the rounding mode used by round(float) for example. Add more unit tests on the rounding mode in test_datetime. | ||||
* | | Issue #25155: Add _PyTime_AsTimevalTime_t() function | Victor Stinner | 2015-09-18 | 1 | -4/+5 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Windows, the tv_sec field of the timeval structure has the type C long, whereas it has the type C time_t on all other platforms. A C long has a size of 32 bits (signed inter, 1 bit for the sign, 31 bits for the value) which is not enough to store an Epoch timestamp after the year 2038. Add the _PyTime_AsTimevalTime_t() function written for datetime.datetime.now(): convert a _PyTime_t timestamp to a (secs, us) tuple where secs type is time_t. It allows to support dates after the year 2038 on Windows. Enhance also _PyTime_AsTimeval_impl() to detect overflow on the number of seconds when rounding the number of microseconds. | ||||
* | | Issue #23501: Argumen Clinic now generates code into separate files by default. | Serhiy Storchaka | 2015-04-03 | 1 | -35/+3 |
| | | |||||
* | | Issue #22117: Fix rounding of fromtimestamp() methods of datetime.datetime and | Victor Stinner | 2015-03-29 | 1 | -2/+3 |
| | | | | | | | | | | datetime.time: round towards minus infinity ("floor") instead of rounding towards zero ("down"). | ||||
* | | Issue #22117: Use the _PyTime_t API in _datetime.datetime() constructor | Victor Stinner | 2015-03-29 | 1 | -4/+14 |
| | | | | | | | | | | * Remove _PyTime_gettimeofday() * Add _PyTime_GetSystemClock() | ||||
* | | Closes issue #22791: Improved datetime from timestamp methods documentation. | Alexander Belopolsky | 2015-03-01 | 1 | -2/+1 |
| | | | | | | | | Original patch by Akira Li. | ||||
* | | merge | Raymond Hettinger | 2014-07-25 | 1 | -7/+7 |
|\ \ | |/ | |||||
| * | Issue #22044: Fixed premature DECREF in call_tzinfo_method. | Raymond Hettinger | 2014-07-25 | 1 | -7/+7 |
| | | |||||
* | | remove the ability of datetime.time to be considered false (closes #13936) | Benjamin Peterson | 2014-03-20 | 1 | -37/+1 |
|/ | |||||
* | Issue #20320: select.select() and select.kqueue.control() now round the timeout | Victor Stinner | 2014-02-16 | 1 | -2/+2 |
| | | | | | | aways from zero, instead of rounding towards zero. It should make test_asyncio more reliable, especially test_timeout_rounding() test. | ||||
* | Issue #20530: Argument Clinic's signature format has been revised again. | Larry Hastings | 2014-02-09 | 1 | -2/+4 |
| | | | | | | | The new syntax is highly human readable while still preventing false positives. The syntax also extends Python syntax to denote "self" and positional-only parameters, allowing inspect.Signature objects to be totally accurate for all supported builtins in Python 3.4. | ||||
* | Issue #20326: Argument Clinic now uses a simple, unique signature to | Larry Hastings | 2014-01-28 | 1 | -3/+3 |
| | | | | | | | | | | annotate text signatures in docstrings, resulting in fewer false positives. "self" parameters are also explicitly marked, allowing inspect.Signature() to authoritatively detect (and skip) said parameters. Issue #20326: Argument Clinic now generates separate checksums for the input and output sections of the block, allowing external tools to verify that the input has not changed (and thus the output is not out-of-date). | ||||
* | Issue #20390: Small fixes and improvements for Argument Clinic. | Larry Hastings | 2014-01-26 | 1 | -1/+1 |
| | |||||
* | Issue #20189: Four additional builtin types (PyTypeObject, | Larry Hastings | 2014-01-24 | 1 | -7/+7 |
| | | | | | | PyMethodDescr_Type, _PyMethodWrapper_Type, and PyWrapperDescr_Type) have been modified to provide introspection information for builtins. Also: many additional Lib, test suite, and Argument Clinic fixes. | ||||
* | Issue #19273: The marker comments Argument Clinic uses have been changed | Larry Hastings | 2014-01-07 | 1 | -6/+6 |
| | | | | to improve readability. | ||||
* | Silence more PyObject_INIT() unused value warnings. | Christian Heimes | 2013-12-04 | 1 | -2/+2 |
| | |||||
* | Issue #19674: inspect.signature() now produces a correct signature | Larry Hastings | 2013-11-23 | 1 | -4/+8 |
| | | | | for some builtins. | ||||
* | Issue #19730: Argument Clinic now supports all the existing PyArg | Larry Hastings | 2013-11-23 | 1 | -5/+5 |
| | | | | | "format units" as legacy converters, as well as two new features: "self converters" and the "version" directive. | ||||
* | Argument Clinic: rename "self" to "module" for module-level functions. | Larry Hastings | 2013-11-18 | 1 | -11/+12 |
| | |||||
* | Issue #19437: Fix datetime_subtract(), handle new_delta() failure | Victor Stinner | 2013-11-07 | 1 | -0/+3 |
| | |||||
* | Issue #19514: Deduplicate some _Py_IDENTIFIER declarations. | Martin v. Löwis | 2013-11-07 | 1 | -14/+5 |
| | | | | Patch by Andrei Dorian Duma. | ||||
* | Issue #16612: Add "Argument Clinic", a compile-time preprocessor | Larry Hastings | 2013-10-19 | 1 | -17/+57 |
| | | | | for C files to generate argument parsing code. (See PEP 436.) | ||||
* | _datetimemodule.c: fix the compilation warning "conversion from 'double' to | Victor Stinner | 2013-08-27 | 1 | -1/+1 |
| | | | | | 'long', possible loss of data" in delta_new(), use an explicit cast from double to long | ||||
* | Issue #18783: Removed existing mentions of Python long type in docstrings, | Serhiy Storchaka | 2013-08-27 | 1 | -7/+7 |
|\ | | | | | | | error messages and comments. | ||||
| * | Issue #18783: Removed existing mentions of Python long type in docstrings, | Serhiy Storchaka | 2013-08-27 | 1 | -7/+7 |
| | | | | | | | | error messages and comments. | ||||
* | | Reuse us_per_second in delta_total_seconds. | Alexander Belopolsky | 2013-08-04 | 1 | -9/+1 |
| | | |||||
* | | Fixes #8860: Round half-microseconds to even in the timedelta constructor. | Alexander Belopolsky | 2013-08-04 | 1 | -18/+31 |
| | | | | | | | | (Original patch by Mark Dickinson.) | ||||
* | | Fix NULL ptr dereferencing in local_timezone(). nameo can be NULL | Christian Heimes | 2013-06-29 | 1 | -1/+1 |
| | | | | | | | | | | CID 1040362 (#1 of 1): Explicit null dereferenced (FORWARD_NULL) var_deref_op: Dereferencing null pointer _py_decref_tmp. | ||||
* | | Fix time.mktime() and datetime.datetime.timestamp() on AIX | Victor Stinner | 2013-06-25 | 1 | -3/+10 |
| | | | | | | | | | | | | On AIX, the C function mktime() alwaysd sets tm_wday, even on error. So tm_wday cannot be used as a sentinel to detect an error, we can only check if the result is (time_t)-1. | ||||
* | | Issue #17917: Use PyModule_AddIntMacro() instead of PyModule_AddIntConstant() | Charles-Francois Natali | 2013-05-20 | 1 | -2/+2 |
|/ | | | | when applicable. | ||||
* | Fix a few typos and a double semicolon. Patch by Eitan Adler. | Ezio Melotti | 2013-01-27 | 1 | -1/+1 |
| | |||||
* | Issue #16096: Fix several occurrences of potential signed integer overflow. ↵ | Mark Dickinson | 2012-10-06 | 1 | -4/+3 |
| | | | | Thanks Serhiy Storchaka. | ||||
* | Closes #15973: fix a segmentation fault when comparing timezone objects. | Georg Brandl | 2012-09-22 | 1 | -0/+6 |
| | |||||
* | Issue #9527: tm_gmtoff has 'correct' sign. | Alexander Belopolsky | 2012-06-22 | 1 | -7/+3 |
| | |||||
* | Fixed compiler warnings in datetime_astimezone() | Alexander Belopolsky | 2012-06-22 | 1 | -4/+5 |
| | |||||
* | Issue #9527: Fixes for platforms without tm_zone | Alexander Belopolsky | 2012-06-22 | 1 | -20/+22 |
| | |||||
* | Issue #9527: datetime.astimezone() method will now supply a class | Alexander Belopolsky | 2012-06-22 | 1 | -4/+82 |
| | | | | | timezone instance corresponding to the system local timezone when called with no arguments. | ||||
* | Issue #15006: Allow equality comparison between naive and aware time | Alexander Belopolsky | 2012-06-16 | 1 | -0/+16 |
| | | | | or datetime objects. | ||||
* | Issue #2736: Added datetime.timestamp() method. | Alexander Belopolsky | 2012-06-08 | 1 | -0/+49 |
| | |||||
* | Issue #14180: datetime.date.fromtimestamp(), datetime.datetime.fromtimestamp() | Victor Stinner | 2012-03-13 | 1 | -36/+39 |
| | | | | | and datetime.datetime.utcfromtimestamp() now raise an OSError instead of ValueError if localtime() or gmtime() failed. | ||||
* | Close #14180: Factorize code to convert a number of seconds to time_t, ↵ | Victor Stinner | 2012-03-13 | 1 | -32/+13 |
| | | | | | | | | | | | | | timeval or timespec time.ctime(), gmtime(), time.localtime(), datetime.date.fromtimestamp(), datetime.datetime.fromtimestamp() and datetime.datetime.utcfromtimestamp() now raises an OverflowError, instead of a ValueError, if the timestamp does not fit in time_t. datetime.datetime.fromtimestamp() and datetime.datetime.utcfromtimestamp() now round microseconds towards zero instead of rounding to nearest with ties going away from zero. | ||||
* | Remove an unnecessary extra copy of the bytes hash function. | Gregory P. Smith | 2012-01-14 | 1 | -15/+1 |
| | | | | | | | | | This copy also had a bug in it, it fails to incorporate the length into the hash by using it as the loop variable so it'll always be -1 by the time it is XORed in. As such: I'm doing this only in Python 3.3 and not backporting as it would change the existing hash behavior of datetime objects. | ||||
* | Fix misuse of PyUnicode_GET_SIZE() => PyUnicode_GET_LENGTH() | Victor Stinner | 2011-11-21 | 1 | -2/+2 |
| | | | | And PyUnicode_GetSize() => PyUnicode_GetLength() | ||||
* | Rename _Py_identifier to _Py_IDENTIFIER. | Martin v. Löwis | 2011-10-14 | 1 | -19/+19 |
| | |||||
* | Use identifier API for PyObject_GetAttrString. | Martin v. Löwis | 2011-10-10 | 1 | -2/+4 |
| |