Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #98931
| Path | csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail |
|---|---|
| From | Alex Naumov <alexander_naumov@opensuse.org> |
| Newsgroups | comp.lang.python |
| Subject | Re: HTTPSConnection from http.client? |
| Date | Tue, 17 Nov 2015 16:47:05 +0100 |
| Lines | 76 |
| Sender | posix.ru@gmail.com |
| Message-ID | <mailman.394.1447775667.16136.python-list@python.org> (permalink) |
| References | <CABPy6+zYvqmOFy7aMNMH0DtUNaaJ3M3nR47QPhDPijsvN2jHbA@mail.gmail.com> <n2f2mb$qoo$1@ger.gmane.org> <CABPy6+zTajMJ8uoPxADbs7hzhVt31XoxGg_NZtaTYwL=LDMwBw@mail.gmail.com> <n2f9qv$gv4$1@ger.gmane.org> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=UTF-8 |
| X-Trace | news.uni-berlin.de 1BtNh7EawWJOgxotpH7Fiwm1rEb3J7oish1kc4ZlCLKA== |
| Return-Path | <posix.ru@gmail.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.008 |
| X-Spam-Evidence | '*H*': 0.98; '*S*': 0.00; 'error:': 0.05; 'importerror:': 0.05; 'cc:addr:python-list': 0.09; 'https': 0.09; 'python': 0.10; 'importing': 0.15; 'packages.': 0.15; 'broken,': 0.16; 'http.client': 0.16; 'module?': 0.16; 'received:io': 0.16; 'received:psf.io': 0.16; 'to:addr:web.de': 0.16; 'traceback.': 0.16; 'wrote:': 0.16; 'sender:addr:gmail.com': 0.18; 'alex': 0.18; 'ssl': 0.18; '>>>': 0.20; '2015': 0.20; 'cc:2**0': 0.20; 'cc:addr:python.org': 0.20; 'please?': 0.22; 'cc:no real name:2**0': 0.22; 'seems': 0.23; 'thanks,': 0.24; 'second': 0.24; 'tried': 0.24; 'import': 0.24; 'header:In-Reply-To:1': 0.24; 'module': 0.25; 'install': 0.25; 'message-id:@mail.gmail.com': 0.27; 'package.': 0.27; 'idea': 0.28; 'skip:( 20': 0.28; 'looks': 0.29; 'succeed': 0.29; 'url:client': 0.29; 'there.': 0.30; 'connection': 0.30; 'url:mailman': 0.30; 'connections': 0.30; 'minimal': 0.30; 'somebody': 0.30; 'post': 0.31; 'another': 0.32; '[1]': 0.32; 'anybody': 0.32; 'maybe': 0.33; 'url:python': 0.33; 'url:listinfo': 0.34; 'tue,': 0.34; 'received:google.com': 0.35; 'nov': 0.35; 'something': 0.35; 'reply.': 0.35; 'but': 0.36; 'should': 0.36; 'url:org': 0.36; 'received:209.85': 0.36; 'url:library': 0.36; 'subject:?': 0.36; 'pm,': 0.36; 'subject:: ': 0.37; 'thanks': 0.37; 'available.': 0.37; 'missing': 0.37; 'no,': 0.38; 'received:209': 0.38; 'log': 0.38; 'thank': 0.38; 'does': 0.39; 'subject:from': 0.39; 'url:mail': 0.40; 'where': 0.40; 'hello,': 0.40; 'some': 0.40; 'url:3': 0.60; 'your': 0.60; 'skip:u 10': 0.61; 'day': 0.67; 'url:http': 0.75; '2:24': 0.84; 'otten': 0.84; 'peter,': 0.84; 'subject:skip:H 10': 0.84; 'sorry.': 0.91; 'source?': 0.91 |
| DKIM-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=VJRX3oXlEAxAaGMvSN/flLasAsc00LNTE0hMBR+MA2w=; b=D9n9T66fNheavcDHhGIlcpDomhlrKmidIXKSDXmA76zfCcolt2uqWPXK8HQ4cRYsbc cJzVW0hyLwWMMkTQS0M4rprf4utNfC3q6wxkuwE8J+VZYPZYQBTe54xe8oukhxvxD9lb qxjNOBuo9DpqCesK766U+KUfAhsLrBaoigi3E4vcN8CnOieGIYrBFpQZHW8Ji1c75D4a 28vPwGPfd3nP/jf7xJaeDakF+T55t4TGmBZbzpDQ26WCvNhsfmHESA/cPx3hEseAdvES 1JfxGdeIPYUhRjfz6kxL8Nheh0FshSA/OMJMQPQMlmVk2zC3y0uynLJSHXrICtF6Nxbw hWnw== |
| X-Received | by 10.112.13.98 with SMTP id g2mr19720803lbc.18.1447775225126; Tue, 17 Nov 2015 07:47:05 -0800 (PST) |
| In-Reply-To | <n2f9qv$gv4$1@ger.gmane.org> |
| X-Google-Sender-Auth | Kd7Z1U2jEoxSpqdCpJSZW3lLp7A |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.20+ |
| Precedence | list |
| List-Id | General discussion list for the Python programming language <python-list.python.org> |
| List-Unsubscribe | <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe> |
| List-Archive | <http://mail.python.org/pipermail/python-list/> |
| List-Post | <mailto:python-list@python.org> |
| List-Help | <mailto:python-list-request@python.org?subject=help> |
| List-Subscribe | <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe> |
| Xref | csiph.com comp.lang.python:98931 |
Show key headers only | View raw
Hello Peter, thanks for your reply. >>> import ssl Works well in python2 and 3. Maybe somebody know another way to create a SSL connection (username/password)? I just need to log in and log out. Thanks, Alex On Tue, Nov 17, 2015 at 2:24 PM, Peter Otten <__peter__@web.de> wrote: > Alex Naumov wrote: > >> On Tue, Nov 17, 2015 at 12:22 PM, Peter Otten <__peter__@web.de> wrote: >>> Alex Naumov wrote: >>> >>>> Hello, >>>> >>>> does anybody know how to create a HTTPS connections in python2 or >>>> python3? I tried second day to do that with http.client[1], but every >>>> time get error: >>>> >>>> from http.client import HTTPSConnection >>>> ImportError: cannot import name HTTPSConnection >>>> >>>> >>>> Where is HTTPSConnection located? Which module? >>>> >>>> I use openSUSE 13.1 x86_64. >>>> >>>> Thank you, >>>> Alex >>>> >>>> >>>> [1] https://docs.python.org/3/library/http.client.html >>> >>> Did you compile Python from source? >> >> No, I install it as a package. >> >>> You may be missing the development >>> packages. >> >> Yes, it looks like some packages are not there. >> >> >>> On a minimal SLES-12-x86_64 installation: >> >> Can you tell me what's the name of package with http.client module please? > > You already have that module as it is part of the Python standard > installation. You can double check by importing something that is always > available. E. g. the following should succeed on your system > >>>> from http.client import HTTPConnection >>>> > > What you are likely missing is ssl support. Try > >>>> import ssl > > to verify that it fails and post the traceback. > > Unfortunately my conclusion from Marco's post is that > >>>> from http.client import HTTPSConnection > > should succeed on your system without the need for additional packages. > Something seems to be broken, but I have no idea what, sorry. > > -- > https://mail.python.org/mailman/listinfo/python-list
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Re: HTTPSConnection from http.client? Alex Naumov <alexander_naumov@opensuse.org> - 2015-11-17 16:47 +0100
csiph-web