Re: Problem with sqlite3 and Decimal

2015-12-11 Thread Chris Angelico
IOn Sat, Dec 12, 2015 at 6:31 PM, Frank Millman wrote: > I have found a workaround for my problem, but first I needed to understand > what was going on more clearly. This is what I have figured out. > > 1. The solution in the SO article is a bit of sleight of hand, though very > effective. It does

Re: Problem with sqlite3 and Decimal

2015-12-11 Thread Frank Millman
"Frank Millman" wrote in message news:n4ei3l$b98$1...@ger.gmane.org... I need to store Decimal objects in a sqlite3 database, using Python 3.4 on Windows 7. I followed the instructions here - http://stackoverflow.com/questions/6319409/how-to-convert-python-decimal-to-sqlite-numeric It seem

Re: Problem with sqlite3 and Decimal

2015-12-11 Thread Frank Millman
"Chris Angelico" wrote in message news:CAPTjJmoPXFSnXe1QA8MjjncBZBpqNkztha8YHJv=mbm--ze...@mail.gmail.com... On Sat, Dec 12, 2015 at 4:10 PM, Frank Millman wrote: > I can reproduce your example above. However, if I set the initial value > to > 5678.7, then the sequence goes > > 5678.7 > 580

Re: Problem with sqlite3 and Decimal

2015-12-11 Thread Chris Angelico
On Sat, Dec 12, 2015 at 4:10 PM, Frank Millman wrote: > I can reproduce your example above. However, if I set the initial value to > 5678.7, then the sequence goes > > 5678.7 > 5802.15 > 5925.6 > 6049.05 > 6172.5 > > I would have thought that adding 123.45 to 5802.15 would always produce the > sam

Re: Is vars() the most useless Python built-in ever?

2015-12-11 Thread Chris Angelico
On Sat, Dec 12, 2015 at 3:44 PM, Steven D'Aprano wrote: > On Sat, 12 Dec 2015 09:13 am, Rick Johnson wrote: > >> Intuitiveness and productivity have a >> synergy like peas and carrots! One cannot be productive if one is fighting >> an unintuitive interface. Could you drive with your toes? How abou

Re: Problem with sqlite3 and Decimal (fwd)

2015-12-11 Thread Frank Millman
"Igor Korot" wrote in message news:CA+FnnTyZY_1=62rbk_kkz39tkeoa6jvmfn9qs17as-2yd4d...@mail.gmail.com... Yes, I saw your post to sqlite3 ML. And I do know that by default sqlite3 does not have many types supported. However, all you need to do is save it as DECIMAL(10,2). It is supported is sql

Re: Problem with sqlite3 and Decimal

2015-12-11 Thread Frank Millman
"Chris Angelico" wrote in message news:captjjmor6newucco7xtsswyyfbgwcwz8jt-mjjkysjocfu7...@mail.gmail.com... On Fri, Dec 11, 2015 at 8:21 PM, Frank Millman wrote: > I noticed one oddity - I am asking sqlite3 to store the value as a > string, > but then I am asking it to perform arithmetic on

Re: Is vars() the most useless Python built-in ever?

2015-12-11 Thread Steven D'Aprano
On Sat, 12 Dec 2015 09:13 am, Rick Johnson wrote: > Intuitiveness and productivity have a > synergy like peas and carrots! One cannot be productive if one is fighting > an unintuitive interface. Could you drive with your toes? How about your > tongue? Drive a car with my tongue? Perhaps not, but

Re: Can anyone help me modify the code so the ball starts in random directions

2015-12-11 Thread Erik
Hi, On 11/12/15 23:19, phamton...@gmail.com wrote: Can anyone direct me in the direction where to start the code for the randomized of the ball to start. Your questions over the last week or so appear to be homework assignments. However, I'll give you a hint: in the interactive interprete

Re: Can anyone help me modify the code so the ball starts in random directions

2015-12-11 Thread Erik
Hi, On 11/12/15 23:19, phamton...@gmail.com wrote: Can anyone direct me in the direction where to start the code for the randomized of the ball to start. Your questions over the last week or so appear to be homework assignments. However, I'll give you a hint: in the interactive interprete

Re: Can anyone help me modify the code so the ball starts in random directions

2015-12-11 Thread phamtony33
On Friday, December 11, 2015 at 7:55:59 PM UTC-5, Steven D'Aprano wrote: > On Sat, 12 Dec 2015 10:19 am, phamton...@gmail.com wrote: > > > Can anyone direct me in the direction where to start the code for the > > randomized of the ball to start. > > [...] > > move_ball(-10, 7, 0) > > > That s

Re: Can anyone help me modify the code so the ball starts in random directions

2015-12-11 Thread Steven D'Aprano
On Sat, 12 Dec 2015 10:19 am, phamton...@gmail.com wrote: > Can anyone direct me in the direction where to start the code for the > randomized of the ball to start. [...] > move_ball(-10, 7, 0) That starts the ball moving, with x-speed of -10 and y-speed of 7. Instead use something similar to

Re: Can anyone help me modify the code so the ball starts in random directions

2015-12-11 Thread phamtony33
from Tkinter import * window = Tk() canvas = Canvas(window, width=500, height=500, background="green") canvas.pack() def mouse_paddle_move(event): mouseY = event.y current_coords = canvas.coords("paddle") x1 = current_coords[0] y1 = current_coords[1] x2 = cu

Re: Can anyone help me modify the code so the ball starts in random directions

2015-12-11 Thread Rick Johnson
On Friday, December 11, 2015 at 5:20:13 PM UTC-6, phamt...@gmail.com wrote: > Can anyone direct me in the direction where to start the code for the > randomized of the ball to start. No, because your problem needs to be simplified first. A good first step would be to create a new script that o

Can anyone help me modify the code so the ball starts in random directions

2015-12-11 Thread phamtony33
Can anyone direct me in the direction where to start the code for the randomized of the ball to start. from Tkinter import * window = Tk() canvas = Canvas(window, width=500, height=500, background="green") canvas.pack() def mouse_paddle_move(event): mouseY = event.y current_coo

Re: Is vars() the most useless Python built-in ever?

2015-12-11 Thread Rick Johnson
On Tuesday, December 1, 2015 at 10:49:19 PM UTC-6, Ian wrote: > > It's a well know fact that GvR was inspired to create > > Python from his experiences working with a language > > called ABC -- and ABC was designed *EXCLUSIVELY* to be a > > beginners language. > Which is exactly what made ABC itsel

Re: Is vars() the most useless Python built-in ever?

2015-12-11 Thread Rick Johnson
On Tuesday, December 1, 2015 at 1:34:54 AM UTC-6, Marko Rauhamaa wrote: > Rick Johnson : > > > python was originally created to be an easy language for noobs to > > learn > > Really? That's would be a silly objective for a programming language. > > > many a noob has been stumped > > So? > > Yo

Re: python 351x64

2015-12-11 Thread Mark Lawrence
On 11/12/2015 17:53, Jay Hamm wrote: It is an issue that borks your install. That seems like your issue which involves notepad++. You might want to talk with them about it or more likely since they've not fixed it in a while - develop a work around or at least a message that pops up and asks i

Re: Hello

2015-12-11 Thread Ian Kelly
On Fri, Dec 11, 2015 at 11:43 AM, Seung Kim wrote: > See message below. > > On Fri, Dec 11, 2015 at 1:13 PM, Seung Kim wrote: > >> I would like to have Python 3.5.1 MSI installer files for both 32-bit and >> 64-bit so that I can deploy the software on managed computers on campus. >> >> When I ran

Re: Hello

2015-12-11 Thread Seung Kim
See message below. On Fri, Dec 11, 2015 at 1:13 PM, Seung Kim wrote: > I would like to have Python 3.5.1 MSI installer files for both 32-bit and > 64-bit so that I can deploy the software on managed computers on campus. > > When I ran the silent install command line on python-3.5.1.exe, the > re

RE: wrappers for C/C++

2015-12-11 Thread Ginga, Dick
Thank you Chris for this answer. These are the _only_ versions the build creates. Are you saying that wrappers for 3.5 "may" continue to support future versions? -Original Message- From: Python-list [mailto:python-list-bounces+dick.ginga=perkinelmer@python.org] On Behalf Of Chris

RE: wrappers for C/C++

2015-12-11 Thread Ginga, Dick
Thanks again for a very informative answer and these are windows wrappers. -Original Message- From: Python-list [mailto:python-list-bounces+dick.ginga=perkinelmer@python.org] On Behalf Of Chris Angelico Sent: Friday, December 11, 2015 1:53 PM Cc: python-list@python.org Subject: Re: w

Re: python 351x64

2015-12-11 Thread Zachary Ware
On Fri, Dec 11, 2015 at 11:53 AM, Jay Hamm wrote: > It is an issue that borks your install. That seems like your issue which > involves notepad++. You might want to talk with them about it or more likely > since they've not fixed it in a while - develop a work around or at least a > message tha

Re: How to connect the MYSQL database to Python program?

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 11:11:22 AM UTC-8, Igor Korot wrote: > Hi, > > On Fri, Dec 11, 2015 at 2:00 PM, ICT Ezy wrote: > > On Friday, December 11, 2015 at 10:52:49 AM UTC-8, larry@gmail.com > > wrote: > >> On Fri, Dec 11, 2015 at 1:36 PM, ICT Ezy wrote: > >> > On Wednesday, December

Re: How to connect the MYSQL database to Python program?

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 10:52:49 AM UTC-8, larry@gmail.com wrote: > On Fri, Dec 11, 2015 at 1:36 PM, ICT Ezy wrote: > > On Wednesday, December 9, 2015 at 9:58:02 AM UTC-8, Chris Angelico wrote: > >> On Thu, Dec 10, 2015 at 4:51 AM, ICT Ezy wrote: > >> > Pl explain me how to connect th

Re: How to connect the MYSQL database to Python program?

2015-12-11 Thread Igor Korot
Hi, On Fri, Dec 11, 2015 at 2:00 PM, ICT Ezy wrote: > On Friday, December 11, 2015 at 10:52:49 AM UTC-8, larry@gmail.com wrote: >> On Fri, Dec 11, 2015 at 1:36 PM, ICT Ezy wrote: >> > On Wednesday, December 9, 2015 at 9:58:02 AM UTC-8, Chris Angelico wrote: >> >> On Thu, Dec 10, 2015 at 4:5

Re: How to connect the MYSQL database to Python program?

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 10:52:49 AM UTC-8, larry@gmail.com wrote: > On Fri, Dec 11, 2015 at 1:36 PM, ICT Ezy wrote: > > On Wednesday, December 9, 2015 at 9:58:02 AM UTC-8, Chris Angelico wrote: > >> On Thu, Dec 10, 2015 at 4:51 AM, ICT Ezy wrote: > >> > Pl explain me how to connect th

Re: Python variable assigning problems...

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 10:27:29 AM UTC-8, Jussi Piitulainen wrote: > ICT Ezy writes: > > On Friday, December 11, 2015 at 8:40:18 AM UTC-8, Ian wrote: > >> > >> No, it actually happens left to right. "x = y = z = 0" means "assign > >> 0 to x, then assign 0 to y, then assign 0 to z." It doe

Re: wrappers for C/C++

2015-12-11 Thread Chris Angelico
On Sat, Dec 12, 2015 at 5:40 AM, Ginga, Dick wrote: > Thank you Chris for this answer. These are the _only_ versions the build > creates. Are you saying that wrappers for 3.5 "may" continue to support > future versions? That's a Windows-specific concern; there've been changes made to how the W

Re: Python variable assigning problems...

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 10:27:29 AM UTC-8, Jussi Piitulainen wrote: > ICT Ezy writes: > > On Friday, December 11, 2015 at 8:40:18 AM UTC-8, Ian wrote: > >> > >> No, it actually happens left to right. "x = y = z = 0" means "assign > >> 0 to x, then assign 0 to y, then assign 0 to z." It doe

Re: How to connect the MYSQL database to Python program?

2015-12-11 Thread Larry Martell
On Fri, Dec 11, 2015 at 1:36 PM, ICT Ezy wrote: > On Wednesday, December 9, 2015 at 9:58:02 AM UTC-8, Chris Angelico wrote: >> On Thu, Dec 10, 2015 at 4:51 AM, ICT Ezy wrote: >> > Pl explain me how to connect the MYSQL database to Python program? >> >> You start by looking for a module that lets

Re: Problem with sqlite3 and Decimal

2015-12-11 Thread Chris Angelico
On Fri, Dec 11, 2015 at 8:21 PM, Frank Millman wrote: > I noticed one oddity - I am asking sqlite3 to store the value as a string, > but then I am asking it to perform arithmetic on it. It's an SQLite3 issue, not a Python one. I used the sqlite3 stand-alone tool to do the same thing: sqlite> upd

Re: How to connect the MYSQL database to Python program?

2015-12-11 Thread ICT Ezy
On Wednesday, December 9, 2015 at 1:45:26 PM UTC-8, Mark Lawrence wrote: > On 09/12/2015 17:51, ICT Ezy wrote: > > Pl explain me how to connect the MYSQL database to Python program? > > > > Use a search engine. Then run up an editor, write some code, run said > code. If you then have problems s

Re: How to connect the MYSQL database to Python program?

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 10:36:33 AM UTC-8, ICT Ezy wrote: > On Wednesday, December 9, 2015 at 9:58:02 AM UTC-8, Chris Angelico wrote: > > On Thu, Dec 10, 2015 at 4:51 AM, ICT Ezy wrote: > > > Pl explain me how to connect the MYSQL database to Python program? > > > > You start by looking f

Re: How to connect the MYSQL database to Python program?

2015-12-11 Thread ICT Ezy
On Wednesday, December 9, 2015 at 9:58:02 AM UTC-8, Chris Angelico wrote: > On Thu, Dec 10, 2015 at 4:51 AM, ICT Ezy wrote: > > Pl explain me how to connect the MYSQL database to Python program? > > You start by looking for a module that lets you do that. You can use > your favourite web search e

Re: How to connect the MYSQL database to Python program?

2015-12-11 Thread ICT Ezy
On Wednesday, December 9, 2015 at 1:45:26 PM UTC-8, Mark Lawrence wrote: > On 09/12/2015 17:51, ICT Ezy wrote: > > Pl explain me how to connect the MYSQL database to Python program? > > > > Use a search engine. Then run up an editor, write some code, run said > code. If you then have problems s

RE: python 351x64

2015-12-11 Thread Jay Hamm
It is an issue that borks your install. That seems like your issue which involves notepad++. You might want to talk with them about it or more likely since they've not fixed it in a while - develop a work around or at least a message that pops up and asks if they want it fixed so the install suc

Re: Python variable assigning problems...

2015-12-11 Thread Jussi Piitulainen
ICT Ezy writes: > On Friday, December 11, 2015 at 8:40:18 AM UTC-8, Ian wrote: >> >> No, it actually happens left to right. "x = y = z = 0" means "assign >> 0 to x, then assign 0 to y, then assign 0 to z." It doesn't mean >> "assign 0 to z, then assign z to y, etc." This works: >> >> >>> d = d['f

Re: Python variable assigning problems...

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 10:20:30 AM UTC-8, Michael Torrie wrote: > On 12/11/2015 11:05 AM, ICT Ezy wrote: > > Deat Ian, Thank you very much your answer, but above answer from > > Robin Koch and your answer is different. What's the actually process > > here? I agree with Robin Koch, but your

Re: wrappers for C/C++

2015-12-11 Thread Chris Angelico
On Sat, Dec 12, 2015 at 4:21 AM, Ginga, Dick wrote: > I have inherited a product build that uses SWIG to product wrapper libraries > for our C/C++ code. It currently builds these wrappers for 2.5, 2.6, 3.1 and > 3.2. > > Is it necessary to have version specific wrappers? Yes, it is, because of

Re: Python variable assigning problems...

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 9:53:10 AM UTC-8, Robin Koch wrote: > Am 11.12.2015 um 17:39 schrieb Ian Kelly: > > On Fri, Dec 11, 2015 at 9:24 AM, Robin Koch wrote: > >> Assigning goes from right to left: > >> > >> x,y=y,x=2,3 > >> > >> <=> > >> > >> y, x = 2, 3 > >> x, y = y, x > >> > >> Otherw

Re: Python variable assigning problems...

2015-12-11 Thread Michael Torrie
On 12/11/2015 11:05 AM, ICT Ezy wrote: > Deat Ian, Thank you very much your answer, but above answer from > Robin Koch and your answer is different. What's the actually process > here? I agree with Robin Koch, but your answer is correct. Pl explain > differences ? If you go re-read the answers, yo

Re: Python variable assigning problems...

2015-12-11 Thread Michael Torrie
On 12/11/2015 11:00 AM, ICT Ezy wrote: > Thank you very much your answer, I had not known assignment id Right2Left > before. I done it. Except that Robin was mistaken. Assignment is indeed left to right, though what's being assigned is on the right. > -- https://mail.python.org/mailman/listi

Re: Python variable assigning problems...

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 8:40:18 AM UTC-8, Ian wrote: > On Fri, Dec 11, 2015 at 9:24 AM, Robin Koch wrote: > > Assigning goes from right to left: > > > > x,y=y,x=2,3 > > > > <=> > > > > y, x = 2, 3 > > x, y = y, x > > > > Otherwise the assignment x, y = y, x would not make any sense, since

Re: Python variable assigning problems...

2015-12-11 Thread ICT Ezy
On Friday, December 11, 2015 at 8:24:45 AM UTC-8, Robin Koch wrote: > Am 11.12.2015 um 17:10 schrieb ICT Ezy: > > Dear All, > > Very Sorry for the my mistake here. I code here with mu question ... > > > > My Question: > > > > A,B=C,D=10,11 > > print(A,B,C,D) > > #(10,11,10,11) --> This is OK! > > >

Re: Python variable assigning problems...

2015-12-11 Thread Robin Koch
Am 11.12.2015 um 17:39 schrieb Ian Kelly: On Fri, Dec 11, 2015 at 9:24 AM, Robin Koch wrote: Assigning goes from right to left: x,y=y,x=2,3 <=> y, x = 2, 3 x, y = y, x Otherwise the assignment x, y = y, x would not make any sense, since x and y haven't any values yet. And the execution fro

wrappers for C/C++

2015-12-11 Thread Ginga, Dick
I have inherited a product build that uses SWIG to product wrapper libraries for our C/C++ code. It currently builds these wrappers for 2.5, 2.6, 3.1 and 3.2. Is it necessary to have version specific wrappers? -- https://mail.python.org/mailman/listinfo/python-list

Re: python 351x64

2015-12-11 Thread Ian Kelly
On Fri, Dec 11, 2015 at 9:30 AM, Jay Hamm wrote: > Hi > > I was trying to use your windows version of python 3.5.1 x64. > > It has a conflict with a notepad++ plugin NppFTP giving > api-ms-win-crt-runtime-I1-1-0.dll error on start up. > > This seems pretty well documented on the web. The work aro

Re: python 351x64

2015-12-11 Thread Steven D'Aprano
Hi Jay, and welcome,! On Sat, 12 Dec 2015 03:30 am, Jay Hamm wrote: > Hi > > I was trying to use your windows version of python 3.5.1 x64. > > It has a conflict with a notepad++ plugin NppFTP giving > api-ms-win-crt-runtime-I1-1-0.dll error on start up. > > This seems pretty well documented o

Re: python 351x64

2015-12-11 Thread Zachary Ware
On Fri, Dec 11, 2015 at 10:30 AM, Jay Hamm wrote: > Hi > > I was trying to use your windows version of python 3.5.1 x64. > > It has a conflict with a notepad++ plugin NppFTP giving > api-ms-win-crt-runtime-I1-1-0.dll error on start up. > > This seems pretty well documented on the web. The work ar

Re: python 351x64

2015-12-11 Thread Mark Lawrence
On 11/12/2015 16:30, Jay Hamm wrote: Hi I was trying to use your windows version of python 3.5.1 x64. It has a conflict with a notepad++ plugin NppFTP giving api-ms-win-crt-runtime-I1-1-0.dll error on start up. This seems pretty well documented on the web. The work around is to delete the pl

Re: trying to force stdout to utf-8 with errors='ignore' or 'replace'

2015-12-11 Thread Adam Funk
On 2015-12-11, Peter Otten wrote: > Adam Funk wrote: >> but with either or both of those, I get the dreaded >> "UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position >> 562: ordinal not in range(128)". How can I force the output to be in >> UTF-8 & silently suppress invalid charac

python 351x64

2015-12-11 Thread Jay Hamm
Hi I was trying to use your windows version of python 3.5.1 x64. It has a conflict with a notepad++ plugin NppFTP giving api-ms-win-crt-runtime-I1-1-0.dll error on start up. This seems pretty well documented on the web. The work around is to delete the plugin and reinstall since it borks the i

Re: Python variable assigning problems...

2015-12-11 Thread Ian Kelly
On Fri, Dec 11, 2015 at 9:24 AM, Robin Koch wrote: > Assigning goes from right to left: > > x,y=y,x=2,3 > > <=> > > y, x = 2, 3 > x, y = y, x > > Otherwise the assignment x, y = y, x would not make any sense, since x and y > haven't any values yet. > > And the execution from right to left is also

Re: Python variable assigning problems...

2015-12-11 Thread Ian Kelly
On Fri, Dec 11, 2015 at 9:10 AM, ICT Ezy wrote: > Dear All, > Very Sorry for the my mistake here. I code here with mu question ... > > My Question: > > A,B=C,D=10,11 > print(A,B,C,D) > #(10,11,10,11) --> This is OK! > > a=1; b=2 > a,b=b,a > print(a,b) > # (1,2) --> This is OK! This actually resul

Re: Python variable assigning problems...

2015-12-11 Thread Robin Koch
Am 11.12.2015 um 17:10 schrieb ICT Ezy: Dear All, Very Sorry for the my mistake here. I code here with mu question ... My Question: A,B=C,D=10,11 print(A,B,C,D) #(10,11,10,11) --> This is OK! a=1; b=2 a,b=b,a print(a,b) # (1,2) --> This is OK! x,y=y,x=2,3 print(x,y) # (3,2) --> Question: How

Re: Python variable assigning problems...

2015-12-11 Thread ICT Ezy
Dear All, Very Sorry for the my mistake here. I code here with mu question ... My Question: A,B=C,D=10,11 print(A,B,C,D) #(10,11,10,11) --> This is OK! a=1; b=2 a,b=b,a print(a,b) # (1,2) --> This is OK! x,y=y,x=2,3 print(x,y) # (3,2) --> Question: How to explain it? # Not understand this proce

Re: python script for dwonload free anything?

2015-12-11 Thread hienmizu
thank you laura, but i know this paid 3d model: http://www.nonecg.com/tokyo-shibuya.html. do you know that -- https://mail.python.org/mailman/listinfo/python-list

Re: python script for dwonload free anything?

2015-12-11 Thread Mark Lawrence
On 11/12/2015 14:29, hienm...@gmail.com wrote: i want create script for download free 3d model from nonecg.com like https://github.com/nishad/udemy-dl-windows , this script download free udemy video lesson. Anyone can tell e, how to create script like that? Any (semi)decent IDE and/or editor

Re: python script for dwonload free anything?

2015-12-11 Thread Laura Creighton
In a message of Fri, 11 Dec 2015 06:29:33 -0800, hienm...@gmail.com writes: >i want create script for download free 3d model from nonecg.com like >https://github.com/nishad/udemy-dl-windows , this script download free udemy >video lesson. Anyone can tell e, how to create script like that? >-- >h

Re: Problem with sqlite3 and Decimal (fwd)

2015-12-11 Thread Igor Korot
Hi, Frank, On Fri, Dec 11, 2015 at 9:27 AM, Frank Millman wrote: > "Igor Korot" wrote in message > news:CA+FnnTyaLLEsYGU7v2BreySDOQ1rVsMzJ=5f4iQTLW3=tn=e...@mail.gmail.com... > >> Hi, >> >> > To: python-list@python.org >> > From: "Frank Millman" >> > Subject: Problem with sqlite3 and Decimal >

python script for dwonload free anything?

2015-12-11 Thread hienmizu
i want create script for download free 3d model from nonecg.com like https://github.com/nishad/udemy-dl-windows , this script download free udemy video lesson. Anyone can tell e, how to create script like that? -- https://mail.python.org/mailman/listinfo/python-list

Re: Problem with sqlite3 and Decimal (fwd)

2015-12-11 Thread Frank Millman
"Igor Korot" wrote in message news:CA+FnnTyaLLEsYGU7v2BreySDOQ1rVsMzJ=5f4iQTLW3=tn=e...@mail.gmail.com... Hi, > To: python-list@python.org > From: "Frank Millman" > Subject: Problem with sqlite3 and Decimal > Date: Fri, 11 Dec 2015 11:21:53 +0200 > Lines: 71 > > Hi all > > I need to store De

Re: Problem with sqlite3 and Decimal (fwd)

2015-12-11 Thread Igor Korot
Hi, On Fri, Dec 11, 2015 at 8:45 AM, Laura Creighton wrote: > From python-list. > Very weird. > Another reason not to use sqlite3 > > --- Forwarded Message > > To: python-list@python.org > From: "Frank Millman" > Subject: Problem with sqlite3 and Decimal > Date: Fri, 11 Dec 2015 11:21:53 +02

Problem with sqlite3 and Decimal (fwd)

2015-12-11 Thread Laura Creighton
>From python-list. Very weird. Another reason not to use sqlite3 --- Forwarded Message To: python-list@python.org From: "Frank Millman" Subject: Problem with sqlite3 and Decimal Date: Fri, 11 Dec 2015 11:21:53 +0200 Lines: 71 Hi all I need to store Decimal objects in a sqlite3 database, us

Problem with sqlite3 and Decimal

2015-12-11 Thread Frank Millman
Hi all I need to store Decimal objects in a sqlite3 database, using Python 3.4 on Windows 7. I followed the instructions here - http://stackoverflow.com/questions/6319409/how-to-convert-python-decimal-to-sqlite-numeric It seemed to work well, but then I hit a problem. Here is a stripped-do

mush 2.0 released! - Type-based dependency injection for scripts

2015-12-11 Thread Chris Withers
Hi All, I'm very happy to announce a new release of Mush, a light weight dependency injection framework aimed at enabling the easy testing and re-use of chunks of code that make up scripts. This release is a re-write dropping all the heuristic callable ordering in favour of building up defin

Re: trying to force stdout to utf-8 with errors='ignore' or 'replace'

2015-12-11 Thread Peter Otten
Adam Funk wrote: > I'm fiddling with a program that reads articles in the news spool > using email.parser (standard library) & > email_reply_parser.EmailReplyParser (installed with pip). Reading is > fine, & I don't get any errors writing output extracted from article > bodies *until* I try to su

trying to force stdout to utf-8 with errors='ignore' or 'replace'

2015-12-11 Thread Adam Funk
I'm fiddling with a program that reads articles in the news spool using email.parser (standard library) & email_reply_parser.EmailReplyParser (installed with pip). Reading is fine, & I don't get any errors writing output extracted from article bodies *until* I try to suppress invalid characters.

Re: How to use internal python c funtions, from python code

2015-12-11 Thread dieter
srinivas devaki writes: > but still I think it would be cool to be able to access internal c > functions without any fuss. I can use such feature with heapq too(sift > operations), Have a look at "Cython". It is a compiler which compiles a language similar to Python with special extensions for a

Re: SystemError in python 2.5.4

2015-12-11 Thread dieter
Palpandi writes: > I am getting the error mentioned below in python 2.5.4. > > SystemError: \loewis\25\python\Objects\longobject.c:225: bad argument to > internal function. > > I also ran the same code in python 2.7. > There I am not getting this error. > > I don't know which causes this error.

Re: SystemError in python 2.5.4

2015-12-11 Thread Steven D'Aprano
On Thu, 10 Dec 2015 10:29 pm, Palpandi wrote: > Hi All, > > I am getting the error mentioned below in python 2.5.4. > > SystemError: \loewis\25\python\Objects\longobject.c:225: bad argument to > internal function. Sounds like your installation of Python is broken. You should never get an intern