Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #90979

Re: No ttk in 2.7

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!1.eu.feeder.erje.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <ian.g.kelly@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.003
X-Spam-Evidence '*H*': 0.99; '*S*': 0.00; ';-)': 0.03; 'importerror:': 0.07; 'tkinter': 0.07; 'cest': 0.09; 'lost.': 0.09; 'raises': 0.09; 'subject:2.7': 0.09; 'try:': 0.09; 'chained': 0.16; 'clause,': 0.16; 'importerror,': 0.16; 'wrote:': 0.18; 'wed,': 0.18; 'import': 0.22; 'error': 0.23; 'wednesday': 0.24; 'first,': 0.26; 'second': 0.26; 'header:In-Reply-To:1': 0.27; 'raise': 0.29; 'message-id:@mail.gmail.com': 0.30; 'except': 0.35; 'something': 0.35; 'received:google.com': 0.35; 'there': 0.35; 'wrong': 0.37; 'to:addr:python-list': 0.38; 'pm,': 0.38; 'to:addr:python.org': 0.39; 'simply': 0.61; 'first': 0.61; 'details': 0.65; '20,': 0.68; '2015': 0.84
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=dSrXiPgn5OFYBcuK7caFSV6rFS4xpY801pZUByh+5mY=; b=J0rlihv60JlI3uTcsMFBGcmLR0XuCTCyN+j2CE+QmRfmgfGy+oy2Axze1Djokmx2RT J/IQ6+SmDUFhwQx6xhmSwvbV3JeHMy1H7uR7K+Z2rRcqYhY2A517T9rLOuB4CA00BeWI ANbKYzdsYgQOAP8npVW1W05C6hEBhyfwvEyVDfPqSNeyI/JqK58n1SVpS459p7yWawmN /B9K6c3fBjpt4UuHGVdgoCHOCCAdz1K0RMdqWnSij5vGh5KCJ1IIhGXYx//Vb26KlWUz 3zTch/VQ9PbJbDxkOjjQB6fZHdoPSp80wewyRdYjA/3d5JhnkKTXmuOslK/OdrkhotDI tasg==
X-Received by 10.50.30.69 with SMTP id q5mr12064895igh.11.1432150252872; Wed, 20 May 2015 12:30:52 -0700 (PDT)
MIME-Version 1.0
In-Reply-To <87egmbqdtp.fsf@Equus.decebal.nl>
References <87r3qbqlve.fsf@Equus.decebal.nl> <mailman.179.1432141452.17265.python-list@python.org> <87egmbqdtp.fsf@Equus.decebal.nl>
From Ian Kelly <ian.g.kelly@gmail.com>
Date Wed, 20 May 2015 13:30:12 -0600
Subject Re: No ttk in 2.7
To Python <python-list@python.org>
Content-Type text/plain; charset=UTF-8
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>
Newsgroups comp.lang.python
Message-ID <mailman.183.1432150260.17265.python-list@python.org> (permalink)
Lines 18
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1432150260 news.xs4all.nl 2940 [2001:888:2000:d::a6]:57358
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:90979

Show key headers only | View raw


On Wed, May 20, 2015 at 12:54 PM, Cecil Westerhof <Cecil@decebal.nl> wrote:
> Op Wednesday 20 May 2015 19:03 CEST schreef Zachary Ware:
>> try:
>> import tkinter as tk
>> from tkinter import ttk
>> except ImportError:
>> import Tkinter as tk
>> import ttk
>
> When there goes something wrong with:
>     from tkinter import ttk
> you will not understand what is happening. ;-)

If something goes wrong with the first import and raises an
ImportError, then it will execute the except clause, which will
definitely raise an ImportError. In this case the second error will
simply be chained onto the first, so the details of the first error
won't be lost.

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

No ttk in 2.7 Cecil Westerhof <Cecil@decebal.nl> - 2015-05-20 18:01 +0200
  Re: No ttk in 2.7 Ned Batchelder <ned@nedbatchelder.com> - 2015-05-20 09:43 -0700
    Re: No ttk in 2.7 Ned Batchelder <ned@nedbatchelder.com> - 2015-05-20 09:47 -0700
      Re: No ttk in 2.7 Cecil Westerhof <Cecil@decebal.nl> - 2015-05-20 20:52 +0200
        Re: No ttk in 2.7 Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-05-20 21:55 +0100
    Re: No ttk in 2.7 Cecil Westerhof <Cecil@decebal.nl> - 2015-05-20 20:51 +0200
  Re: No ttk in 2.7 Zachary Ware <zachary.ware+pylist@gmail.com> - 2015-05-20 12:03 -0500
    Re: No ttk in 2.7 Cecil Westerhof <Cecil@decebal.nl> - 2015-05-20 20:54 +0200
      Re: No ttk in 2.7 Ian Kelly <ian.g.kelly@gmail.com> - 2015-05-20 13:30 -0600
  Re: No ttk in 2.7 Sturla Molden <sturla.molden@gmail.com> - 2015-05-21 14:04 +0000

csiph-web