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


Groups > comp.lang.python > #16505

platform issues?

Path csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!news-out2.kabelfoon.nl!newsfeed.kabelfoon.nl!xindi.nntp.kabelfoon.nl!feed.xsnews.nl!border-2.ams.xsnews.nl!xlned.com!feeder7.xlned.com!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <adrianp@bringtechnology.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.048
X-Spam-Evidence '*H*': 0.90; '*S*': 0.00; 'urllib2': 0.07; 'python': 0.08; 'dev': 0.09; '_call_chain': 0.16; 'func(*args)': 0.16; 'subject:issues': 0.16; 'url_data': 0.16; '>>>': 0.18; 'trying': 0.21; '(most': 0.21; '(but': 0.21; 'wrote': 0.22; 'fine,': 0.23; 'cc:2**0': 0.24; 'traceback': 0.24; "i'm": 0.26; 'import': 0.27; 'raise': 0.28; 'urls': 0.28; 'skip:" 30': 0.28; 'problem': 0.29; 'keeps': 0.30; 'subject:?': 0.31; 'thanks': 0.31; 'anyone': 0.31; 'version': 0.32; 'to:addr:python-list': 0.34; 'causing': 0.34; "we're": 0.34; 'last):': 0.34; 'issue': 0.35; 'running': 0.35; 'test': 0.35; 'response': 0.35; 'file': 0.36; 'but': 0.37; 'run': 0.37; 'machine': 0.37; 'think': 0.37; 'open': 0.38; 'skip:o 20': 0.38; 'client': 0.39; 'why': 0.39; "it's": 0.40; 'to:addr:python.org': 0.40; 'might': 0.40; 'received:208': 0.60; 'our': 0.64; 'opener': 0.84; 'received:10.200': 0.84; 'received:bluetie.com': 0.84; 'data)': 0.91; 'received:208.89': 0.91
X-CMAE-OUT-Analysis v=2.0 cv=Gq/ACzJC c=1 sm=1 a=7hyHpxntrC0A:10 a=IkcTkHD0fZMA:10 a=1XWaLZrsAAAA:8 a=54UC-1H9L6WOhPQ57rMA:9 a=DJjKZK_dTlJhtccBqLEA:7 a=QEXdDO2ut3YA:10 a=jldDdGg9RpdlhCWv9Upb1Q==:117
X-CMAE-OUT-Score 0.00
X-HTTP-Received from adrianp.rcomykccru4303 [173.212.138.1] by web003.roc2.bluetie.com (BlueTie WebMail ); Thu, 01 Dec 2011 12:41:22 -0500
X-Mailer BlueTie MTA
Date Thu, 01 Dec 2011 12:41:22 -0500
Cc
To Python-list@python.org
From "Adrian Powell" <adrianp@bringtechnology.com>
Importance normal
Subject platform issues?
Content-transfer-encoding quoted-printable
Content-Type text/plain; charset=UTF-8
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://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 <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.3204.1322761291.27778.python-list@python.org> (permalink)
Lines 38
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1322761291 news.xs4all.nl 6989 [2001:888:2000:d::a6]:55916
X-Complaints-To abuse@xs4all.nl
Xref x330-a1.tempe.blueboxinc.net comp.lang.python:16505

Show key headers only | View raw


I'm new to python and I'm trying to get a twitter client running on a new machine but it keeps on failing. I tracked the problem down to an issue opening URLs and wrote this little test case:

import urllib2
url = 'http://www.google.com/'
opener = urllib2.build_opener()
url_data = opener.open(url).read
url_data


When I run that on a dev machine it works fine, but when it's on one of our servers it crashes:

>>> import urllib2
>>> url = 'http://www.google.com/'
>>> opener = urllib2.build_opener()
>>> url_data = opener.open(url).read
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.7/urllib2.py", line 391, in open
    response = self._open(req, data)
  File "/usr/lib/python2.7/urllib2.py", line 409, in _open
    '_open', req)
  File "/usr/lib/python2.7/urllib2.py", line 369, in _call_chain
    result = func(*args)
  File "/usr/lib/python2.7/urllib2.py", line 1173, in http_open
    return self.do_open(httplib.HTTPConnection, req)
  File "/usr/lib/python2.7/urllib2.py", line 1148, in do_open
    raise URLError(err)
urllib2.URLError: <urlopen error [Errno -2] Name or service not known>


Our servers have the same version of python and we're running the same OS (Fedora 14). Can anyone think of what might be causing this problem, or why it works on most (but not all) machines?

Thanks

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


Thread

platform issues? "Adrian Powell" <adrianp@bringtechnology.com> - 2011-12-01 12:41 -0500
  Re: platform issues? Redcat <redcat@catfolks.net> - 2011-12-01 18:00 +0000

csiph-web