« first day (1983 days earlier)      last day (2964 days later) » 

7:00 PM
Yeah, A new way to rickroll. :D
 
I also wanted to say "and annotations are something different entirely" But I didn't want the well-actually brigade to come in and say "function annotations have a specific meaning in Python but just 'annotations' on its own could be interpreted to mean anything that adds information without changing program behavior"
 
Tkinter seems awfully confusing
 
@vaultah I once had a co-worker who wrote comments so damn cryptic that I usually had to read the source code to understand his comments
 
I have a powerful hatelove for Tkinter.
 
The problem with Tkinter is that, AFAIK, there isn't a really good "getting started with Tkinter" book/guide out there. Much of the information is fragmented, and some of it is quite decent, but nothing is, AFAIK, really "complete" in the sense that it explains the concepts, caveats, best practices, API, etc.
 
7:05 PM
Docs.SO to the rescue! /s
 
Aw man, I left my "tkinter_grievances.txt" on my now-formatted work computer.
 
I just want a simple progress bar for the user, but it seems to be a lot more complicated than I realized
 
@Carpetsmoker There was. Unfortunately it was carved in stone when tkinter was first written, and has been lost over the eons.
 
I had a great example of a Tkinter feature that is completely undocumented by any source online. It had something to do with per-keystroke entry validation...
 
@Kevin But this is probably documented in the Tk API docs?
 
7:07 PM
@Programmer You might have an easier time just doing it on the command line. See sopython.com/canon/78/…
 
DSM
@Kevin: I'm bringing my portable HD in from home precisely so that doesn't happen to me. :-)
 
@Carpetsmoker I have never been able to successfully extract useful information from those.
 
@Kevin I wish I could do it that way.
 
More like Application Psychic Interface, am I right?
 
Drawing a progress bar isn't super hard in Tkinter. Just create a canvas and draw a rectangle on it that changes width as time goes by. The hard part is getting it to run in parallel with the rest of your program, because the root mainloop method will block forever as long as the user doesn't X out of the window.
 
7:11 PM
Well there's a handy progress bar widget, but it doesn't like to be positioned.
 
You can use threads or .after() to schedule stuff in the event loop − it's usually not that difficult (not more so than other applications...)
 
Threading is probably the way to go if you already have a complete program and just want to staple a progress bar to it.
If you want to use .after(), you have to refactor your work-doing program entirely so it performs work in little 10 ms increments and yields control back to the mainloop
Although that's not enormously hard if it's already in one big function. Then you can just sprinkle in yield statements and now it's magically a coroutine
 
Hmm, I hadn't given it much thought yet. I assumed I could use step and probably end up with something ugly.
 
user559633
 
7:35 PM
This is basically how I'd do it.
 
Kevin do you play the Sims?
 
Back in the day, yeah
 
The "reticulating spines" seems like their loading screen messages :p
 
Yeah I lifted that line from Sim City 2000.
 
Rhubarb, Time to sleep
 
7:46 PM
cbg
headache because of baaad questions
 
Thanks for the pastebin though, I think this will help a ton.
 
does this answer I just posted seem harsh?
 
by the way, I asked how to get the median of an unordered iterator, a few days ago. Thanks to links everyone shared, I came up with this
 
@TadhgMcDonald-Jensen not in my reading.
 
import itertools

def median(S, n, k): # S is the sequence (list-iterator); n is the size of the list; k says "find the k-th smallest item in the sequence"
    L,G = itertools.tee(S)  #clones the iterator
    p = next(G)
    numSmaller = sum(1 for i in G if i<p)
    if numSmaller == k-1: return p
    if numSmaller < k-1: return median((i for i in L if i>p), n-numSmaller, k-1-numSmaller)
    return median((i for i in L if i<p), numSmaller, k)
 
7:48 PM
I know that while I was writing it I was yelling in my head Why are you throwing away your tracebacks? but I can't tell if it went through.
 
If the reader is actively trying to find something to feel hurt about, they can find the tone accusative. But that's also true of a whole lot of perfectly ordinary answers on SO.
 
asdfkjlkdsafjlkdsafjaslkfdjsalkfdjsadlkfxzvcöxzcvösaigf'wq9
ETERNAL SEPTEMBER :D
 
kevin: yeah that is true, ok I think I'm fine.
 
@AnttiHaapala wake me up when [eternal] september ends
 
@inspectorG4dget okie :d
 
7:53 PM
:P
 
So, when the last star finally winks out. Got it.
 
I wanted to get 200 rep today
I've been stuck at 150 for 4 hours
 
I'll be so well rested after such a sleep
 
occasionally checking if there are any good questions.
 
there's still time
 
7:54 PM
no. there is not a single good question, answered or not.
 
At the end of all things it'll just be me, you, and the Wandering Jew. Hopefully he doesn't have any programming questions.
 
@Kevin he'd have a unicode error while printing 'א'
 
DSM
> Tyr Anasazi: I have faith in nothing but this: when the universe collapses and dies, there will be three survivors: Tyr Anasazi, the cockroaches, and Dylan Hunt, trying to save the cockroaches.
 
cabbage
 
8:32 PM
potato?
 
8:44 PM
Banana, melon! Potato?
 
Peas. Yam peas.But otherwise banana. But life goes on
 
:(
 
9:09 PM
so guys, Apple just recabbaged iphone 4
they did it again. They revolutionized the world.
 
the question remains: will it blend?
 
9:46 PM
@davidism this (very good) review of the original Transformers film makes that point
 
just to be clear: are they saying that the film is useless eyecandy, and people should watch better?
heh, started reading it, the answer seems to be "yes":D
wow that's a lot of letters
 
He basically 100% agreed with my take on that film, and writes really well, so I've always remembered that review
 
10:04 PM
cbg
 
cbg :D
 
cbg
 
Is there an easy way to parse a cookie in Python? I'm getting the cookie through a browser console command (javascript): document.cookie and I want to parse it in a dictionary
 
I don't want to create a cookie. Think of the cookie as just a raw string. I just want to decode that string into either some kind of object or a dictionary
 
10:14 PM
You have a custom format that you're storing in a cookie, and you want to know how to parse that custom format?
 
@RobertGrant that's correct. I think I figured it out. I can use urllib.parse.unquote
(I'm using py3.4)
 
10:54 PM
@RobertGrant I skimmed it because I can't read that giant wall of bold text, but it seems to have the same idea.
I've been noticing it with people defending books too.
They equate their emotional or "wow" response with a thing being actually good, versus just cool.
Nothing wrong with cool, but it shouldn't be getting 9.5/10 from movie critics.
 
unless the movie's category is Michael Bay movie
if you expect the expected, it could make sense
but the movie critics industry doesn't seem to work that way:D
10/10 Bay movie, 3/10 overall
oh @davidism completely unrelated: I've talked to Drew in SOCVR. He told me you discussed it a while back that he drop topical batches of partially closed questions here
would it be OK for me to do that if he gathers a batch in the near future?
 
Yeah, we can try it out since there's that whole "more cv-queue votes" thing going on right now.
 
awesome:) thanks
 
I'm not inclined to do it very often though, I don't want that to be the focus of this room.
 
I don't think Drew is inclined to do it often either, he's mostly invested in java and mysql and stuff
but thanks, understood
 
11:27 PM
friendly reminder for those with older kindles to update.
 
DSM
"phablet"? Tell me that's not a word now.
 
it's been for a while:S
I've even seen a girl on the subway yesterday (in Hungary!) with a big-ass tablet held to her ear and answering a call
also:
 
DSM
Get off my lawn, kids. Get off my damned lawn.
 
hey, at least geek chic is there as well ¯\_(ツ)_/¯
 

« first day (1983 days earlier)      last day (2964 days later) »