Re: How to get 'od' run?

2015-11-11 Thread Michael Torrie
On 11/11/2015 08:04 PM, fl wrote: > Hi, > > I am learning python. I see a previous post has such code: > > > > > >>>> data = '"binääridataa"\n'.encode('utf-8') >>>> f = open('roska.txt', 'wb') >>>> f.write(data) >17 >>>> f.close() > > The .encode methods produced a b

Re: Python.exe is not a valid Win32 application error message

2015-11-11 Thread Michael Torrie
On 11/11/2015 10:21 AM, Quivis wrote: > On Tue, 10 Nov 2015 00:34:23 +, M. Kamisato wrote: > >> I am running python on Windows XP SP3 and download version 3.5xx. I got >> the above error message and could not run the program. >> I have downloaded Python version 2.7xx and it runs fine. >> Is t

Re: Python.exe is not a valid Win32 application error message

2015-11-11 Thread Michael Torrie
On 11/11/2015 06:13 AM, Chris Angelico wrote: > On Tue, Nov 10, 2015 at 11:34 AM, M. Kamisato via Python-list > wrote: >> I am running python on Windows XP SP3 and download version 3.5xx. I got the >> above error message and could not run the program. >> I have downloaded Python version 2.7xx an

Re: using binary in python

2015-11-10 Thread Michael Torrie
On 11/10/2015 02:29 PM, kent nyberg wrote: > On Mon, Nov 09, 2015 at 10:20:25PM -0800, Larry Hudson via Python-list wrote: >> Your questions are somewhat difficult to answer because you misunderstand >> binary. The key is that EVERYTHING in a computer is binary. There are NO >> EXCEPTIONS, it's a

Re: Puzzled

2015-11-08 Thread Michael Torrie
On 11/06/2015 02:36 PM, Robinson, Wendy wrote: > Ah, ok I get it now. > Thanks both! Glad you got it! Thanks for letting us know, too. -- https://mail.python.org/mailman/listinfo/python-list

Re: Question about math.pi is mutable

2015-11-08 Thread Michael Torrie
On 11/08/2015 04:19 AM, BartC wrote: >> That elegant dynamism comes at a cost: method lookup is not a constant >> memory offset. Rather, it is a dictionary lookup. > > I've never understood why this seems to be necessary in Python. Why do > names have to be looked up? (I'm assuming this is searc

Re: Guide in Deskop Application Development in Python for newbies

2015-11-07 Thread Michael Torrie
On 11/07/2015 12:15 PM, paul.hermeneu...@gmail.com wrote: > Where would you say that web2py fits into this mix > of tools? I am not familiar with it but I know it's supposed to be a lightweight framework for developing web-based sites and applications. Could be an excelle

Re: Scipy odeint (LSODA) gives inaccurate results; same code fine in MATLAB ode15s/ode23s

2015-11-07 Thread Michael Torrie
On 11/06/2015 11:54 PM, Christian Gollwitzer wrote: > It is very hard to analyze such a problem, unless you also post the > Matlab code and plot both solutions into a single graph. Also he may have a quicker response posting to the scipy list, where scientists and mathematicians regularly use and

Re: Guide in Deskop Application Development in Python for newbies

2015-11-07 Thread Michael Torrie
On 11/07/2015 07:44 AM, leonardmesi...@gmail.com wrote: > How do you start building a desktop application in python? I mean > where do I start? Besides installing python on your windows what else > do I need, and any suggestion on how do I accomplish this project. > > Right now I really want to fi

Re: Puzzled

2015-11-05 Thread Michael Torrie
On 11/05/2015 04:10 PM, Laura Creighton wrote: > In a message of Thu, 05 Nov 2015 12:48:11 -0800, "Robinson, Wendy" writes: >> Well... I still can't get this to work. I guess I'll just uninstall it. >> It's a bummer that there's no help on basic startup like this. >> >> Wendy Robinson >> Audit Anal

Re: Regular expressions

2015-11-04 Thread Michael Torrie
On 11/04/2015 01:57 AM, Peter Otten wrote: > and then headed for the man page. Apparently there is a subset > called "basic regular expressions": > > """> Basic vs Extended Regular Expressions >In basic regular expressions the meta-characters ?, +, {, |, (, >and ) lose their speci

Re: Regular expressions

2015-11-03 Thread Michael Torrie
On 11/03/2015 08:23 PM, Steven D'Aprano wrote: >>> Grep can use regular expressions (and I do so with it regularly), but >>> it's default mode is certainly not regular expressions ... >> >> Its very name indicates that its default mode most certainly is regular >> expressions. > > I don't even kno

Re: Regular expressions

2015-11-03 Thread Michael Torrie
On 11/03/2015 05:33 PM, rurpy--- via Python-list wrote: > I consider regexs more fundemental. One need not even be a programmer > to use them: consider grep, sed, a zillion editors, database query > languages, etc. Grep can use regular expressions (and I do so with it regularly), but it's defaul

Re: Puzzled

2015-11-02 Thread Michael Torrie
On 11/02/2015 08:52 AM, Robinson, Wendy wrote: > [cid:image001.png@01D11543.5ED11D50] Just FYI this mailing list group is tied with with a system called USENET which is plain text only, so most of us can't see your attachment. This may help you copy the text to your messages in plain text form:

Re: Regular expressions

2015-11-02 Thread Michael Torrie
On 11/02/2015 09:23 PM, rurpy--- via Python-list wrote: >> My completely unsolicited advice is that regular expressions shouldn't be >> very high on the list of things to learn. They are very useful, and very >> tricky and prone many problems that can and should be learned to be >> resolved with m

Re: Regular expressions

2015-11-02 Thread Michael Torrie
On 11/02/2015 09:23 PM, rurpy--- via Python-list wrote: > On 11/02/2015 08:51 PM, Michael Torrie wrote: >> [...] >> Indeed, sometimes Jamie Zawinski's is often quite appropriate: >> >> Some people, when confronted with a problem, think "I know, I'll

Re: Regular expressions

2015-11-02 Thread Michael Torrie
On 11/02/2015 07:42 PM, Tim Chase wrote: > On 2015-11-02 20:09, Seymore4Head wrote: >> How do I make a regular expression that returns true if the end of >> the line is an asterisk > > Why use a regular expression? > > if line[-1] == '*': > yep(line) > else: > nope(line) Indeed, some

Re: Detection of a specific sound

2015-11-02 Thread Michael Torrie
On 10/25/2015 06:17 PM, Montana Burr wrote: > I'm looking for a library that will allow Python to listen for the shriek > of a smoke alarm. Once it detects this shriek, it is to notify someone. > Ideally, specificity can be adjusted for the user's environment. For > example, I expect to need modera

Re: installer user interface glitch ?

2015-11-01 Thread Michael Torrie
On 11/01/2015 03:08 AM, Chris Angelico wrote: > Windows XP has now been around for twelve years. It's older than that. Release date was August 1, 2001. More than 14 years ago. My how the time flies. Though more recent versions of Windows have added features (which Python now takes advantage o

Re: UNABLE TO GET IDLE TO RUN

2015-10-28 Thread Michael Torrie
On 10/28/2015 12:21 PM, Peter Otten wrote: > PS: The shell people have learned their lesson and no longer include the > working directory in the PATH: > $ ls # the real thing > $ ./ls # use at your own risk Sure but this is a somewhat different genre. > > So maybe > import string # stdl

Re: UNABLE TO GET IDLE TO RUN

2015-10-28 Thread Michael Torrie
On 10/28/2015 10:10 AM, Peter Otten wrote: > Terry Reedy wrote: > > Thank you for your patience. > >> Why do you think it a misfeature for IDLE to execute code the way Python >> does? > > Sadly I wasn't aware that the interactive interpreter is also vulnerable. > I should have been, but failed t

Re: teacher need help!

2015-10-20 Thread Michael Torrie
On 10/20/2015 10:25 AM, Storey, Geneva wrote: > FYI-We formatted the machines, reinstalling everything, including > Python. I works with no problems now. Confusing that this would > happen on 3 out of 13 machines. Just letting you know, all is well. > Thank you for your help! Geneva Wow that se

Re: Defamation

2015-10-19 Thread Michael Torrie
On 10/19/2015 08:14 AM, Chris Angelico wrote: > On Mon, Oct 19, 2015 at 7:31 AM, gaini2002--- via Python-list > wrote: >> Please remove the page > > That page is just spam that someone sent to the newsgroup/mailing > list. You can ignore it, same as the rest of us do. > > Even if the page were to

Re: teacher need help!

2015-10-18 Thread Michael Torrie
On 10/17/2015 05:46 PM, Storey, Geneva wrote: > I am teaching a coding class to students grades 7-12. We have been > using Python, which seems to be a perfect fit. Everything was going > great until this week when I began teaching turtle. Suddenly, of the > 13 computers that I have, 3 began givi

Re: Where is the menu bar for 3.5?

2015-10-18 Thread Michael Torrie
On 10/17/2015 09:27 PM, Peachy Keen wrote: > I am learning to code and I downloaded Python 3.5 32bit. But I can't > find the menu bar and after much frustration I uninstalled the > program. I would like to get started again so if you could assist it > would be appreciated. Python itself is in inte

Re: Strong typing implementation for Python

2015-10-12 Thread Michael Torrie
On 10/12/2015 06:07 PM, Steven D'Aprano wrote: > Where is the "vast amounts of noise" added to the code? Well in Java code for one. No wonder they require auto-completion. Java class-based namespaces must be a nightmare to work with. That and all the over-use of design patterns that Java librari

Re: Strong typing implementation for Python

2015-10-12 Thread Michael Torrie
On 10/12/2015 02:47 AM, John Michael Lafayette wrote: > Now that Python has static type checking and support for IDE auto-complete > (PEP 484?), I beg you to please use it. In your standard library, in your > production code, in everywhere. I cannot type without auto-complete. > > I know that soun

Re: Strong typing implementation for Python

2015-10-12 Thread Michael Torrie
On 10/12/2015 07:30 AM, Bartc wrote: > On 12/10/2015 03:45, Michael Torrie wrote: >> On 10/11/2015 06:34 PM, Steven D'Aprano wrote: >>> That's called type inference, and there's nothing innovative about Swift to >>> include that as a feature. Type

Re: Strong typing implementation for Python

2015-10-11 Thread Michael Torrie
On 10/11/2015 06:34 PM, Steven D'Aprano wrote: > That's called type inference, and there's nothing innovative about Swift to > include that as a feature. Type inference is *old*. The theory behind type > inference goes back to 1958, and languages such as ML and OCaml have > included it for decades,

Re: Strong typing implementation for Python

2015-10-10 Thread Michael Torrie
On 10/09/2015 10:26 AM, John Michael Lafayette wrote: > I would like Python to have a strong typing feature that can co-exist with > the current dynamic typing system. Currently Python is like this: > > var animal = Factory.make("dog") # okay. > var dog = Factory.make("dog") # okay.

Re: Recover data over the network

2015-10-09 Thread Michael Torrie
On 10/09/2015 09:44 PM, William Ray Wing wrote: > I hesitate to mention this, but there _may_ be a communication > problem here. When American-English speakers refer to data recovery, > they usually are discussing reading data from a disk that has > suffered some catastrophic event, say a head cras

Re: Recover data over the network

2015-10-09 Thread Michael Torrie
On 10/09/2015 08:47 PM, Arshpreet Singh wrote: > On Friday, 9 October 2015 22:51:16 UTC+5:30, Emile van Sebille wrote: > >> without extensive clues as to the nature of the data to be recovered >> you're not going to get much further with this. > > It is mostly /home partition data on disk. T

Re: PySide window does not resize to fit screen

2015-10-05 Thread Michael Torrie
On 10/05/2015 05:20 AM, Hedieh Ebrahimi wrote: > is this free to use for commercial use? Yes of course. There's also the newer Qt Creator program if you want to use Qt 5. The license of the Designer and Creator programs does not apply to the output of these programs (the .ui XML files). You'll

Re: Newbie: Designer Looking to Build Graphics Editor (PS/AI)

2015-10-03 Thread Michael Torrie
On 10/02/2015 02:23 PM, Kenneth L wrote: > No don't tell me what to do. I joined the military 3 years ago. You > wouldn't believe the stuff I wasn't able to do before but now I am. > You can keep your advice to yourself. I wasn't asking for something > simple. I was asking for a starting point. The

Re: Pyserial and Ubuntu Linux kernel 3.13.0-65-generic

2015-10-03 Thread Michael Torrie
On 10/03/2015 03:19 AM, Laura Creighton wrote: > With better searching, I find this bug. > https://bugs.launchpad.net/ubuntu/+source/linux-lts-trusty/+bug/1501345 > > Looks like that's the real one. This ubuntu bug and the other bug you mention seem to be about FTDI devices. Rob said in his origi

Re: Successfully send sms with python

2015-09-22 Thread Michael Torrie
On 09/22/2015 05:19 AM, Timon Rhynix wrote: > When run it, the "message sent!" is printed but no message is sent/delivered. > Please assist on what I am missing. Thank you Is this "message sent!" from your code or is it a message you get back on the serial port from the gsm modem? Oh nevermind I s

Re: Einstein's Riddle

2015-09-19 Thread Michael Torrie
On 09/18/2015 03:51 AM, Nick Sarbicki wrote: > On Fri, Sep 18, 2015 at 10:33 AM, Steven D'Aprano >> Time is relative. Perhaps the poster has been travelling at close to the >> speed of light, and for him it is only a few minutes after the original >> post was sent. > > I prefer to think that it j

Re: Terminology: "reference" versus "pointer"

2015-09-12 Thread Michael Torrie
On 09/12/2015 08:22 PM, Mark Lawrence wrote: > You appear to have the same level of knowledge of Python internals as > the RUE has of the Python 3.3+ FSR unicode implementation. Let's have > some fun, is Python pass by value or pass by reference? It has to be > more interesting debating that t

Re: Python handles globals badly.

2015-09-12 Thread Michael Torrie
On 09/11/2015 11:22 PM, Skybuck Flying wrote: > I didn't learn anything from this posting, sorry ! ;) I too am not surprised. You're not here to learn, either about programming language theory, or about Python apparently. I would refer you to a good programming language theory class, but I suspe

Re: Python handles globals badly.

2015-09-11 Thread Michael Torrie
On 09/11/2015 06:11 PM, random...@fastmail.us wrote: > On Fri, Sep 11, 2015, at 20:01, Michael Torrie wrote: >> The secret to understanding the global keyword is to understand how >> Python namespaces work. The statement "a=5" does not assign a 5 to the >> box c

Re: Python handles globals badly.

2015-09-11 Thread Michael Torrie
On 09/11/2015 03:50 PM, Skybuck Flying wrote: > Something which python does not seem to do currently ?! > > So that's weird. > > I will leave it at that for now. Seems to me you have a completely mistaken understanding of how variables work in Python. This is one of the reasons why I have said

Re: Python handles globals badly.

2015-09-10 Thread Michael Torrie
On 09/10/2015 01:27 AM, Antoon Pardon wrote: > Op 09-09-15 om 19:55 schreef Steven D'Aprano: >> In fairness to the C creators, I'm sure that nobody back in the early >> seventies imagined that malware and security vulnerabilities would be as >> widespread as they have become. But still, the fundame

Re: Python handles globals badly.

2015-09-08 Thread Michael Torrie
On 09/08/2015 09:56 AM, Steven D'Aprano wrote: > http://exple.tive.org/blarg/2013/10/22/citation-needed/ > > It's a wonderful read. I read this article, but I'm still uncertain to what his point actually is. It's a great review of the history of C, some batch computing, and IBM's CEO's penchant

Re: Trying pmw with python3: Lots of crashes!

2015-09-06 Thread Michael Torrie
On 09/06/2015 12:47 PM, Paulo da Silva wrote: > Do I need to go to more complex system like wxwidgets or pyside (QT)? > I looked at the last one but, from the 1st steps, it seems too complex. Before anyone can suggest toolkits to look at, what kind of GUI are you trying to build? What kind of "co

Re: Python handles globals badly.

2015-09-04 Thread Michael Torrie
On 09/04/2015 06:27 PM, Chris Angelico wrote: > If you want the first one, well, there are languages like that, and > you're welcome to use those. For the latter, it's easy enough to do > something like this: > > import types > _g = types.SimpleNamespace() > > def accumulate(x): > _g.accum +=

Re: Python handles globals badly.

2015-09-03 Thread Michael Torrie
On 09/03/2015 01:05 PM, t...@freenet.de wrote: > And a compiler can surely recognize if a defined var xxx outside is > not a var yyy inside a function. At issue here is the idea of Python namespaces and how Python uses them in a consistent way with your code. The consistency is that binding of a

Re: Python handles globals badly.

2015-09-03 Thread Michael Torrie
On 09/03/2015 10:15 AM, Ian Kelly wrote: > The only person whom I see talking about this in this thread is you > disclaiming that you're not talking about it. (And I guess Skybuck is > talking about it, but I don't see those.) I have a vague memory of Skybuck talking about globals over a year ago.

Re: Python handles globals badly.

2015-09-03 Thread Michael Torrie
On 09/03/2015 07:22 AM, t...@freenet.de wrote: > First topic: > "sharing globals between modules" > Where globals is meant as vars used throughout the app. > > This is the topic why Skybuck starts the thread. The answer to this is simple and elegant. Use a third module to store globals. Each mod

Re: Why Python is not both an interpreter and a compiler?

2015-09-01 Thread Michael Torrie
On 08/31/2015 02:35 AM, Mahan Marwat wrote: > What I know about an interpreter and a compiler is: they both convert > source code to machine code and the only difference is, an > interpreter convert it, line by line while compiler convert the whole > source file. Now if we compile a C source file o

Re: OFF-TOPIC Ben's sig monster quote [was Re: Parametrized Unit Tests]

2015-08-28 Thread Michael Torrie
On 08/28/2015 01:27 AM, Ben Finney wrote: > -- > \ “Capitalism is the astounding belief that the most wickedest of | > `\men will do the most wickedest of things for the greatest good | > _o__) of everyone.” —John Maynard Keynes | Now that is an interestin

Re: How to reassign the value of the variable on runtime?

2015-08-27 Thread Michael Torrie
On 08/27/2015 02:21 PM, Ivan Evstegneev wrote: > Thanks for the reply, I've got your point, furthermore tried to make imports > as you've told but ended up with kind of an opposite result. > > Maybe I've explained myself not clear enough. If you don't mind I'll bring > back the piece of my code he

Re: How to reassign the value of the variable on runtime?

2015-08-27 Thread Michael Torrie
On 08/27/2015 12:25 PM, Ivan Evstegneev wrote: > Can some please (I mean very please) explain me how do I reassign > "engine_object" and "meta_object" variables, > so they would store(point to) a new connection objects of my database, > while other functions still would see those variables as thei

Re: Sometimes bottle takes a lot of time

2015-08-23 Thread Michael Torrie
On 08/23/2015 08:05 AM, Johannes Bauer wrote: > By git bisect he can find out where > he introduced the bug. Like Cecil said, this is of little help. There was no code changed from when he didn't notice the behavior until he did. >> Note that this says nothing about the location of the bug, in c

Re: Sometimes bottle takes a lot of time

2015-08-22 Thread Michael Torrie
On 08/22/2015 05:37 AM, Cecil Westerhof wrote: >> I don't know. Is it bottle, or the browser, or something completely >> different that eats the extra time? > > I really do not know. I suspect bottle, but I am new to this, so I > value the suspicion of someone who has more experience more. :-D T

Re: SQLite3 and web server

2015-08-21 Thread Michael Torrie
On 08/21/2015 08:19 AM, Michael Torrie wrote: > But of course you can use straight CGI with Apache too. Probably this > is the easiest way for you to get started. Don't try to run your own > http server. That's just a waste of time and effort. Run the CGIs under > Apache.

Re: SQLite3 and web server

2015-08-21 Thread Michael Torrie
On 08/21/2015 03:44 AM, Cecil Westerhof wrote: > Interesting, but it does not help me. I need to know how to server > data from SQLite instead of static files. Is your program already working with data coming from your Python dict? If so, you would just replace the python dict lookups with a call

Re: Old DbaseV DOS Programmer wants to step over to new/actual modern program software

2015-08-16 Thread Michael Torrie
On 08/16/2015 10:40 AM, AGOSTINHO TEIXEIRA wrote: > I'm a 25year DBASE-5 DOS programmer and want/have to step over to new > program/platform software, because there is no future anymore for DOS > after W-XP, I've been looking around for alternatives and cannot > figure out where to start, I already

Re: Encrypted web mail

2015-08-15 Thread Michael Torrie
On 08/15/2015 03:47 AM, Uri Even-Chen wrote: > To Python, Django and Speedy Mail Software developers, > > Is it possible to make Speedy Mail encrypted? I want mail to be encrypted > on the server, and only the user will be able to read his/her mail. The > user's password will be encrypted on the s

Re: Is Django the way to go for a newbie?

2015-08-13 Thread Michael Torrie
On 08/13/2015 07:30 PM, Rustom Mody wrote: > Nothing specifically Django I am getting at. > Just that learning > - a templating engine -- eg Cheetah, Mako > - an ORM eg SQLAlchemy > - etc > > is more fun than learning to chant the right mantras that a framework > demands without any clue of what/w

Re: Is Django the way to go for a newbie?

2015-08-13 Thread Michael Torrie
On 08/10/2015 10:08 PM, Rustom Mody wrote: > On Tuesday, August 11, 2015 at 8:59:47 AM UTC+5:30, Michael Torrie wrote: >> On 08/10/2015 07:49 PM, Dwight GoldWinde wrote: >>> Thank you, Gary, for this new information. >>> >>> I will be looking into virtual

[Back off topic] - Re: Hooking Mechanism when Entering and Leaving a Try Block

2015-08-13 Thread Michael Torrie
On 08/13/2015 12:28 AM, Sven R. Kunze wrote: > On 12.08.2015 20:44, Sven R. Kunze wrote: >> On 12.08.2015 18:11, Chris Angelico wrote: >>> Sounds to me like you want some sort of AST transform, possibly in an >>> import hook. Check out something like MacroPy for an idea of how >>> powerful this sor

[OT] unwritten list etiquette ate, was Re: Hooking Mechanism when Entering and Leaving a Try Block

2015-08-13 Thread Michael Torrie
On 08/13/2015 12:26 AM, Sven R. Kunze wrote: > > Btw. to me, the *context is the entire post*, not just two lines. You're a very rare person indeed. Most people seem to not read any of the post except the first and last lines. At least posting inline shows me they've read and understood the porti

Re: Real-time recoding of video from asx to non-Windows formats

2015-08-13 Thread Michael Torrie
On 08/12/2015 12:04 AM, Montana Burr wrote: > I'm interested in using Python to create a server for streaming my > state's traffic cameras - which are only available as Windows Media streams > - to devices that do not natively support streaming Windows Media content > (think Linux computers & i

Re: Is Django the way to go for a newbie?

2015-08-10 Thread Michael Torrie
On 08/10/2015 07:49 PM, Dwight GoldWinde wrote: > Thank you, Gary, for this new information. > > I will be looking into virtualenv and vertualenvwrapper. > > I thought that Django was an IDE. But, it seems that an IDE is one more > thing that I need that I didn¹t know I needed!? Django is a prog

Re: Is Django the way to go for a newbie?

2015-08-09 Thread Michael Torrie
On 08/08/2015 10:08 PM, Dwight GoldWinde wrote: > I am both new to Python and I haven¹t even touched Django yet. > > I understand I that I need Django or something like it to develop my > website. > > From what I have read, Python and Django somewhat go together. > > Is that true? > > Or is the

Re: python for barcode

2015-08-06 Thread Michael Torrie
On 08/06/2015 12:27 PM, Xxx Ooo wrote: > I try to do a program to modify barcode which kind of like "Msoffice" > if you suggestion? You'll have to explain better what you're looking for and what you've done so far. Also explain how this relates to Python. I have no idea what "like 'Msoffice'" me

Re: QUEST: does HACKING make FOR loop quicker.

2015-08-05 Thread Michael Torrie
On 08/05/2015 03:39 PM, Mark Lawrence wrote: > On 05/08/2015 21:00, John Doe wrote: > > Three strikes and you're out, good bye troll. While the original post is incomprehensible to me, I see only one post. What were the other two strikes? -- https://mail.python.org/mailman/listinfo/python-list

Re: Most Pythonic way to store (small) configuration

2015-08-04 Thread Michael Torrie
On 08/04/2015 08:19 PM, Cameron Simpson wrote: > So on the whole I am against python code as the config file format. Really, > who > needs a Turing complete configuration file? In Django's case, since you're intimately referring to certain classes and methods, particularly in the url mapping sec

Re: Most Pythonic way to store (small) configuration

2015-08-04 Thread Michael Torrie
On 08/04/2015 08:44 PM, random...@fastmail.us wrote: > On Tue, Aug 4, 2015, at 21:32, Michael Torrie wrote: >> In many of my projects I put basic config variables in a file like >> config.py and import that in each module that needs it. The config >> module doubles as a

Re: Most Pythonic way to store (small) configuration

2015-08-04 Thread Michael Torrie
On 08/04/2015 01:59 PM, Ben Finney wrote: > marco.naw...@colosso.nl writes: > >> Why not use Python files itself as configuration files? > > Because configuration data will be user-editable. (If it's not > user-editable, that is itself a poor design choice.) > > If you allow executable code to b

Re: Integers with leading zeroes

2015-07-23 Thread Michael Torrie
On 07/22/2015 07:51 AM, Grant Edwards wrote: > On 2015-07-22, Ben Finney wrote: >> Laura Creighton writes: >> >>> The biggest use I have for decimal numbers that begin with 0 is in >>> credit card numbers, account numbers and the like where the first >>> check you do is 'does this thing have the

Re: [OT] Can I copy/paste Python code?

2015-07-22 Thread Michael Torrie
On 07/22/2015 01:35 PM, Grant Edwards wrote: > That must be using something other than the standard X11 clipboard > copy/paste mechnism. You shouldn't have to "right click copy", and > many of the apps I paste into don't even have a "right click paste". > > It sounds like evince has abandoned the

Re: Can I copy/paste Python code?

2015-07-21 Thread Michael Torrie
On 07/21/2015 06:12 PM, Grant Edwards wrote: > > I don't want to close the TOC panel. I want to collapse all the > entries in the TOC tree widget _in_ the TOC panel. Ahh. Atril does not do this either. It can collapse the TOC to the first level items but not the tree itself. I'm curious as to

Re: Can I copy/paste Python code?

2015-07-21 Thread Michael Torrie
On 07/21/2015 03:47 PM, Grant Edwards wrote: > I'm trying to switch from acroread to evince, bit it has a few serious > usability problems for me: > > 1) You can't copy/paste text from evince _at_all_. At least it works > right most of the time with acroread. I really like being able >

Re: Is there a way to install ALL Python packages?

2015-07-20 Thread Michael Torrie
On 07/20/2015 08:57 PM, ryguy7272 wrote: > I'd like to install ALL Python packages on my machine. Even if it > takes up 4-5GB, or more, I'd like to get everything, and then use it > when I need it. Now, I'd like to import packages, like numpy and > pandas, but nothing will install. I figure, if

Re: Should non-security 2.7 bugs be fixed?

2015-07-19 Thread Michael Torrie
On 07/19/2015 11:33 PM, Michael Torrie wrote: > For the most part, > it's been good to hear from Cecil (there have been a few snarky posts) > as he has learned python and really run with it. I don't understand > where your apparent frustration with Cecil is coming from.

Re: Should non-security 2.7 bugs be fixed?

2015-07-19 Thread Michael Torrie
On 07/19/2015 06:27 PM, Mark Lawrence wrote: > On 20/07/2015 00:23, Cecil Westerhof wrote: >> No use replying anymore. You make a caricature of what I am saying and >> put words in my mouth I never said. Just stay in your cosy ivory >> tower. But please do not pretend that you are open for discussi

Re: Need assistance

2015-07-19 Thread Michael Torrie
On 07/19/2015 06:21 PM, Rick Johnson wrote: > On Sunday, July 19, 2015 at 6:07:14 PM UTC-5, craig...@gmail.com wrote: >> def main(): >> name= input('Enter your full name: ') >> split=name.split() >> Full_name=split[2],split[0], split[1] >> print(Full_name[2],',', Full_name[0], Full

Re: Need assistance

2015-07-19 Thread Michael Torrie
On 07/19/2015 05:06 PM, craig.si...@gmail.com wrote: > def main(): name= input('Enter your full name: ') > split=name.split() > Full_name=split[2],split[0], split[1] > print(Full_name[2],',', Full_name[0], Full_name[1]) > > main() > > Sorry it took so long to get back to you guys an

Re: Need assistance

2015-07-18 Thread Michael Torrie
On 07/18/2015 03:44 PM, Dennis Lee Bieber wrote: > The new units (HP28, 48, 49, 50, etc.) no longer use the 4-register > stack; the stack is whatever is available in memory. As a result, the Roll > instructions now need an argument for how many stack entries are in play. > > The HP50g

Re: Need assistance

2015-07-16 Thread Michael Torrie
On 07/16/2015 08:44 PM, Joseph Lee wrote: > Hi Michael, > I have talked to this guy offlist (basically you gave him the answer > (smiles)). > Cheers, > Joseph Sounds good. I had hoped to merely point him in the right way, and that he would put things together. I hope this is indeed the case. --

Re: Need assistance

2015-07-16 Thread Michael Torrie
On 07/16/2015 08:15 PM, craig.si...@gmail.com wrote: > I need help writing a homework program. > > I'll write it, but I can't figure out how to incorporate what I have > read in the book to work in code. Can you post the code that you are currently working with? > The assignment wants us to take

Re: Keypress Input

2015-07-16 Thread Michael Torrie
On 07/16/2015 01:10 AM, Terry Reedy wrote: > On 7/16/2015 12:30 AM, Michael Torrie wrote: >> On 07/15/2015 07:03 PM, Rick Johnson wrote: >>> >> >> I think you've missed the whole point of the OP's project. He doesn't >> want to make a GUI

Re: Keypress Input

2015-07-16 Thread Michael Torrie
On 07/16/2015 11:22 AM, Rick Johnson wrote: > On Wednesday, July 15, 2015 at 11:30:40 PM UTC-5, Michael Torrie wrote: >> On 07/15/2015 07:03 PM, Rick Johnson wrote: >>> >> >> I think you've missed the whole point of the OP's project. > > Obviously

Re: Keypress Input

2015-07-15 Thread Michael Torrie
On 07/15/2015 07:03 PM, Rick Johnson wrote: > I think you've missed the whole point of the OP's project. He doesn't want to make a GUI. He simply wants to have his program do something like blink an LED when someone presses a big red button. He just wanted a quick way to test things out since

Re: Keypress Input

2015-07-15 Thread Michael Torrie
On 07/15/2015 01:05 PM, John McKenzie wrote: > Hello, all. > > Thanks to everyone who responded to my post. > > I decided to make sure I had something that worked with what I have now > and used Curses to finish it. However, it turns out that the extra work > and problems with using GPIO pin

Re: beginners choice: wx or tk?

2015-07-14 Thread Michael Torrie
On 07/14/2015 08:06 AM, Grant Edwards wrote: > On 2015-07-14, Michael Torrie wrote: >> On 07/13/2015 08:42 AM, Grant Edwards wrote: >>> If it didn't have to run on Windows, I'd pick pygtk over wx. I've >>> never tried qt. >> >> PyQt is

Re: beginners choice: wx or tk?

2015-07-13 Thread Michael Torrie
On 07/13/2015 08:42 AM, Grant Edwards wrote: > If it didn't have to run on Windows, I'd pick pygtk over wx. I've > never tried qt. PyQt is very nice to work with. In some respects it's not as Pythonic as PyGTK. It feels a lot like transliterated C++ code, which it is. But it's a powerful toolki

Re: beginners choice: wx or tk?

2015-07-11 Thread Michael Torrie
On 07/11/2015 11:39 AM, Chris Angelico wrote: >> I'm happy with PyQt. I haven't created standalone executable files with it, >> though. Do they necessarily have to be large? I would think that >> well-written import statements would cut down on the file size. Just import >> the objects you n

Re: Readline -- cannot bind to both Ctrl-tab and tab at the same time?

2015-07-09 Thread Michael Torrie
On 07/09/2015 02:42 PM, Marko Rauhamaa wrote: > Skip Montanaro : > >> It makes perfect sense to me that TAB and Ctrl-TAB would generate the >> same keycode, as TAB is itself a control character (Ctrl-I). As the >> Ctrl modifier bit is effectively already set, I don't think you can >> really set it

Re: (side-)effects and ...

2015-07-09 Thread Michael Torrie
On 07/09/2015 08:05 PM, Chris Angelico wrote: >> I thought so at first add well. It looks like the Mailman system handles the >> X-No-Archive and/or Archive headers. I couldn't find his name in this >> month's archive. > > Even if it respects that, there's no way that Mailman can know to > respect

Re: Trying to import numpy

2015-07-06 Thread Michael Torrie
On 07/06/2015 09:17 PM, ryguy7272 wrote: > I followed the instructions here. > https://pip.pypa.io/en/latest/installing.html > > > In the c-prompt, I get this error. > C:\>python get-pip.py > python: can't open file 'get-pip.py': [Errno 2] No such file or directory Is get-pip.py located in c:\?

Re: Linear time baseconversion

2015-06-30 Thread Michael Torrie
On 06/30/2015 10:24 AM, jonas.thornv...@gmail.com wrote: > Den tisdag 30 juni 2015 kl. 18:12:46 UTC+2 skrev Michael Torrie: >> Do you have some Python code to show us? > > No i just thought you would find the digit search algorithm interesting. Yeah it is interesting, although

Re: Linear time baseconversion

2015-06-30 Thread Michael Torrie
Do you have some Python code to show us? -- https://mail.python.org/mailman/listinfo/python-list

Re: Pure Python Data Mangling or Encrypting

2015-06-27 Thread Michael Torrie
On Jun 27, 2015 11:51 AM, "Paul Rubin" wrote: > > Michael Torrie writes: > > Furthermore you cannot prove a negative, which is what proving > > security is for anything but the trivial case. Are you saying this is > > untrue? > > I've always thought

Re: Pure Python Data Mangling or Encrypting

2015-06-27 Thread Michael Torrie
On 06/26/2015 03:11 PM, Johannes Bauer wrote: > You misunderstand. This is now how it works, this is not how any of this > works. Steven does not *at all* have to prove to you your system is > breakable or show actual attacks. YOU have to prove that your system is > secure. Ahh the holy grail of

Re: HOPE: A Python just-in-time compiler for astrophysical computations

2015-06-26 Thread Michael Torrie
On 06/23/2015 10:53 AM, Laurent Pointal wrote: > Mark Lawrence wrote: > >> Another beasty I've just stumbled across which you may find interesting >> http://www.sciencedirect.com/science/article/pii/S2213133714000687 > > Why use a JIT complation when you could use some C++ generation then > com

Re: windows and file names > 256 bytes

2015-06-25 Thread Michael Torrie
On 06/25/2015 06:34 AM, Tim Golden wrote: > On 25/06/2015 13:04, Joonas Liik wrote: >> It sounds to me more like it is possible to use long file names on windows >> but it is a pain and in python, on windows it is basically impossible. > > Certainly not impossible: you could write your own wrapper

Re:

2015-06-25 Thread Michael Torrie
On 06/24/2015 09:56 AM, Knss Teja via Python-list wrote: > I WANT TO install 4.3 version ... but the MSI file is giving a DLL error .. > what should I do :/ > please use REPLY ALL .. so that I get the mail to my gmail inbox No idea what you mean about wanting to get mail to your gmail inbox... I

Re: Do I need license to release the Python version of old BASIC games?

2015-06-21 Thread Michael Torrie
On 06/21/2015 08:27 PM, Steven D'Aprano wrote: > Public domain is not a licence, and many places (including the US) do not > allow individuals to put works into the public domain. (US government works > are a special case.) Some places will not recognise a public domain > dedication, and will treat

<    4   5   6   7   8   9   10   11   12   13   >