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


Groups > comp.lang.python > #74088

Re: Module name does not match file name

Path csiph.com!usenet.pasdenom.info!weretis.net!feeder1.news.weretis.net!feeder4.news.weretis.net!rt.uk.eu.org!newsfeed.xs4all.nl!newsfeed4.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <rosuav@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.015
X-Spam-Evidence '*H*': 0.97; '*S*': 0.00; 'subject:not': 0.03; 'subject:file': 0.07; "'python": 0.09; 'oh,': 0.09; 'cc:addr :python-list': 0.11; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'imports': 0.16; 'wrote:': 0.18; 'module': 0.19; '>>>': 0.22; 'cc:addr:python.org': 0.22; 'mon,': 0.24; 'cc:2**0': 0.24; 'mention': 0.26; 'somewhere': 0.26; 'header:In-Reply-To:1': 0.27; 'chris': 0.29; 'then.': 0.30; 'message-id:@mail.gmail.com': 0.30; "d'aprano": 0.31; 'steven': 0.31; 'anyone': 0.31; 'file': 0.32; 'used,': 0.33; 'anywhere': 0.35; 'but': 0.35; 'received:google.com': 0.35; 'there': 0.35; 'curious': 0.36; 'next': 0.36; "didn't": 0.36; 'so,': 0.37; 'pm,': 0.38; 'explain': 0.39; 'itself': 0.39; 'system.': 0.39; 'how': 0.40; 'even': 0.60; 'first': 0.61; 'believe': 0.68; 'jul': 0.74; 'to:none': 0.92
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=X38pF6KE82bI/4TMREF3Fx8rH2Ru6qg0ed/lZ/1fn/I=; b=pg8YaUaNd31hRjX3D+uptd+y0LzbdSHlKJYPRjkEvlxUZCXFj4xbfwshw6MeiuBS+G u5v3yJM54U8mphS5mPs5E5NmeIgWKLUbjOuTdI428Mfw6Ixzj26n2YSiKNvP/dUeyr/Z Mg+4GiNvKUekFo8tbkPhtUkC+SkoaSGU86BEQGPMlGY0nAtTyWqIWXjgGHITL0apLDjw LMsGeyL1j9vVas+S1AoJ9m7k9UuRqOVnakQOEesjz5FnpfltCgk5tJIgCS+A+UUhsXH2 QMLCfCTIEiA+2rWBkbm3z4yARKBHvLzcQ8cN3+EgdfUAYkEP2fsagAL4pgRva58tuK0Y ROMQ==
MIME-Version 1.0
X-Received by 10.58.243.170 with SMTP id wz10mr55812vec.55.1404724312221; Mon, 07 Jul 2014 02:11:52 -0700 (PDT)
In-Reply-To <53ba6254$0$2926$c3e8da3$76491128@news.astraweb.com>
References <53ba52e1$0$2926$c3e8da3$76491128@news.astraweb.com> <mailman.11577.1404720285.18130.python-list@python.org> <53ba6254$0$2926$c3e8da3$76491128@news.astraweb.com>
Date Mon, 7 Jul 2014 19:11:52 +1000
Subject Re: Module name does not match file name
From Chris Angelico <rosuav@gmail.com>
Cc "python-list@python.org" <python-list@python.org>
Content-Type text/plain; charset=UTF-8
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
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.11581.1404724315.18130.python-list@python.org> (permalink)
Lines 22
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1404724315 news.xs4all.nl 2872 [2001:888:2000:d::a6]:34672
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:74088

Show key headers only | View raw


On Mon, Jul 7, 2014 at 7:03 PM, Steven D'Aprano <steve@pearwood.info> wrote:
> On Mon, 07 Jul 2014 18:04:36 +1000, Chris Angelico wrote:
>
>> On Mon, Jul 7, 2014 at 5:57 PM, Steven D'Aprano <steve@pearwood.info>
>> wrote:
>>> Can anyone explain how "import pg" can end up coming from pgmodule.so?
>>
>> First guess: There's a "pg.py" somewhere that imports the so, then
>> replaces itself in sys.modules.
>
>
> Oh, there's a pg.py somewhere alright, but it imports _py and there is no
> _py module anywhere on the system. I don't believe that the pg.py file is
> actually used, even though it is in the site-packages next to pgmodule.py.

Huh. Definitely curious as to what 'python -v' says, then.

> I did mention the maze of twisty dependencies, didn't I?

And I winced at your opening paragraph.

ChrisA

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


Thread

Module name does not match file name Steven D'Aprano <steve@pearwood.info> - 2014-07-07 07:57 +0000
  Re: Module name does not match file name Chris Angelico <rosuav@gmail.com> - 2014-07-07 18:04 +1000
    Re: Module name does not match file name Steven D'Aprano <steve@pearwood.info> - 2014-07-07 09:03 +0000
      Re: Module name does not match file name Chris Angelico <rosuav@gmail.com> - 2014-07-07 19:11 +1000
  Re: Module name does not match file name Steven D'Aprano <steve@pearwood.info> - 2014-07-07 08:57 +0000
    Re: Module name does not match file name Chris Angelico <rosuav@gmail.com> - 2014-07-07 19:03 +1000
      Re: Module name does not match file name Steven D'Aprano <steve@pearwood.info> - 2014-07-07 09:28 +0000
    Re: Module name does not match file name Peter Otten <__peter__@web.de> - 2014-07-07 12:41 +0200
    Re: Module name does not match file name Robert Kern <robert.kern@gmail.com> - 2014-07-07 12:15 +0100
      Re: Module name does not match file name Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-07-07 11:56 +0000
        Re: Module name does not match file name Chris Angelico <rosuav@gmail.com> - 2014-07-07 22:04 +1000
        Re: Module name does not match file name Robert Kern <robert.kern@gmail.com> - 2014-07-07 15:25 +0100

csiph-web