Message13044

Author stefan.richthofer
Recipients stefan.richthofer
Date 2020-04-26.01:04:43
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1587863083.78.0.780656003325.issue2884@roundup.psfhosted.org>
In-reply-to
Content
For the record: I can get it working by modifying the future module as follows:
In standard_library.install_aliases()
out-comment the "Hack for urllib" like so:

    # Hack for urllib so it appears to have the same structure on Py2 as on Py3

    #import urllib
    #from future.backports.urllib import request
    #from future.backports.urllib import response
    #from future.backports.urllib import parse
    #from future.backports.urllib import error
    #from future.backports.urllib import robotparser
    #urllib.request = request
    #urllib.response = response
    #urllib.parse = parse
    #urllib.error = error
    #urllib.robotparser = robotparser
    #sys.modules['urllib.request'] = request
    #sys.modules['urllib.response'] = response
    #sys.modules['urllib.parse'] = parse
    #sys.modules['urllib.error'] = error
    #sys.modules['urllib.robotparser'] = robotparser

No doubt, this nukes some part of future. But for my usecase, it appears, urllib is not required.
History
Date User Action Args
2020-04-26 01:04:43stefan.richthofersetmessageid: <1587863083.78.0.780656003325.issue2884@roundup.psfhosted.org>
2020-04-26 01:04:43stefan.richthofersetrecipients: + stefan.richthofer
2020-04-26 01:04:43stefan.richthoferlinkissue2884 messages
2020-04-26 01:04:43stefan.richthofercreate