Try: Except: evaluates to True every time

2017-11-04 Thread brandon wallace
I have this code that tests a server to see if it is listening on port 123 runs and evaluates to True every time. Even if the server does not exist but it is not supposed to do that. I am getting no error message at all. What is going on with this code?     #!/usr/bin/env python import socket

Key Press Not Working

2017-11-02 Thread brandon wallace
  I am trying to catch a key press but it is not working. How can I fix this code? There is no error message so there is no error message to do a search on. I am using Python3.5 64-bit inside the terminal. while True: key = input("Enter a letter: ") if key == ord('q'): break    

Issues downloading python.

2017-04-07 Thread Brandon Mace
I have downloaded python onto a DELL laptop, but it will not run. I have tried to install it multiple times but each time it does not work so I try again. This time it has come up with a system error and that "The program can't start because api-ms-win-crt-runtime-[1-1-0.dlll is missing" What can I

Re: How coding in Python is bad for you

2017-01-26 Thread Brandon McCaig
your paste ended. (O_O) You learn something every day. Thank you. I have been using Vim and vi for probably close to a decade by now, but I still have a lot to learn... But nevertheless hate to go without for even a few seconds. Regards, -- Brandon McCaig Castopulence Software <https://www

Re: How coding in Python is bad for you

2017-01-26 Thread Brandon McCaig
l if my analysis is correct it shouldn't so one of us is obviously wrong. Unfortunately, in my experience, they usually expect the conversation to be over after "but it works"... Regards, -- Brandon McCaig Castopulence Software <https://www.castopulence.org/> Blog <http://www.

Re: How coding in Python is bad for you

2017-01-26 Thread Brandon McCaig
ting the entire block could be useful. Though I suppose it might be too noisy and distract from what matters? Alternatively, you'd need different levels of indentation to capture nested indentation. That shouldn't be a problem if people are limiting their indentation levels though... Regar

Re: Quick way to calculate lines of code/comments in a collection of Python scripts?

2016-10-20 Thread Brandon McCaig
trawberry Perl distribution. It comes with batteries included. If you're lucky cpanm will just work(tm) to install it from there. Hope that helps... Regards, -- Brandon McCaig Castopulence Software <https://www.castopulence.org/> Blog <http://www.bambams.ca/> perl -E '$_=q{

Re: Python Data base help

2016-10-17 Thread Brandon McCaig
nd you want to query it regularly, consider learning a bit about SQL and sqlite3 and import the data into a "real" database first. Then you'll get the full expressive power of a query language and the performance improvements of binary data and indexing (if you tune it

Re: Were is a great place to Share your finished projects?

2016-07-15 Thread Brandon McCaig
y pulling your name out of nowhere when it looks up the author of commits that are responsible for lines of code... Maybe you should report that to the mailing list and get to the bottom of it... I suspect that the explanation has nothing to do with any bugs in Git. Regards, -- Brandon McCaig

RE: Gzip module does not support Unix compressed .Z files [SEC=UNOFFICIAL]

2016-07-04 Thread Owen Brandon
That's actually the module that I wrote for this purpose (adapted Mark Adler's C code) - I haven't optimised it very much. Brandon Owen GNSS Network Operator  |  Geodesy and Seismic Monitoring Group Community Safety and Earth Monitoring Division  |  GEOSC

Gzip module does not support Unix compressed .Z files [SEC=UNOFFICIAL]

2016-07-03 Thread Owen Brandon
ctionality being included in a core module at some point? Sorry if this is not the correct forum for questions like this - any help would be appreciated. Kind Regards Brandon Owen GNSS Network Operator | Geodesy and Seismic Monitoring Group Community Safety and Earth Monitoring Div

ERROR: IDLEs subprocesses did not make a connection...

2016-01-15 Thread Lee, Brandon
Hello! I am running into the following error and need some guidance. Please see the screenshots of the error, the files I currently have in the /python directory. As well as a link to a troubleshooting post on 'stackoverflow'. Thank you! -Brandon http://stackoverflow.com/question

Try Except Specific Error Messages

2015-05-02 Thread brandon wallace
Hi,   I am try to get more specific error messages using try/except. I ran this code with the cable unplugged to see the error message. I got #!/usr/bin/env python3 import urllib.request webpage = urllib.request.urlopen("http://fakewebsite.com/";) text = webpage.read().decode("utf8") I got t

Re: Markers on a matplotlib plot

2013-10-16 Thread Brandon La Porte
On Wednesday, 16 October 2013 18:31:09 UTC-4, Mark Lawrence wrote: > On 16/10/2013 22:34, Brandon La Porte wrote: > > > I have the following code to make a plot of 4 different supply curves > > (economics). > > > > > > > > > from matplotlib imp

Markers on a matplotlib plot

2013-10-16 Thread Brandon La Porte
I have the following code to make a plot of 4 different supply curves (economics). from matplotlib import pyplot as plt price = range(0,51) q1 = [x/2.0 for x in price] q2 = [x/4.0 for x in price] q3 = [x/5.0 for x in price] q4 = [x/10.0 for x in price] markers_on = [20, 40] plt.plot(q1,price,

Re: Is Python a commercial proposition ?

2012-07-29 Thread Brandon Schaffer
Another common use is to create automated regression testing frameworks, and other automation tools. I see posting for python developers for this type of thing all the time on stack overflow careers. On Sun, Jul 29, 2012 at 11:43 AM, Mark Lawrence wrote: > On 29/07/2012 17:01, lipska the kat wrot

RE: tkFileDialogs

2012-07-06 Thread brandon harris
It doesn't matter whether I pass the actual path in or the global variable name. The result is the same. Brandon L. Harris From: Karim [kliat...@gmail.com] Sent: Friday, July 06, 2012 12:42 AM To: brandon harris Subject: Re: tkFileDialogs Le

tkFileDialogs

2012-07-05 Thread brandon harris
dows the %APPDAT% folder is hidden by default) Windows Example Code. import tkFileDialog # Won't start in or allow navigation to APPDATA test = tkFileDialog.askdirectory(initialdir='%APPDATA%') # Will start in and navigate to APPDATA test = tkFileDialog.askopenfile(initialdir=&

Re: Python Pickling Issue

2011-11-03 Thread Brandon Harris
After digging around a while I discovered I was attempting to pickle a third party class that can't be pickled. Initially I was removing it before pickling and everything was kosher, but at some point it got back onto the class. Apologies. Brandon L. Harris On 11/03/2011 09:42 AM, Br

Python Pickling Issue

2011-11-03 Thread Brandon Harris
n it can't pickle is, so if there's any possible way to at least get the name of what's failing to be pickled, that would be a win. Thanks in advance for all replies. Brandon L. Harris -- http://mail.python.org/mailman/listinfo/python-list

Re: PEP 8 and extraneous whitespace

2011-07-22 Thread Brandon Harris
Poor sod? Makes it sound bad when you say it like that. I am not forced to work at that fixed width, but when I work with code, I often have my vim session split vertically and it's super important to keep things at 80 character to quickly read/edit code. Brandon L. Harris On 07/22/20

Re: PEP 8 and extraneous whitespace

2011-07-21 Thread Brandon Harris
a new longer variable and you can never be consistent in how much whitespace is there. Brandon L. Harris On 07/21/2011 01:46 PM, Andrew Berg wrote: -BEGIN PGP SIGNED MESSAGE- Hash: RIPEMD160 On 2011.07.21 01:32 PM, Thomas Jollans wrote: So, the PEP says: do not align operators. E

Re: Python threading/multiprocessing issue.

2011-07-15 Thread Brandon Harris
f use? Brandon L. Harris On 07/15/2011 03:55 PM, Lee Harr wrote: I'm working on a tool that runs a number of process is separate thread. I've, up to this point, been using threading.Thread, but from what I read multiprocess will allow multiple processors to be used From the python docs on

Python threading/multiprocessing issue.

2011-07-15 Thread Brandon Harris
The odd thing is that I can modify the multiprocessing.Event and it holds, but modifying any attribute on the class goes away. If I am super ignorant of something, please cure me of it. Thanks in advance! Brandon L. Harris -- http://mail.python.org/mailman/listinfo/python-list

Python threading/multiprocessing issue.

2011-07-14 Thread Brandon Harris
The odd thing is that I can modify the multiprocessing.Event and it holds, but modifying any attribute on the class goes away. If I am super ignorant of something, please cure me of it. Thanks in advance! Brandon L. Harris -- http://mail.python.org/mailman/listinfo/python-list

Reading Huge UnixMailbox Files

2011-04-26 Thread Brandon McGinty
them using the re.split function with a compiled regexp, and imports each chunk as a message. The regular expression work is where the bottle-neck appears to be, based on timings. I'm wondering if there is a faster way to do this, or some other method that you all would recommend. Brandon McGint

Re: new to python, trying to choose a book.

2011-03-06 Thread Brandon LaRocque
I'd suggest Zed Shaw's amazing Learn Python The Hard Way [1] (which isn't as hard as it sounds) - and it's free over the web (but, I believe - you can buy a copy). I dislike Pilgrim's Dive Into Python, but that's just me (though I thoroughly recommend Dive Into HTML5 to anyone interested in HTML5)

Re: Passing File Objects into Subprocess.Popen

2010-11-04 Thread Brandon Harris
ok. Jumping back to the start of the file solved the problem. (file.seek(0)) Big thanks for that insight! Brandon L. Harris On 11/04/2010 05:49 PM, Brandon Harris wrote: What do you mean by rewind the file pointer before reading from it? Seek back to the beginning? And It sounded very

Re: Passing File Objects into Subprocess.Popen

2010-11-04 Thread Brandon Harris
l. I did try running communicate before and after the wait() but to no avail. Brandon L. Harris On 11/04/2010 05:39 PM, Antoine Pitrou wrote: Try to rewind the file pointer before reading from it. -- http://mail.python.org/mailman/listinfo/python-list

Passing File Objects into Subprocess.Popen

2010-11-04 Thread Brandon Harris
oraryFile() my_stdout = tempfile.TemporaryFile() process = subprocess.Popen(my_cmd, stderr=my_stderr, stdout=my_stdout) process.wait() print my_stderr.read() print my_stdout.read() print "Finished!!!" Any help on this issue would be awesome! thanks! Brandon L.

eval string

2010-09-30 Thread Brandon Harris
import sys; sys.stderr.write("\n\n\nCompleted!!!\nCompleted!!!\nCompleted!!!\nCompleted!!!\nCompleted!!!\nCompleted!!!\n\n\n");') Traceback (most recent call last): File "", line 1, in File "", line 1 import sys; sys.stderr.write(" ^ SyntaxError: invalid syntax Brandon L. Harris -- http://mail.python.org/mailman/listinfo/python-list

Using re.sub with %s

2010-08-18 Thread Brandon Harris
27;%'gosh', test) return is /my/gosh/whats/wrong Any help would be good. I've tried passing the value as an int, or recasting that value as something else, passing it as a raw string, removing the r and just double escaping the groups. Brandon L. Harris -- http://mail.python.org/mailman/listinfo/python-list

Re: new to python - trouble calling a function from another function

2010-08-05 Thread Brandon McCombs
Ulrich Eckhardt wrote: Brandon McCombs wrote: I'm building an elevator simulator for a class assignment. I recently ran into a roadblock and don't know how to fix it. For some reason, in my checkQueue function below, the call to self.goUp() is never executed. [...] sorry about the

Re: new to python - trouble calling a function from another function

2010-08-05 Thread Brandon McCombs
Jon Clements wrote: On 5 Aug, 08:25, Brandon McCombs wrote: Hello, I'm building an elevator simulator for a class assignment. I recently ran into a roadblock and don't know how to fix it. For some reason, in my checkQueue function below, the call to self.goUp() is never executed. It

new to python - trouble calling a function from another function

2010-08-05 Thread Brandon McCombs
Hello, I'm building an elevator simulator for a class assignment. I recently ran into a roadblock and don't know how to fix it. For some reason, in my checkQueue function below, the call to self.goUp() is never executed. It is on the last line of code I pasted in. I can put print statements b

Re: Multiline regex

2010-07-21 Thread Brandon Harris
Could it be that there isn't just that type of data in the file? there are many different types, that is just one that I'm trying to grab. Brandon L. Harris Andreas Tawn wrote: I could make it that simple, but that is also incredibly slow and on a file with several million lines

Re: RE: Multiline regex

2010-07-21 Thread Brandon Harris
I could make it that simple, but that is also incredibly slow and on a file with several million lines, it takes somewhere in the league of half an hour to grab all the data. I need this to grab data from many many file and return the data quickly. Brandon L. Harris Andreas Tawn wrote: I&#

Re: Multiline regex

2010-07-21 Thread Brandon Harris
At the moment I'm trying to stick with built in python modules to create tools for a much larger pipeline on multiple OSes. Brandon L. Harris Eknath Venkataramani wrote: On Wed, Jul 21, 2010 at 8:12 PM, Brandon Harris mailto:brandon.har...@reelfx.com>> wrote: I'm t

Re: Multiline regex

2010-07-21 Thread Brandon Harris
what do you mean by slurp the entire file? I'm trying to use regular expressions because line by line parsing will be too slow. And example file would have somewhere in the realm of 6 million lines of code. Brandon L. Harris Rodrick Brown wrote: Slurp the entire file into a string and

Multiline regex

2010-07-21 Thread Brandon Harris
;.kot[0]" 5; would be what my regex would grab. I'm currently only able to grab out the first line and part of the second line, but no more. regex is as follows my_regexp = re.compile("createNode\ animCurve.*\n[\t*setAttr.*\n]*") I've run several variations of this, but

Re: Writing to open subprocess pipes.

2010-06-16 Thread Brandon McGinty
Ah. Thank you all for your quick responses. I shall implement non-blocking stdin/stdout objects, then. Thank You, Brandon McGinty On 6/16/2010 5:37 PM, Thomas Jollans wrote: On 06/16/2010 10:29 PM, Brandon McGinty wrote: All, I have researched this both in the python documentation, and via

Writing to open subprocess pipes.

2010-06-16 Thread Brandon McGinty
if not, I shall do my best to elaborate further. I appreciate all the help this group has given me in the past, and I certainly appreciate any help you all can offer now. Sincerely, Brandon McGinty -- http://mail.python.org/mailman/listinfo/python-list

script to upload file using POST form

2010-03-19 Thread Brandon C
got another question for yall wonderful minds; how can i upload a file to a server that uses a POST form? here's the link to the form that i'd like to be able to upload a file: http://imagebin.org/index.php?page=add tks -- http://mail.python.org/mailman/listinfo/python-list

Re: Truoble With A Search Script for ImageBin.org

2010-03-19 Thread Brandon C
*grumble* *grumble* *grumble* oops, sorry ... my mistake it turns out that i misspelled one of the values and left another one out. here's the working script now for anyone who may care: import urllib import urllib2 url = 'http://imagebin.org/index.php?page=search' values = {'search_for' : 'bla

Truoble With A Search Script for ImageBin.org

2010-03-18 Thread Brandon Conner
Hey Pythoners, its my first post here, yay! I'm trying to develop a script that will return the results of a POST request that should list all images uploaded by a user. However, when i run the script, i get returned the HTML of the page with the search form. I am wondering what am i doing inco

Re: Question about getmtime

2010-02-19 Thread Brandon
On Feb 19, 10:26 am, Krister Svanlund wrote: > On Fri, Feb 19, 2010 at 5:05 PM, Brandon wrote: > > Hi everyone, > > > Does copying or moving a file affect the return value of > > os.path.getmtime(path)? > > > Thank you, > > Brandon > > Wouldn't

Question about getmtime

2010-02-19 Thread Brandon
Hi everyone, Does copying or moving a file affect the return value of os.path.getmtime(path)? Thank you, Brandon -- http://mail.python.org/mailman/listinfo/python-list

Re: dictionary with tuple keys

2009-12-15 Thread Brandon Devine
So grateful! Thanks to all. The breadth of Python continues to amaze me, as does your generosity. ("Relative clarity like relative beauty is in the eye of the beholder, and few parents have ugly children"... fantastic!) Brandon -- http://mail.python.org/mailman/listinfo/python-list

dictionary with tuple keys

2009-12-14 Thread Brandon Devine
values once I've collected these keys. I am staring at my screen, pondering ugly things, and I just know I must be missing a Pythonic solution. Any suggestions? Thanks for any help, Brandon -- http://mail.python.org/mailman/listinfo/python-list

Re: Problem embedding Python.

2009-10-29 Thread Brandon Keown
O...K... -- http://mail.python.org/mailman/listinfo/python-list

Re: Problem embedding Python.

2009-10-29 Thread Brandon Keown
On Oct 27, 7:48 pm, "Gabriel Genellina" wrote: > En Tue, 27 Oct 2009 06:36:18 -0300, Brandon Keown > escribió: > > > On Oct 27, 2:47 am, "Gabriel Genellina" > > wrote: > > >> You didn't test for the fopen result; are you sure "test

Re: Problem embedding Python.

2009-10-27 Thread Brandon Keown
I found the problem. Evidently as posted on a few other areas of the internet, this is a common problem when trying to use compilers that may have different type definitions for (FILE*). Here is workable solution: #include int main(int argc, char* argv[]) { PyObject* PyFileObject;

Re: Problem embedding Python.

2009-10-27 Thread Brandon Keown
On Oct 27, 2:47 am, "Gabriel Genellina" wrote: > > Crashes, how? Try running inside a debugger to see where it crashes, or at   > least put a few printf. > You didn't test for the fopen result; are you sure "test.py" exists in the   > current directory at the time you run it? > > -- > Gabriel Gene

Problem embedding Python.

2009-10-26 Thread Brandon Keown
I am going to try to embed python in an application, but in simple testing, I could not get it to work. The following code seems like it should work, but it crashes, and I have tried several things. What could I be doing wrong? #include int main(int argc, char* argv[]) { FILE* fp = fop

base64 Incorrect Padding

2009-07-31 Thread Brandon Fredericks
I did a search within this group, but couldn't find any information on this. I am sending base64 encoded data as the content over http using urllib2 urlopen. When I receive the data and attempt to decode it, I get an "Incorrect Padding" error. Is there a simple way to fix this? A better way to sen

python docs redirect on python.org is old

2009-04-04 Thread Brandon Craig Rhodes
When I visit ... http://www.python.org/doc/lib/lib.html ... I get redirected to ... http://www.python.org/doc/2.5.2/lib/lib.html ... which seems a bit old. -- Brandon Craig Rhodes bran...@rhodesmill.org http://rhodesmill.org/brandon -- http://mail.python.org/mailman/listinfo

Problem with environment variables and cx_Oracle

2009-02-24 Thread Brandon Taylor
e environment handle I've been wrestling with this for quite some time. My Oracle person assures me that my user has appropriate permissions for the schema. My Oracle experience is pretty limited, but this seems like it's an issue with the environment on my Mac. Does anyone have any ide

Re: cx_Oracle-5.0 Problem

2009-02-12 Thread Brandon Taylor
On Feb 12, 9:31 am, redbaron wrote: > > ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.6/ > > lib/python2.6/site-packages/cx_Oracle.so, 2): Symbol not found: > > ___divdi3 > > You didn't link cx_Oracle.so all libs which it use. run "ldd -r > cx_Oracle.so" and you'll have an id

cx_Oracle-5.0 Problem

2009-02-12 Thread Brandon Taylor
Hello everyone, I'm Brandon Taylor, senior web developer with the University of Texas at Austin. We're using Python 2.6.1 and having a lot of difficulty getting the cx_Oracle-5.0 library to install on one of our MacBooks running OS X 10.5.6. We can get cx_Oracle to compile, but aft

Re: Extracting file from zip archive in Python 2.6.1

2009-02-05 Thread Brandon Taylor
On Feb 4, 12:16 am, "Gabriel Genellina" wrote: > En Wed, 04 Feb 2009 00:36:40 -0200, Brandon Taylor   > escribió: > > > > > On Feb 3, 1:16 pm, Brandon Taylor wrote: > >> On Feb 3, 9:45 am, "Gabriel Genellina" wrote: > >> > En Tue,

Re: Extracting file from zip archive in Python 2.6.1

2009-02-03 Thread Brandon Taylor
On Feb 3, 9:15 pm, rdmur...@bitdance.com wrote: > Quoth Brandon Taylor : > > > > > Ok, the first thing I needed to do was add: > > > from __future__ import with_statement at the beginning of my file > > > but: > > > with zip_file.ope

Re: Extracting file from zip archive in Python 2.6.1

2009-02-03 Thread Brandon Taylor
On Feb 3, 1:16 pm, Brandon Taylor wrote: > On Feb 3, 9:45 am, "Gabriel Genellina" wrote: > > > > > En Tue, 03 Feb 2009 05:31:24 -0200, Brandon Taylor   > > escribió: > > > > I'm having an issue specifying the path for extracting fi

Re: Extracting file from zip archive in Python 2.6.1

2009-02-03 Thread Brandon Taylor
On Feb 3, 9:45 am, "Gabriel Genellina" wrote: > En Tue, 03 Feb 2009 05:31:24 -0200, Brandon Taylor   > escribió: > > > I'm having an issue specifying the path for extracting files from > > a .zip archive. In my method, I have: > > > zip_

Extracting file from zip archive in Python 2.6.1

2009-02-02 Thread Brandon Taylor
name' and extracting the files to it. Example: if 'thumbnail_path' is 'images/inventory/thumbnails/' extract is creating: 'images/inventory/thumbnails/test1/' and saving the files out. How can I set the path to be exactly: 'images/inventory/thumbnails&

Re: dictionary idiom needed

2008-12-11 Thread Brandon
> >>> d = defaultdict(lambda: defaultdict(int)) > > Arnaud Ah... so that's what lambdas are for. Many thanks! Brandon -- http://mail.python.org/mailman/listinfo/python-list

Re: dictionary idiom needed

2008-12-11 Thread Brandon
> Smells like homework without a particular application. @Scott: Even if that were the case :) I'd still like to figure out how to create nested dictionaries! Brandon -- http://mail.python.org/mailman/listinfo/python-list

Re: dictionary idiom needed

2008-12-11 Thread Brandon
es back from my initial attempts to build a nested dictionary. I am stumbling at constructing a "for" loop that automatically creates such nested dictionaries. I hope that clears things up. If you still have any advice, it's much appreciated. Thanks, Brandon -- http://mail.python.org/mailman/listinfo/python-list

dictionary idiom needed

2008-12-11 Thread Brandon
do this with lists? All of the nested for loops I have tried return replicated results, so I can't trust those values. Thanks for any pointers, Brandon -- http://mail.python.org/mailman/listinfo/python-list

Re: File copying from a menu

2008-08-26 Thread Brandon
Turns out I was missing a few lines of code here-and-there, but now it's visible and working. Thanks to anyone who was looking into this for me. "Fredrik Lundh" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Brandon wrote: > >> I'm attemp

Re: File copying from a menu

2008-08-26 Thread Brandon
self.tr("E&xit"), self) self.exitAct.setShortcut(self.tr("Ctrl+Q")) self.exitAct.setStatusTip(self.tr("Exit the application")) self.connect(self.exitAct, QtCore.SIGNAL("triggered()"), self, QtCore.SLOT("close()")) "Fredrik Lundh" <[

File copying from a menu

2008-08-25 Thread Brandon
I'm attempting to have a file copied from a menu selection. The menu already exists, but it won't even create the menu item. If anyone has any ideas, please let me know. -- http://mail.python.org/mailman/listinfo/python-list

Re: updating dictionaries from/to dictionaries

2008-08-14 Thread Brandon
> (1) iterating over foo: > for key in foo: >foo[key] += bar.get(key, 0) > > (2) iterating over bar: > for key in bar: >foo[key] += bar[key] > > I (again) challenge you to say *why* you feel that the "iterating over > bar" solution will not work. Well if you're going to be clever enough

Re: updating dictionaries from/to dictionaries

2008-08-12 Thread Brandon
On Aug 12, 7:26 am, John Machin <[EMAIL PROTECTED]> wrote: > On Aug 12, 12:26 pm, Brandon <[EMAIL PROTECTED]> wrote: > > > > > You are very correct about the Laplace adjustment. However, a more > > precise statement of my overall problem would involve tra

Re: updating dictionaries from/to dictionaries

2008-08-11 Thread Brandon
on of the power of lists, nested lists, and dictionaries (with glorious examples) - something that might appeal to a lot of non-full time programmers who need to script a lot but want to be efficient about it, yet don't want to deal with a tutorial that unnecessarily covers all the aspects of Python. My $0.027 (having gone up due to the commodities markets). Thanks again for the input, I do appreciate it! Brandon -- http://mail.python.org/mailman/listinfo/python-list

Re: updating dictionaries from/to dictionaries

2008-08-11 Thread Brandon
I wasn't sure about the update method either, since AFAICT (not far) the values would in fact update, not append as I needed them to. But the iteritems and get combo definitely worked for me. Thank you for the suggested link. I'm familiar with that page, but my skill level isn't so far along yet

Re: updating dictionaries from/to dictionaries

2008-08-11 Thread Brandon
"Harder to say what you want to do than to just do it." The truly terrible thing is when you know that's the case even as you're saying it. Thanks for the help, all! -- http://mail.python.org/mailman/listinfo/python-list

updating dictionaries from/to dictionaries

2008-08-11 Thread Brandon
't see a way yet to match the tuple key as x[0][0] in one list for all y in the other list. There's just got to be a better way! Thanks for any help, Brandon (trying hard to be Pythonic but isn't there yet) -- http://mail.python.org/mailman/listinfo/python-list

Inserting into a combo box

2008-08-03 Thread Brandon
I'm attempting to insert items into a combo box, but when it goes to run it, throws up the error: TypeError: argument 1 of QComboBox.insertItem() has an invalid type and here is what I'm trying to do: self.editUsername.insertItem(uname) editUsername is the combo box, and uname is a string I'm a

Required items in a form

2008-07-01 Thread Brandon
What I'm trying to do is essentially force a user to fill in required items in a form, which will be saved to a database. How can I get it so that once the user clicks "OK" on the dialog box, it transfers control back to the form, and not save the empty fields into the database? -- http://ma

Re: Convert string to char array

2008-07-01 Thread Brandon
Thank you both for your help. "Mike Kent" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] On Jul 1, 2:49 pm, "Brandon" <[EMAIL PROTECTED]> wrote: > How do I convert a string to a char array? I am doing this so I can edit > the string rece

Convert string to char array

2008-07-01 Thread Brandon
How do I convert a string to a char array? I am doing this so I can edit the string received from an sql query so I can remove unnecessary characters. -- http://mail.python.org/mailman/listinfo/python-list

adding values to keys

2008-02-15 Thread Brandon
0,1,2,3]) ('y', [0,1,2,3]) ('z', [0,1,2,3]) And now I want a master dictionary like: [{'w': [0],[1],[2],[3]}, {'x': [0]...] So I try: MT = {} MT.fromkeys(NT[0], range(alpha,omega)) print MT but this only returns: {} {} {}... Anybody see what I'

Re: Unknown cause to error (new to python)

2008-01-16 Thread Brandon Perry
Sorry, this is all I can get. :-( This isn't my webserver, so the only error logs I get are what they give me. I guess I will just have to keep working at it. Thanks for looking at it though, Brandon On Wed, 2008-01-16 at 15:12 +0100, Bruno Desthuilliers wrote: > Brandon Perry a écrit

Unknown cause to error (new to python)

2008-01-16 Thread Brandon Perry
minds/public_html/torrents/TF_BitTornado/BitTornado/download_bt1.py", line 4, in ? File "/home/vminds/public_html/torrents/TF_BitTornado/btphptornado.py", line 15, in ? I am using 2.2 for compatibility purposes. Thanks, Brandon -- http://mail.python.org/mailman/listinfo/python-list

Re: Compile with GLib-1.2 instead of 2.4

2008-01-15 Thread Brandon Perry
Sorry, I know what arg to use with ./configure. With --with-libc=STRING, do I put the version I want, or the path to my GLib 1.2 files? On Tue, 2008-01-15 at 14:53 -0600, Brandon Perry wrote: > Hi, I am having to compile a standalone python because the webserver I > use doesn't allo

Compile with GLib-1.2 instead of 2.4

2008-01-15 Thread Brandon Perry
ad of/and GLib2.4? Thanks, Brandon -- http://mail.python.org/mailman/listinfo/python-list

Re: Python beginner!

2007-11-18 Thread Brandon Sandrowicz
On 11/16/07, Shawn Milochik <[EMAIL PROTECTED]> wrote: > I completely support Wildemar. Lazy questions like that deserve absolutely > nothing. > > I agree that cushioning the reply with a brief explanation of why that > question sucks would have helped the original poster, but he doesn't deserve >

Algebraic Modules For Python

2007-10-01 Thread Brandon McGinty
icies, graphing or listing points for function, etc? If not, I may be developing some; I am a blind highschool student and as of now there are no accessible graphing calculators for me to use in my algebra 2 class. Thanks for your help. Thanks, Brandon McGinty -- Brandon McGinty McGinty Sof

Re: How to Start

2007-09-13 Thread Brandon Barry
;Idiomatic Python" tutorial. http://python.net/~goodger/projects/pycon/2007/idiomatic/handout.html I've benefited greatly from HOWTOs available at A.M. Kuchling's website. http://www.amk.ca/python/howto/ Be sure to consider the optparse and cmd modules if you decide to develop the simple shell you've described. I hope this helps, Brandon -- http://mail.python.org/mailman/listinfo/python-list

Python Info.

2007-06-25 Thread Brandon
Check it out: www.BrandonsMansion.com -- http://mail.python.org/mailman/listinfo/python-list

Parsing Rdf (Rewrite)

2007-05-30 Thread Brandon McGinty
m I doing wrong, or am I even in the realm of possibility, trying to get thee elements by name? Thanks, Brandon -- Brandon McGinty McGinty Soft Ltd. Website design, configuration, and maintenance Python and PHP coder Email:[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> MSN:[EMAIL PROTECTED]

RDFXML Parser For "qualified Dublin Core" Database File

2007-05-29 Thread Brandon McGinty
alf an hour to load with 2 gb of ram. So you all know what I'm talking about, the file is located at: http://www.gutenberg.org/feeds/catalog.rdf.bz2 Does anyone have suggestions for a parser or converter, so I'd be able to view this file, and extract data? Any help is appreciated.

Re: retarded twits posting horseshit in technical groups

2007-04-17 Thread Brandon D Cartwright
On Tue, 17 Apr 2007 15:43:02 -0700, MassiveProng <[EMAIL PROTECTED]> wrote: >On 17 Apr 2007 06:56:05 -0700, [EMAIL PROTECTED] Gave us: > >>We know that... > > You're a fucking retard. But you are a text book example of a retard shoveling horseshit to technical groups.This is why you are universa

Re: paths in modules

2007-02-22 Thread Brandon Mintern
On Thu, 22 Feb 2007 10:30:59 -0600, Larry Bates wrote: > Normally this would be: > > f = os.popen('./wrapper_dir/utility_dir/some_external_utility') > > -Larry Yes, but the problem with that solution is, let's say that I further abstract the whole thing and I add a directory outside of my toplev

Re: paths in modules (solved)

2007-02-22 Thread Brandon Mintern
On Thu, 22 Feb 2007 08:28:50 -0800, Paul Boddie wrote: > And you really want to refer to utility_dir relative to some_wrapper. > What you can try is to split the __file__ attribute of some_wrapper - > it's a standard attribute on imported modules - in order to refer to > the module's parent directo

Re: paths in modules

2007-02-22 Thread Brandon Mintern
On Thu, 22 Feb 2007 11:13:46 -0500, Brandon Mintern wrote: > Of course, the problem with that approach is that it fails because there > is no utility_dir in the CWD... ...and of course by CWD, I actually mean "current working directory", which should have actually been PWD or

paths in modules

2007-02-22 Thread Brandon Mintern
g that there is some simple solution to this problem that I simply haven't found in my searches so far. If so, I will humbly accept any ridicule that comes along with said simple solution :-). Thanks in advance, Brandon -- http://mail.python.org/mailman/listinfo/python-list

PythonCard Auto Placement

2006-12-21 Thread Brandon McGinty
p, and the controls for moving don't show up as usable controls in my screen reader. Any help is appreciated. Thanks Much, Brandon McGinty -- http://mail.python.org/mailman/listinfo/python-list

Awesome Python Information

2006-11-05 Thread Brandon
Check out: www.ChezBrandon.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Exposing Excel as a Webservice

2006-09-15 Thread Brandon
call into the system guarantees that it will leave everything how it found it. That's sort of why I thought up option 3). Let the OS help me somewhat to clean up. I strongly suspect that my option 2) is to some extent at the mercy of the python garbage collector. I'm not po

  1   2   >