Author vstinner
Recipients Nan Zhang, p-ganssle, vstinner
Date 2019-09-17.20:46:00
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1568753161.22.0.434198935219.issue30367@roundup.psfhosted.org>
In-reply-to
Content
It seems like this issue has been fixed in 3.8 and master branches (I didn't test Python 3.7): see below.

I close the issue. Reopen/comment the issue if you consider that Python 3.7 should be fixed as well.


I made this change:

$ git diff
diff --git a/Modules/Setup b/Modules/Setup
index 983fa014ec..ff2fd14857 100644
--- a/Modules/Setup
+++ b/Modules/Setup
@@ -151,6 +151,10 @@ _symtable symtablemodule.c
 # modules are to be built as shared libraries (see above for more
 # detail; also note that *static* or *disabled* cancels this effect):
 
+*static*
+
+_datetime _datetimemodule.c    # datetime accelerator
+
 #*shared*
 
 # GNU readline.  Unlike previous Python incarnations, GNU readline is
@@ -177,7 +181,6 @@ _symtable symtablemodule.c
 #_random _randommodule.c       # Random number generator
 #_elementtree -I$(srcdir)/Modules/expat -DHAVE_EXPAT_CONFIG_H -DUSE_PYEXPAT_CAPI _elementtree.c        # elementtree accelerator
 #_pickle _pickle.c     # pickle accelerator
-#_datetime _datetimemodule.c   # datetime accelerator
 #_bisect _bisectmodule.c       # Bisection algorithms
 #_heapq _heapqmodule.c # Heap queue algorithm
 #_asyncio _asynciomodule.c  # Fast asyncio Future


I built Python: it works as expected, _datetime is a built-in module:

$ ./python
Python 3.9.0a0 (heads/master-dirty:46b0b81220, Sep 17 2019, 22:42:19) 
[GCC 9.2.1 20190827 (Red Hat 9.2.1-1)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import _datetime
>>> _datetime
<module '_datetime' (built-in)>


Note:

$ make
...
The following modules found by detect_modules() in setup.py, have been
built by the Makefile instead, as configured by the Setup files:
_abc                  _datetime             atexit             
pwd                   time                                     
...
History
Date User Action Args
2019-09-17 20:46:01vstinnersetrecipients: + vstinner, p-ganssle, Nan Zhang
2019-09-17 20:46:01vstinnersetmessageid: <1568753161.22.0.434198935219.issue30367@roundup.psfhosted.org>
2019-09-17 20:46:01vstinnerlinkissue30367 messages
2019-09-17 20:46:00vstinnercreate