Re: [ANN] PyLint 0.27 / logilab-astng 0.24.2

2013-03-04 Thread Sylvain Thénault
On 01 mars 07:41, Melton Low (devl) wrote: Hi Sylvain, Hi, Clicking on the download linked from [1] below gives me an error. Same with logilab-astng link [2]. Not Found The requested URL /pub/pylint/pylint-0.27.0.tar.gz was not found on this server. Apache/2.2.16 (Debian)

Encoding problem in python

2013-03-04 Thread yomnasalah91
I have a problem with encoding in python 27 shell. when i write this in the python shell: w=u'العربى' It gives me the following error: Unsupported characters in input any help? -- http://mail.python.org/mailman/listinfo/python-list

Re: Encoding problem in python

2013-03-04 Thread Laszlo Nagy
On 2013-03-04 10:37, yomnasala...@gmail.com wrote: I have a problem with encoding in python 27 shell. when i write this in the python shell: w=u'العربى' It gives me the following error: Unsupported characters in input any help? Maybe it is not Python related. Did you get an exception? Can

Re: Encoding problem in python

2013-03-04 Thread Steven D'Aprano
On Mon, 04 Mar 2013 01:37:42 -0800, yomnasalah91 wrote: I have a problem with encoding in python 27 shell. when i write this in the python shell: w=u'العربى' It gives me the following error: Unsupported characters in input any help? Firstly, please show the COMPLETE error,

Re: Triple nested loop python (While loop insde of for loop inside of while loop)

2013-03-04 Thread Ulrich Eckhardt
Am 01.03.2013 17:28, schrieb Isaac Won: What I really want to get from this code is m1 as I told. For this purpose, for instance, values of fpsd upto second loop and that from third loop should be same, but they are not. Actually it is my main question. You are not helping yourself... In

Python SUDS issue

2013-03-04 Thread VGNU Linux
Hi Guys, I am pretty new to web services. After some googling found that python suds is a suitable module to create web service client. I am trying to create a client but its giving me an error which is quite confusing for me. Here is my code: from suds.client import Client wsdlurl =

Question on for loop

2013-03-04 Thread newtopython
Hi all, I'm super new to python, just fyi. In the piece of code below, secretWord is a string and lettersGuessed is a list. I'm trying to find out if ALL the characters of secretWord are included in lettersGuessed, even if there are additional values in the lettersGuessed list that aren't in

Re: Question on for loop

2013-03-04 Thread leo kirotawa
In fact this code is already doing what you want, but if the second character, by example, is not in secrectWord it'll jump out of the for and return. If you want that interact through the all characters and maybe count how many them are in the secrectWord, just take of the return there or do

Re: Question on for loop

2013-03-04 Thread Joel Goldstick
On Mon, Mar 4, 2013 at 7:18 AM, newtopython roshen.set...@gmail.com wrote: Hi all, I'm super new to python, just fyi. Welcome. Next time write a better subject line, and be sure the code you post is actually the code you are running. Provide the results you want and what you get. Provide

Re: Python SUDS issue

2013-03-04 Thread Joel Goldstick
On Mon, Mar 4, 2013 at 5:37 AM, VGNU Linux vgnuli...@gmail.com wrote: Hi Guys, I am pretty new to web services. After some googling found that python suds is a suitable module to create web service client. I am trying to create a client but its giving me an error which is quite confusing for

Re: Question on for loop

2013-03-04 Thread Dave Angel
On 03/04/2013 07:18 AM, newtopython wrote: Hi all, I'm super new to python, just fyi. Welcome to the Python list. In the piece of code below, secretWord is a string and lettersGuessed is a list. I'm trying to find out if ALL the characters of secretWord are included in lettersGuessed,

Re: Encoding problem in python

2013-03-04 Thread Vlastimil Brom
2013/3/4 yomnasala...@gmail.com: I have a problem with encoding in python 27 shell. when i write this in the python shell: w=u'العربى' It gives me the following error: Unsupported characters in input any help? -- http://mail.python.org/mailman/listinfo/python-list Hi, I guess, you

Different behavior with multiprocessing

2013-03-04 Thread Tomas Kotal
Hi all. Recently I discovered a strange behavior with multiprocessing library and call to function os.system (a different behavior under Linux and Windows to be more specific). I have this simple testing script: import sys import os from

Re: Question on for loop

2013-03-04 Thread Bryan Devaney
if character not in lettersGuessed: return True return False assuming a function is being used to pass each letter of the letters guessed inside a loop itself that only continues checking if true is returned, then that could work. It is however more work than is needed.

Re: Different behavior with multiprocessing

2013-03-04 Thread Chris Angelico
On Tue, Mar 5, 2013 at 1:31 AM, Tomas Kotal tomas.ko...@gmail.com wrote: But when I run same script on Linux, what I get is this: 0 32512 Under Unix, the return value from os.system() encodes more than one piece of information: http://docs.python.org/2/library/os.html#os.system

Re: i need help

2013-03-04 Thread Bryan Devaney
On Sunday, March 3, 2013 6:45:26 PM UTC, Kwpolska wrote: On Sun, Mar 3, 2013 at 7:46 AM, Michael Torrie torr...@gmail.com wrote: On 02/21/2013 03:18 AM, leonardo wrote: thanks, problem solved Apparently not. The shift key on your keyboard still seems to be non-functional. ;)

Embedding a for inside an html template for substitution

2013-03-04 Thread Ferrous Cranus
Hello pythonistas! I'am tryign to populate a table with dictionary keys and values: Foe that iam using an html template and the questions is what i should write inside 'files.html' so then then the python script populate the table. table trthSuperHost - Economy/th/tr trtdΧώρος

fixed broken links for the latest pylint/astng release

2013-03-04 Thread Sylvain Thénault
Hi there, last week I announced the latest and greatest pylint/astng release but didn't noticed at that time that the download links on our web site were broken, and that the upload to pypi failed. This is now fixed, for those who tried during the mean time. Sorry for the convenience, --

Re: Different behavior with multiprocessing

2013-03-04 Thread Tomas Kotal
Under Unix, the return value from os.system() encodes more than one piece of information: http://docs.python.org/2/library/os.html#os.system http://docs.python.org/2/library/os.html#os.wait 32512 is 127*256, meaning that the shell exited with return code 127 when given an

Re: Different behavior with multiprocessing

2013-03-04 Thread Tomas Kotal
Dne pondělí, 4. března 2013 15:31:41 UTC+1 Tomas Kotal napsal(a): Hi all. Recently I discovered a strange behavior with multiprocessing library and call to function os.system (a different behavior under Linux and Windows to be more specific). I have this simple testing script:

Re: Different behavior with multiprocessing

2013-03-04 Thread Chris Angelico
On Tue, Mar 5, 2013 at 2:35 AM, Tomas Kotal tomas.ko...@gmail.com wrote: Seems like I found the problem: os._exit probably takes as parametr unsigned char, so it uses as error code whatever value it gets modulo 256: os._exit(1) # process.exitcode == 1 os._exit(255) # process.exitcode ==

Re: Question on for loop

2013-03-04 Thread Rick Johnson
On Monday, March 4, 2013 6:18:20 AM UTC-6, newtopython wrote: [Note: Post has be logically re-arranged for your comprehensive pleasures] for character in secretWord: if character not in lettersGuessed: return True return False What this code is doing is only checking the

Re: Embedding a for inside an html template for substitution

2013-03-04 Thread Michael Torrie
On 03/04/2013 08:14 AM, Ferrous Cranus wrote: Instead of writing the above html data inside my html template how would i write it with a for that then will be substituted by the python script? What templating system are you using? Django's? can you please write an example for me that user

Re: [Python-ideas] string.format() default variable assignment

2013-03-04 Thread David Robinow
Ignoring my own posting ban, since I've clearly been misunderstood .. On Sat, Mar 2, 2013 at 10:21 PM, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: On Sat, 02 Mar 2013 21:11:04 -0500, David Robinow wrote: Do you consider it rude that you choose to use a newsreader, thus

Re: [Python-ideas] string.format() default variable assignment

2013-03-04 Thread David Robinow
Crap. I just forgot to do what I just said I would do and didn't go through my inconvenient sequence. Sorry, Steven. It was unintentional. -- http://mail.python.org/mailman/listinfo/python-list

Re: Why is it impossible to create a compiler than can compile Python to machinecode like C?

2013-03-04 Thread Grant Edwards
On 2013-02-28, kramer65 kram...@gmail.com wrote: I'm using Python for a while now and I love it. There is just one thing I cannot understand. There are compilers for languages like C and C++. why is it impossible to create a compiler that can compile Python code to machinecode? The main

Re: Question on for loop

2013-03-04 Thread Ian Kelly
On Mon, Mar 4, 2013 at 7:34 AM, Bryan Devaney bryan.deva...@gmail.com wrote: if character not in lettersGuessed: return True return False assuming a function is being used to pass each letter of the letters guessed inside a loop itself that only continues checking if true

Re: i need help

2013-03-04 Thread Ian Kelly
On Mon, Mar 4, 2013 at 8:07 AM, Bryan Devaney bryan.deva...@gmail.com wrote: On Sunday, March 3, 2013 6:45:26 PM UTC, Kwpolska wrote: It is! How else could he type those two question marks and 10 double-quotes? Onscreen Keyboard? Or voice recognition, perhaps. We have no idea what the

Re: i need help

2013-03-04 Thread Alister
On Mon, 04 Mar 2013 07:07:53 -0800, Bryan Devaney wrote: On Sunday, March 3, 2013 6:45:26 PM UTC, Kwpolska wrote: On Sun, Mar 3, 2013 at 7:46 AM, Michael Torrie torr...@gmail.com wrote: On 02/21/2013 03:18 AM, leonardo wrote: thanks, problem solved Apparently not. The shift

Re: Question on for loop

2013-03-04 Thread Ricardo Aráoz
El 04/03/13 09:18, newtopython escribió: Hi all, I'm super new to python, just fyi. In the piece of code below, secretWord is a string and lettersGuessed is a list. I'm trying to find out if ALL the characters of secretWord are included in lettersGuessed, even if there are additional values

Re: Embedding a for inside an html template for substitution

2013-03-04 Thread Ferrous Cranus
Τη Δευτέρα, 4 Μαρτίου 2013 5:59:34 μ.μ. UTC+2, ο χρήστης Michael Torrie έγραψε: On 03/04/2013 08:14 AM, Ferrous Cranus wrote: Instead of writing the above html data inside my html template how would i write it with a for that then will be substituted by the python script? What

How to Nest Structs?

2013-03-04 Thread Ari King
Hi, I'm trying to nest the info_header, info_body, and info_trailer structs (see below) into a data_packet struct. Does anyone know how I can/should accomplish this? Thanks. batch_header_format = struct.Struct('!c2h') info_header_format = struct.Struct('!2hl') mkt_status_format =

Re: [Python-ideas] string.format() default variable assignment

2013-03-04 Thread Dave Angel
On 03/04/2013 11:15 AM, David Robinow wrote: Crap. I just forgot to do what I just said I would do and didn't go through my inconvenient sequence. Sorry, Steven. It was unintentional. FWIW, you don't have to bother moving the python-list address to a To: field. Just remove the personal

Re: Read csv file and create a new file

2013-03-04 Thread io
What you wrote seems interesting but i haven't understood. Can you explain in simple words considering i'm italian and i'm not understanding so well some terms you use. Sorry, i'm sure you are suggesting something really valid but can't understand it. Marco. --

Python script not working on windows 7 but works fine on linux

2013-03-04 Thread io
The following scripts are working fine on linux but, using the same version, can't work on windows because i receive the following message: Script: import json import urllib import csv url = http://bitcoincharts.com/t/markets.json; response = urllib.urlopen(url); data =

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread ian douglas
On 03/04/2013 11:06 AM, io wrote: esclusioni_file = open('/home/io/btc_trading/exclusions.txt','r') Windows error : Traceback (most recent call last): File C:\btc_trading\scripts \import_json_2_csv_from_web_and_exclusions.py, line 10, in module f =

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread Christian Gollwitzer
Am 04.03.13 20:06, schrieb io: The following scripts are working fine on linux but, using the same version, can't work on windows because i receive the following message: snip f = open(/home/io/btc_trading/markets.csv,wb) Windows error : Traceback (most recent call last): File

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread Wolfgang Strobl
io mar...@libero.it: The following scripts are working fine on linux but, using the same version, can't work on windows because i receive the following message: Thats because there is No such file or directory: '/home/io/btc_trading/ on that Windows PC. -- Wir danken für die Beachtung aller

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread io
Genius! The code i posted was an example. My real code was c:\btc_trading i was just missing the double slashes! Thanks , thankyou very much. :-) -- http://mail.python.org/mailman/listinfo/python-list

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread io
Thanks, btw ...i'm the IT guy! I was missing the double slash as dougas suggested!++Thanks anyway. -- http://mail.python.org/mailman/listinfo/python-list

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread Chris Angelico
On Tue, Mar 5, 2013 at 6:59 AM, io mar...@libero.it wrote: Genius! The code i posted was an example. My real code was c:\btc_trading i was just missing the double slashes! Thanks , thankyou very much. :-) Even on Windows, you can use / as a directory separator. This generally saves

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread Terry Reedy
On 3/4/2013 2:20 PM, ian douglas wrote: I imagine your CSV file lives in a different location on your Windows 7 system (which also uses back-slashes '\' instead of forward-slashes '/', Forward slashes work fine on Windows except for invoking the executable at a Command Prompt command line,

Re: How to Nest Structs?

2013-03-04 Thread web
Try unpacking the nested struct as a fixed width string and then unpacking the string. Then unpack the string On Monday, March 4, 2013 10:22:07 AM UTC-8, Ari King wrote: Hi, I'm trying to nest the info_header, info_body, and info_trailer structs (see below) into a data_packet

فيس بوك facebook

2013-03-04 Thread 23alagmy
فيس بوك facebook https://www.facebook.com/pages/%D9%86%D8%AA%D8%A7%D8%A6%D8%AC-%D8%A7%D9%84%D8%A7%D9%85%D8%AA%D8%AD%D8%A7%D9%86%D8%A7%D8%AA-%D9%88%D8%A7%D9%84%D8%AC%D8%A7%D9%85%D8%B9%D8%A7%D8%AA-%D9%88%D8%A7%D8%AC%D8%AA%D9%85%D8%A7%D8%B9%D9%8A%D8%A7%D8%AA/299719160065550?ref=hl --

Re: Why is it impossible to create a compiler than can compile Python to machinecode like C?

2013-03-04 Thread CM
The main issue is that python has dynamic typing.  The type of object that is referenced by a particular name can vary, and there's no way (in general) to know at compile time what the type of object foo is. That makes generating object code to manipulate foo very difficult. Could you help

Re: Why is it impossible to create a compiler than can compile Python to machinecode like C?

2013-03-04 Thread 88888 Dihedral
On Tuesday, March 5, 2013 6:55:06 AM UTC+8, CM wrote: The main issue is that python has dynamic typing.  The type of object that is referenced by a particular name can vary, and there's no way (in general) to know at compile time what the type of object foo is. That makes

Re: Why is it impossible to create a compiler than can compile Python to machinecode like C?

2013-03-04 Thread Terry Reedy
On 3/4/2013 5:55 PM, CM wrote: Could you help me understand this better? For example, if you have this line in the Python program: foo = 'some text' bar = {'apple':'fruit'} If the interpreter can determine at runtime that foo is a string and bar is a dict, why can't the compiler figure that

Re: Why is it impossible to create a compiler than can compile Python to machinecode like C?

2013-03-04 Thread Chris Angelico
On Tue, Mar 5, 2013 at 9:55 AM, CM cmpyt...@gmail.com wrote: The main issue is that python has dynamic typing. The type of object that is referenced by a particular name can vary, and there's no way (in general) to know at compile time what the type of object foo is. That makes generating

Re: Why is it impossible to create a compiler than can compile Python to machinecode like C?

2013-03-04 Thread Benjamin Kaplan
On Mar 4, 2013 3:02 PM, CM cmpyt...@gmail.com wrote: The main issue is that python has dynamic typing. The type of object that is referenced by a particular name can vary, and there's no way (in general) to know at compile time what the type of object foo is. That makes generating

Re: Why is it impossible to create a compiler than can compile Python to machinecode like C?

2013-03-04 Thread Steven D'Aprano
On Mon, 04 Mar 2013 16:36:36 +, Grant Edwards wrote: On 2013-02-28, kramer65 kram...@gmail.com wrote: I'm using Python for a while now and I love it. There is just one thing I cannot understand. There are compilers for languages like C and C++. why is it impossible to create a compiler

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread Steven D'Aprano
On Mon, 04 Mar 2013 11:20:28 -0800, ian douglas wrote: The error tells you everything you need to know: the file system has no path/file called /home/io/btc_trading/markets.csv I imagine your CSV file lives in a different location on your Windows 7 system (which also uses back-slashes '\'

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread Andrew Berg
On 2013.03.04 19:58, Steven D'Aprano wrote: Windows understands forward slashes in paths too. You can make your code (almost) platform-independent, and avoid a lot of problems with unescaped backslashes, by always using forward slashes in paths. Or use os.path.join, the entire purpose of

Re: [Python-ideas] string.format() default variable assignment

2013-03-04 Thread Steven D'Aprano
On Mon, 04 Mar 2013 11:09:10 -0500, David Robinow wrote: But here's what I don't understand. Why does somebody who posts as much as Steven (and thanks for that. Getting cussed at occasionally is a cheap price for all the free advice) not set up a simple mail filter which trashes all mail

Re: [Python-ideas] string.format() default variable assignment

2013-03-04 Thread Chris Angelico
On Tue, Mar 5, 2013 at 1:42 PM, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: It's easy for him to deal with it, all he has to do is get a goat to eat the garden waste I toss over the fence, and his problem is solved. Sounds like someone got Steven's goat. *dives for cover*

Re: Python script not working on windows 7 but works fine on linux

2013-03-04 Thread 88888 Dihedral
On Tuesday, March 5, 2013 3:20:28 AM UTC+8, ian douglas wrote: On 03/04/2013 11:06 AM, io wrote: esclusioni_file = open('/home/io/btc_trading/exclusions.txt','r') Windows error : Traceback (most recent call last): File C:\btc_trading\scripts

** UPDATE ** ~ The Perfect Guide To Actionable Programming Thank You ~

2013-03-04 Thread Claira
Thanks for the few answers, though those few were very Helpful. The problem was that some people (even after 4 or more years of university), especially including almost all beginners, do not know how to start building something that does something helpful for soceity and everyone around them --

Re: Embedding a for inside an html template for substitution

2013-03-04 Thread Michael Torrie
On 03/04/2013 01:06 PM, Ferrous Cranus wrote: What do you advise me to do? Generate html via python code like print '''stuf..''' or use an html templating system? Up until now i was using the first method and i though it would be a nice idea to seperate design from code. But please

Re: [Python-ideas] string.format() default variable assignment

2013-03-04 Thread Gene Heskett
On Monday 04 March 2013 23:00:31 Chris Angelico did opine: On Tue, Mar 5, 2013 at 1:42 PM, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: It's easy for him to deal with it, all he has to do is get a goat to eat the garden waste I toss over the fence, and his problem is

Re: Python SUDS issue

2013-03-04 Thread VGNU Linux
Hi, Typing URL in the browser displays document tree as a web page. Is it right or there is something wrong with it ? Regards, VGNU On Mon, Mar 4, 2013 at 6:45 PM, Joel Goldstick joel.goldst...@gmail.comwrote: On Mon, Mar 4, 2013 at 5:37 AM, VGNU Linux vgnuli...@gmail.com wrote: Hi Guys,

Pythonic way for retrieving value for a nested dictionary.

2013-03-04 Thread Lowly Minion
For a typical dict: i.e. d = { '1': 'a', '2', 'b' } I might use something like: d.get('1', None) To get the value of 1. What would be the most pythonic way of getting a nested value of a dictionary within a list: some_list = [{ 'item': { 'letter': 'b',

Re: Python SUDS issue

2013-03-04 Thread dieter
VGNU Linux vgnuli...@gmail.com writes: ... Here is my code: from suds.client import Client wsdlurl = 'https://46.51.221.138/PBExternalServices/v1/soap?wsdl' client = Client(wsdlurl) print client And following is the error that occurs on trying to print client. Traceback (most recent call

Re: Pythonic way for retrieving value for a nested dictionary.

2013-03-04 Thread Dave Angel
On 03/05/2013 01:48 AM, Lowly Minion wrote: For a typical dict: i.e. d = { '1': 'a', '2', 'b' } I might use something like: d.get('1', None) To get the value of 1. What would be the most pythonic way of getting a nested value of a dictionary within a list: some_list = [{ 'item': {

Re: Embedding a for inside an html template for substitution

2013-03-04 Thread nagia . retsina
Τη Δευτέρα, 4 Μαρτίου 2013 5:14:00 μ.μ. UTC+2, ο χρήστης Νίκος Γκρ33κ έγραψε: Hello pythonistas! I'am tryign to populate a table with dictionary keys and values: Foe that iam using an html template and the questions is what i should write inside 'files.html' so then then the

[issue17328] Fix reference leak in dict_setdefault() in case of resize failure

2013-03-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: LGTM. This is 3.3+ only issue as far as I understand. -- nosy: +benjamin.peterson versions: -Python 2.6, Python 2.7, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17328

[issue17345] Portable and extended type specifiers for array module

2013-03-04 Thread Nikita Nemkin
New submission from Nikita Nemkin: Currently array module only provides platform-dependent type specifiers. It would be very nice to have platform-independent specifiers in addition to that, matching the struct module. For example array('H') - an array of little-endian 2-byte integers. This

[issue17278] SIGSEGV in _heapqmodule.c

2013-03-04 Thread Raymond Hettinger
Changes by Raymond Hettinger raymond.hettin...@gmail.com: -- Removed message: http://bugs.python.org/msg183401 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17278 ___

[issue17278] SIGSEGV in _heapqmodule.c

2013-03-04 Thread Raymond Hettinger
Raymond Hettinger added the comment: Antoine, thanks for the patch. This looks like a reasonable solution that is fast and prevents segfaults. -- assignee: rhettinger - pitrou ___ Python tracker rep...@bugs.python.org

[issue15216] Support setting the encoding on a text stream after creation

2013-03-04 Thread Nick Coghlan
Nick Coghlan added the comment: That's a fair point - I think it's acceptable to throw an error in the case of *already decoded* characters that haven't been read. There's also a discussion on python-ideas about an explicit API for clearing the internal buffers, and pushing data back into a

[issue15216] Support setting the encoding on a text stream after creation

2013-03-04 Thread Nick Coghlan
Nick Coghlan added the comment: Oops, meant to link to my post in the thread about a buffer manipulation API: http://mail.python.org/pipermail/python-ideas/2013-March/019769.html -- ___ Python tracker rep...@bugs.python.org

[issue17346] Pickle tests do not test protocols 0, 1, and 2 for bytes

2013-03-04 Thread Marius Gedminas
New submission from Marius Gedminas: I was reading Lib/test/pickletester.py when I noticed that test_bytes loops over all the protocols but doesn't actually use the loop variable anywhere. Attached patch should fix this. -- components: Tests files: actually-test-all-protocols.diff

[issue17346] Pickle tests do not test protocols 0, 1, and 2 for bytes

2013-03-04 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +ezio.melotti stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17346 ___

[issue17347] bsddb._openDBEnv() should not touch current directory

2013-03-04 Thread Florian Weimer
New submission from Florian Weimer: This code: def _openDBEnv(cachesize): e = db.DBEnv() if cachesize is not None: if cachesize = 20480: e.set_cachesize(0, cachesize) else: raise error, cachesize must be = 20480

[issue17348] Unicode - encoding seems to be lost for inputs of unicode chars

2013-03-04 Thread Pradyun Gedam
New submission from Pradyun Gedam: In IDLE, I have spotted a peculiar problem. I have attached an .png file which is a screen capture of 'session' on IDLE. It seems that the Unicode character that has been input, loses its encoding. My 'session' Python 2.7.2 (default, Jun 12 2011, 15:08:59)

[issue17347] bsddb._openDBEnv() should not touch current directory

2013-03-04 Thread Jesús Cea Avión
Jesús Cea Avión added the comment: This is a standard Berkeley DB behavior. Can I suggest you to report this issue to Oracle forums? http://docs.oracle.com/cd/E17276_01/html/programmer_reference/env_db_config.html https://forums.oracle.com/forums/forum.jspa?forumID=271 Closing as invalid. if

[issue16620] Avoid using private function glob.glob1() in msi module and tools

2013-03-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I have added some comments on Rietveld. Note that glob.glob() and glob.glob1() returns different filenames. The first returns full paths and the second returns bare filenames without a directory path. Workarounding this may require more in-depth changes to

[issue13598] string.Formatter doesn't support empty curly braces {}

2013-03-04 Thread Phil Elson
Phil Elson added the comment: I didn't see a test case relating to the example in his comment, namely f.format({0:{}}, 'foo', 5) Did I miss it? The example should fail, which it wouldn't have done with the patch previously proposed. I believe the case is covered by the block: with

[issue17299] Test cPickle with real files

2013-03-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I have added comments on Rietveld. Perhaps it will be worth to create mixings for cStringIO.StringIO, BytesIO and file object and then mix them to other tests. Note that there is no sense to change pure Python pickle tests. Python implementation uses the

[issue17299] Test cPickle with real files

2013-03-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: David, yes, this is 2.7 only issue. The code was broken recently (see msg182979 in issue13555) due to insufficient testing. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17299

[issue17349] wsgiref.simple_server.demo_app is not PEP-3333 compatible

2013-03-04 Thread Andrey Lebedev
New submission from Andrey Lebedev: Under certain circumstances, wsgiref.simple_server.demo_app may return unicode data, but that is prohibited by PEP-. This happens if environ with unicode key is passed to demo_app. Unicode keys are then written to StringIO instance, automatically making

[issue17346] Pickle tests do not test protocols 0, 1, and 2 for bytes

2013-03-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: LGTM. -- nosy: +serhiy.storchaka versions: +Python 3.2, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17346 ___

[issue16851] Hint about correct ismethod and isfunction usage

2013-03-04 Thread Thomas Kluyver
Thomas Kluyver added the comment: I agree that the docs for inspect.ismethod() for Python 2 are wrong. The docs say: Return true if the object is a bound method written in Python. However, it also returns True for an unbound method: class A: ... def meth(self): ... pass ...

[issue17094] sys._current_frames() reports too many/wrong stack frames

2013-03-04 Thread Stefan Ring
Stefan Ring added the comment: When I originally worked on this, I noticed that _PyThread_CurrentFrames also iterates over all interpreters. Because I have no experience with or use for multiple interpreters, I intentionally left it out of my patch, but shouldn't it be taken into account for

[issue1124861] subprocess fails on GetStdHandle in interactive GUI

2013-03-04 Thread Tomgu
Tomgu added the comment: Here I get one problem need help. In python 2.7.5 version I write a script test.py as below ### import subprocess fileID=file('test1.log','w') process_response = subprocess.call('netsh wlan show\ interface',stdout=fileID,shell=True) fileID.flush() fileID.close() ### It

[issue1124861] subprocess fails on GetStdHandle in interactive GUI

2013-03-04 Thread Tomgu
Tomgu added the comment: Update, the python version is '2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)]' -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1124861 ___

[issue16382] Better warnings exception for bad category

2013-03-04 Thread Phil Elson
Phil Elson added the comment: Ok. I think I've done all of the actions from the reviews. I'm not sure if I should remove the old patches or not? Thanks, -- Added file: http://bugs.python.org/file29304/pelson_warnings_fix_4.diff ___ Python tracker

[issue17350] Use STAF call python script will case 1124861 issue in 2.7.2 version

2013-03-04 Thread Tomgu
New submission from Tomgu: Here I get one problem use STAF call python and need help. In python 2.7.2 version I write a script test.py as below ### import subprocess fileID=file('test1.log','w') process_response = subprocess.call('netsh wlan show\ interface',stdout=fileID,shell=True)

[issue17094] sys._current_frames() reports too many/wrong stack frames

2013-03-04 Thread Stefan Ring
Stefan Ring added the comment: (Regarding your test) I have also noticed in the past that joining threads after a fork has caused hangs occasionally, although that might have resulted from the messed up _current_frames. -- ___ Python tracker

[issue15866] encode(..., 'xmlcharrefreplace') produces entities for surrogate pairs

2013-03-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I prefer a little different (simpler for me) form: for (p = collstart; p collend;) { Py_UCS4 ch = *p++; if ((0xD800 = ch ch = 0xDBFF) (p collend)

[issue11787] File handle leak in TarFile lib

2013-03-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Actually it was fixed in issue16477. ;) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11787 ___ ___

[issue17346] Pickle tests do not test protocols 0, 1, and 2 for bytes

2013-03-04 Thread Roundup Robot
Roundup Robot added the comment: New changeset a982feb29584 by Ezio Melotti in branch '3.2': #17346: make sure pickle tests are run against all protocols. Initial patch by Marius Gedminas. http://hg.python.org/cpython/rev/a982feb29584 New changeset 796de4f7df07 by Ezio Melotti in branch

[issue17346] Pickle tests do not test protocols 0, 1, and 2 for bytes

2013-03-04 Thread Ezio Melotti
Ezio Melotti added the comment: Fixed, thanks for the report and the patch! -- assignee: - ezio.melotti resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org

[issue16997] subtests

2013-03-04 Thread Nick Coghlan
Nick Coghlan added the comment: I think I have figured out what bothers me about the expectedfailure changes, and they actually relate to how expectedfailure was implemented in the first place: I had previously assumed that decorator was an *annotating* decorator - that it set an attribute on

[issue17322] urllib.request add_header() currently allows trailing spaces (and other weird stuff)

2013-03-04 Thread R. David Murray
R. David Murray added the comment: A crazy idea that occurred to me was to create an rfc822-style-header management module, and share it between email, http, and urllib. We'd probably break too many things backward-compatibility wise if we did that, but I still think it is an interesting

[issue16997] subtests

2013-03-04 Thread Michael Foord
Michael Foord added the comment: Getting rid of the thread local would be an improvement, and the change to how expected failures is done sounds good too. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16997

[issue13598] string.Formatter doesn't support empty curly braces {}

2013-03-04 Thread Vinay Sajip
Vinay Sajip added the comment: I believe the case is covered by the block: [snip] Ah, right. I wasn't sure that was the exact same code path that was being exercised. But I didn't look very closely. If you think it is worthwhile? Only if it exercises a different code path. --

[issue16997] subtests

2013-03-04 Thread Antoine Pitrou
Antoine Pitrou added the comment: However, I'm wondering if it might still be possible to avoid the need for a thread local context to handle the combination of expected failures and subtests when we have access to the test caseby adding the annotation that I expected to be there in the

[issue10590] Parameter type error for xml.sax.parseString(string, ...)

2013-03-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Low-level part already extracted to issue17089 and committed. Issue16986 has a similar patch for cElementTree. The main part of path was moved to issue2175 which is now pre-requisite for issue16986 and for this issue. It contains additional tests and

[issue10590] Parameter type error for xml.sax.parseString(string, ...)

2013-03-04 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: Removed file: http://bugs.python.org/file28757/sax_parse.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10590 ___

[issue16986] ElementTree incorrectly parses strings with declared encoding not UTF-8

2013-03-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Eli, this issue no longer has open pre-requisites. Issue10590 was replaced by issue17089 which closed now. Issue17089 fixed Python interface to expat parser, but cElementTree uses C interface of expat directly and the proposed pathes fix it. --

[issue10590] Parameter type error for xml.sax.parseString(string, ...)

2013-03-04 Thread Eli Bendersky
Eli Bendersky added the comment: Serhiy, OK - I'll look at #2175 first. But yes, Christian is right, let's wait for the security issues to be resolved first. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10590

  1   2   >