| |
| |
| |
|
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14
Comments:
<0> which is interesting actually <1> without the parens, you're just getting an instancemethod returned <2> that's what you get for trying to learn a language when you haven't slept in the past 45 hours <0> you could even do it this way (although pointless): <0> a = outfile.close <0> a() <0> but it's useful sometimes <2> ah, yeah <3> hello together.. some python cracks here ? *g* <2> hmm <3> *g* someone whos really into python.. ;-) <1> crack seems unpythonic <2> I think the file is being closed before it's actually done processing it <3> hehe <2> File "<pyshell#11>", line 3, in -toplevel-
<2> outfile.write(line) <2> ValueError: I/O operation on closed file <2> hmm <2> do I need to add a paus or something in here? <2> outfile.write(line) <2> infile.close() <2> outfile.close() <0> is the outfile.close() indented into a loop? <1> you want to close the file only once, when you are done with it <2> the only thing I do after the closing is renaming/deleting, whichh should be alright <1> so unindent infile.close() and outfile.close() so they are not in the loop <2> how do I see if they are in a loop? :) <0> check the indent level <1> the "Stuff in the loop" depends on indentation <0> paste up the source on a pastebin perhaps <2> yeah <2> http://rafb.net/paste/results/ex7y8Q21.html <0> blimey... that code runs? <2> lol <0> i don't see any indenting for the loop <0> or the if, for that matter <2> yes, that code works.. except the closing part, it seems to close too soon :) <2> let's see, what does indenting mean? I'm not english, and I'm tired, so.. :) <4> I need a name for a Netcat frontend? <4> er, s/?/./ <0> Nev|, putting spaces at the start of the line is indenting <2> oh <2> python checks spaces huh? <0> http://rafb.net/paste/results/jA9DN361.html <0> try that ^ <0> i ***ume that's what you want <4> I need a name for a Netcat frontend. <0> i'll now fiddle it some more :) <4> that I will write. <2> damn <4> anyone? <2> I've been scripting in a language that ignores spaces/indentation for the past four years >.< <4> Nev|, what languae? <1> hmmmm.... netdog? <2> well, I've done c++ of course, but the language I've done most is torque script <2> (game script.. ) <4> mcmillen, what does "dog" mean btw? i ***ume you mean powerful <4> am i correct? <2> is there a way to get this whole chunk to run without having to paste it line-by-line into the python shell, by the way? :) <1> dog... the animal. like cat :) <1> save it to a file, type "python filename.py" <4> mcmillen, no, i mean - Netdog - <insert catchy line here> <1> netdog - chases netcat up a tree ? <4> ahhhhhhhhhhhhhhh <4> now i understand <5> i have cvs removed a file which has since been modified on the server. how do i resolve this conflict? (i want the end result to be that the file is removed) <1> "netdog - like netcat, but a schnauzer" ? <5> (apologies for the OT question but it's 1am and i want to get this done and go home from work, and #cvs is very slow) <1> just because i like the word "schnauzeR" :) <4> mcmillen, thanks for the name. do you want to join me in this project? <2> hmm, that didn't work very well <2> same thing, greatred <0> Nev|, try this: http://rafb.net/paste/results/oIrbnB75.html - although i've not fiddled with your os.remove lines, wasn't wanting to mess that up <0> ah :| <1> kbrooks: not really :( i'm already juggling about 30 things ;) <2> go ahead and fiddle with it if you like =)
<2> *tests the new code* <4> mcmillen, OK. here's my email: kyle@kbrooks.ath.cx <2> hmm <0> Nev|, http://rafb.net/paste/results/4HNhup85.html <2> :) <0> anyway, what's the problem with it? <2> ok let's see <2> the latest one <2> created the file properly, no errors <2> but no file renaming or deleting going on <0> yes i've commented those lines out for the moment, i didn't want to damage your filesystem <2> right :) <2> damage my filesystem? :O <0> by that i mean delete any files that you don't want deleted <2> ah right <2> ! <2> flawless, cool <0> aces <4> rename is technically a copy then delete <2> thanks again greatred.. and all you other people for being patient with me :) <0> no worries, happy coding :) <2> now.. on to the next step :D <4> wx or gtk? <4> wx is good and easy... <4> or is it? <2> you're not speaking to me are you? :) <0> i've tried to learn it, but i get bored learning GUI stuff <2> hehe <0> for some reason GUI programming doesn't excite me in the least <4> # Snippy: Cutting scissors around code and putting it in a box <4> like it? :) <2> now.. if I were to execute a .bat file before doing these file modifications, how can I make sure that the .bat has finished running before I move on to edit the .lua-file and rename/delete? <3> could someone take a look on this and tell me what is on the return command or the getcurrent wrong so i could pick up every of the 3 values and not only the whole string inside ? http://rafb.net/paste/results/fEuPoz57.html <0> which 3 values? <3> the last line is what i cet as return from the getcurrent command <0> and what do you really want? <3> i would need somehow to pick theses values out <0> split <0> for example: <0> a = "fp_up, (630, 320)" <2> Thanks once more. I'll try not to ask questions next time I come here, now I'm gonna sleep =) <0> a.split(",") would give you: ["fp_up", " (630", " 320)"] <0> which isn't perhaps that useful, but might be closer to what you want <4> Why is a menu so hard to xcreate in pygtk? <3> what i need wpuld be "fp_up" "630" "320" <4> because it can be placed anywhere? <6> hi, is there a seperate channel dedicated to wxPython or might i get help here? <4> flonk, #wxwidgets <3> i thought selection = self["list"].getCurrent()[4][1] would bring me the (630,320) but it brings me only "f" ;-( <6> kbrooks: thanks <3> the list is where i get the retun values from <4> NetDreamer, thats a string <4> i need a bit of help. what should netdog do? <0> NetDreamer, it depends how flexible you want this code to be <3> aargh. you are right. so easiest way would be to remove the "()" have the values and split the lines ? <4> dogs can find information <4> ... <4> erm <0> i mean, what other strings are you trying to break out of it? <4> find things <4> upon command <4> mcmillen, ^ <0> NetDreamer, or perhaps you should just store the values differently <4> but WHAT things? <0> keyDescriptions = {KEYIDS["BTN_0"]: ("fp_up, (630, 320)")} becomes: <0> keyDescriptions = {KEYIDS["BTN_0"]: ("fp_up", 630, 320)} <3> that would also be an idea. what i do is look up a Keyid and match the first, and that should me return all the values behind, (fp_up, 630, 320) <4> NetDreamer, <0> indeed, then you've got it all as a nice tuple <3> hmm. thats an idea. brb. ill check this out... <4> the first example didnt because [1] on a string <3> kbrooks. your right. i had a conversion error before. just checking that out <3> kbrooks. looks good. returns me now ('fp_up', 630, 320) <3> so i should be able now to pick them out ?
Return to
#python or Go to some related
logs:
#mysql #php gtk tray icon transparent fluxbox dovecot MYSQL: User query did not return 'uid' field #debian ubuntu tty hangs running local boot scripts
rulesdujour dutch embed php in flash #perl #kde
|
|