Re: [Tutor] How should my code handle db connections? Should my db manager module use OOP?

2015-08-27 Thread Steven D'Aprano
On Wed, Aug 26, 2015 at 10:22:25PM -0500, Zachary Ware wrote: On Aug 26, 2015 9:03 PM, Steven D'Aprano st...@pearwood.info wrote: - If your database lives on a NTFS partition, which is very common for Linux/Unix users snip these issues, especially on Linux when using NTFS. Surely you

[Tutor] tkinter in Python 3

2015-08-27 Thread Michael Thomas
I'm trying to move a Python 2.x program to Python 3.x. When I try to import tkinter I get the error message that no module _tkinter can be found. I've tried sudo apt-get install python-tk. While this command works, there is no difference in the result. This problem has only cropped up after I

Re: [Tutor] tkinter in Python 3

2015-08-27 Thread Rohan S
I am trying to download a version of Pygame that is compatible with Python 2.7.10; when I try to run a simple program, I get an error message stating that terms like livewires, Sprite, pygame, and screen, are unresolved references, and so I assume that downloading pygame could solve this problem.

[Tutor] Pygame in v2 was: Re: tkinter in Python 3

2015-08-27 Thread Alan Gauld
On 27/08/15 22:29, Rohan S wrote: I am trying to download a version of Pygame that is compatible with Python 2.7.10; While a similar problem it would have been better to start a new thread. These are quite different problems. However... when I try to run a simple program, I get an error

Re: [Tutor] tkinter in Python 3

2015-08-27 Thread Alan Gauld
On 27/08/15 18:21, Michael Thomas wrote: I'm trying to move a Python 2.x program to Python 3.x. When I try to import tkinter I get the error message that no module _tkinter can be found. I've tried sudo apt-get install python-tk. Thats the Python2 version Try apt-get install python3-tk Note

Re: [Tutor] value range checker

2015-08-27 Thread Peter Otten
Albert-Jan Roskam wrote: I have a written a function checks the validity of values. The ranges of valid values are stored in a database table. Such a table contains three columns: category, min and max. One record of such a table specifies the range for a certain category, but a category

Re: [Tutor] How should my code handle db connections? Should my db manager module use OOP?

2015-08-27 Thread Alan Gauld
On 27/08/15 01:11, boB Stepp wrote: My ongoing project will be centered around an SQLite db. Since almost all data needed by the program will be stored in this db, my thought is that I should create a connection to this db shortly after program startup and keep this connection open until

Re: [Tutor] How should my code handle db connections? Should my db manager module use OOP?

2015-08-27 Thread Peter Otten
boB Stepp wrote: My ongoing project will be centered around an SQLite db. Since almost all data needed by the program will be stored in this db, my thought is that I should create a connection to this db shortly after program startup and keep this connection open until program closure. I am