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


Groups > comp.lang.python > #101881

Re: When is an int not an int? Who can explain this?

Path csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail
From Ian Kelly <ian.g.kelly@gmail.com>
Newsgroups comp.lang.python
Subject Re: When is an int not an int? Who can explain this?
Date Mon, 18 Jan 2016 10:00:28 -0700
Lines 24
Message-ID <mailman.92.1453136470.15297.python-list@python.org> (permalink)
References <n7j2r0$hc4$1@dont-email.me> <mailman.89.1453134008.15297.python-list@python.org> <n7j3s1$hc4$2@dont-email.me> <CAPTjJmqGS3ZNP5qxHU+DZerJ5k15dKdCp9HXa7cdDUH1Fzmo+w@mail.gmail.com>
Mime-Version 1.0
Content-Type text/plain; charset=UTF-8
X-Trace news.uni-berlin.de WwU0YBvPZUDjdCkpQgg3MACFRsKpUeZ7D2iLoLRpfxdQ==
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.013
X-Spam-Evidence '*H*': 0.97; '*S*': 0.00; 'received:209.85.223': 0.03; 'called.': 0.09; 'imported': 0.09; 'int.': 0.09; 'subclass': 0.09; 'jan': 0.11; 'subject:not': 0.11; '(float)': 0.16; '(int)': 0.16; '2016': 0.16; 'received:io': 0.16; 'received:psf.io': 0.16; 'transcript': 0.16; 'wrote:': 0.16; 'string': 0.17; 'posted': 0.21; 'file.': 0.22; 'am,': 0.23; 'header:In-Reply-To:1': 0.24; 'mon,': 0.24; 'module': 0.25; 'chris': 0.26; 'question': 0.27; 'message-id:@mail.gmail.com': 0.27; 'callable': 0.29; 'there!': 0.29; 'though,': 0.32; 'curious': 0.33; 'int': 0.33; 'tue,': 0.34; 'received:google.com': 0.35; 'next': 0.35; 'should': 0.36; 'received:209.85': 0.36; 'loaded': 0.36; 'to:addr:python-list': 0.36; 'subject:?': 0.36; 'subject:: ': 0.37; 'received:209': 0.38; 'to:addr:python.org': 0.40; 'where': 0.40; 'information,': 0.61; 'now:': 0.72; 'smith': 0.76; 'start.': 0.84; 'subject:When': 0.84; 'to:name:python': 0.84; 'subject:this': 0.85; 'armed': 0.91; 'subject:Who': 0.91
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=WP6X0ARuquvTQsWMawPlXI4T9X5uAbo1e93kPv5u228=; b=Z7b4SGMtsyrsg+WlldO8Mv7+PMznzSQ+pfhrxSsfJ969g3Bbyk8YaC3nPBxlOqs4TW 89LH6/E365VJpBfCY7ObfPYoE0cml6O6XEIiVBKojWKtsNwZpfsU78ZLq3hSdBCBhIoJ ixdOWyFVDn5hSFkPWJRPRq1y8aB9uFH7JvKlrEZ3O8z5LXuAkQMLzqzF4VXS6UdocuGC 2LFW2nFI3J/bAV6CD/Z5XWHMmE3oHgRwewp5+5KAwRkY3VH3wXm6yiB2sL2wBzNg40Y/ 79ZLLNiRFPNHwSQ+5I/DEtmW5/IaMilLdmwSzUWY2ZYQ0Jj+BjeYyZoZx4Xa36bmmZT4 S2Mw==
X-Google-DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:content-type; bh=WP6X0ARuquvTQsWMawPlXI4T9X5uAbo1e93kPv5u228=; b=CU9shAwYAgcNnJ7q2zP8GDhtXEHVasEb7zrGxbX6gaB6PdZLb5P7GryvzCU6MZfOjl OfbpJUAeAwIwg4VYdYATkagBYzK8RNQ6bIDV9abgAWnQNRVu1cK68IJYfK2fVfGSyBFY fWVUpk7xneIKzS54MUwhbS9SkT0qBxuqgS20ZqTzWadwxRLR5q+GIauBNS4bfxsew317 IxIPuN7Yu3iUnIHgSDz1uX2L6yuSj+y25UMKSBW2weYKXBew3c/BfbmTujIfoIi4jJsQ QohhYru8dz0ADwJd2odQngttCAFouXaN0yipTnMh0d8zyZY3h76sZjFjLPp+LiaF64vy 0dVQ==
X-Gm-Message-State ALoCoQmzPzWbdW3JbvhaOi0RwWvnl0nTvFEObWzxoT6bIlwsWsV9cvoB0iDXglt11BO1fyyTJLLOmoQJjfq9AHgrf/A1QbuH1A==
X-Received by 10.107.185.6 with SMTP id j6mr22966721iof.111.1453136467798; Mon, 18 Jan 2016 09:01:07 -0800 (PST)
In-Reply-To <CAPTjJmqGS3ZNP5qxHU+DZerJ5k15dKdCp9HXa7cdDUH1Fzmo+w@mail.gmail.com>
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:101881

Show key headers only | View raw


On Mon, Jan 18, 2016 at 9:51 AM, Chris Angelico <rosuav@gmail.com> wrote:
> On Tue, Jan 19, 2016 at 3:28 AM, Charles T. Smith
>> Okay, I think I understand it now:
>>
>> (PDB)type (int)
>> <type 'module'>
>>
>> (PDB)type (float)
>> <type 'type'>
>
> And that's pretty strong evidence right there! So the next question
> is... what got imported under the name 'int'?
>
> int.__name__ will be a start. If that just returns the string 'int',
> then try int.__package__ which might give a hint. Also, int.__file__
> will tell you where it was loaded from, if it was indeed loaded from a
> file.
>
> Armed with that information, you should be able to track down what's
> going on. It's curious, though, that you have a callable subclass of
> module bound to the name int. Very curious indeed.

What makes you think that it's a callable subclass? I don't see any
place in the posted transcript where int has been called.

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


Thread

When is an int not an int?  Who can explain this? "Charles T. Smith" <cts.private.yahoo@gmail.com> - 2016-01-18 16:11 +0000
  Re: When is an int not an int? Who can explain this? Chris Angelico <rosuav@gmail.com> - 2016-01-19 03:19 +1100
    Re: When is an int not an int? Who can explain this? "Charles T. Smith" <cts.private.yahoo@gmail.com> - 2016-01-18 16:28 +0000
      Re: When is an int not an int? Who can explain this? Chris Angelico <rosuav@gmail.com> - 2016-01-19 03:51 +1100
      Re: When is an int not an int? Who can explain this? Ian Kelly <ian.g.kelly@gmail.com> - 2016-01-18 10:00 -0700
      Re: When is an int not an int? Who can explain this? Random832 <random832@fastmail.com> - 2016-01-18 12:02 -0500
      Re: When is an int not an int? Who can explain this? Chris Angelico <rosuav@gmail.com> - 2016-01-19 04:35 +1100

csiph-web