« first day (1446 days earlier)      last day (3508 days later) » 

2:01 PM
yes. I have write permissions
 
hello
 
Welcome
 
i was wondering, if someone wanted to post something like a wiki post
would it be ok to just "ask a question" with the content ?
like... for review or something similar ?
or how would the idea of a wiki blend with stackoverflow
i guess that's my question
 
SO does have a "post as community wiki" option, but you would still need to couch the post in question/answer form.
 
i know some posts usually turn into "community wiki" if there are many edits
@Kevin ah i see
 
2:04 PM
And the post still needs to follow the usual standards for questions, even if you intend it to be for reference use or whatever.
So for example "what are some good tutorials for Python?", while possibly very informative, still doesn't make a good objective question, so you'd probably get closed no matter how beautiful your provided answer is
 
I logged out of ipython and then logged back in. Now it is working. Thanks
 
Some enterprising users here are trying to get SOPython to be kind of a companion site to Stack Overflow proper. It has a wiki.
 
Is there any way to automatically log all commands and output. The way notebook does but at command prompt.
 
@Kevin this gets more difficult when you get into pythonicness (or whatever - pythonicity?), which could also be judged the same way
 
2:07 PM
i see, thanks
 
I'm thinking of developing a caffeine habit.
 
It's good. Caffeine is your friend.
 
Long-term dependency and financial expense are acceptable costs, provided I experience an improvement in energy levels, even accounting for eventual tolerance.
 
Oh I reached 200 answers, nice.
 
Obviously I don't want to do it if I experience an improvement for a month and return to my current baseline.
 
2:16 PM
I get pretty much no noticable energy boost from coffee. I just like the taste.
 
@Ffisegydd I do like coffee... but it has to be a decent coffee
those 39p value jars from tesco for instance... arhghghghghghgg... that's if you have nothing else left
 
I don't like the taste, but I do like having a beverage I can pour a cup of sugar into without being judged much
 
Can't do that with water. Double standards, amirite.
 
@Kevin I know someone who just drinks hot water
 
2:19 PM
Now, just to reiterate, while the caffeine content of BBotE is high, I do not know exactly how high. I strongly recommend keeping consumption below 100ml/day.
 
@Ffisegydd That background is horrible
 
No it's not, it's glorious.
 
The visible tiling
it cuts my eyes
 
Well don't rub your eyes against it then.
 
But how else should one use a touch-screen?
 
2:22 PM
Well I have my butler operate mine for me, sure it cuts his fingers but who cares?
 
What are people opinions on this?
-4
Q: What programming language is apple.com written in?

paulpaul1076What programming language is apple.com written in? I know that microsoft.com is written in C#, because it's a Microsoft technology,however i don't see Apple having any web technologies, all of the programming languages they use are native.

Close?
With what reason?
 
Any reason.
 
    is there a better way to do this:

    try:
        case1
        try:
            case2
            long piece of code
        except exception:
            case3
            long piece of code
    except exception

coz my pc got stuck in this nested statement,i guess..
 
Closed as off-topic
 
There's a meta post were Shog or Robert Harvey discuss how sometimes the close reason doesn't need to be dead on.
 
2:25 PM
@Veedrac I quite like it :)
Let someone answer, because it's interesting, then close it as off-topic :)
 
Did you see the answer? It was awful
worse than the question
 
Yeah I DVd the answer.
 
Oh, no I just saw the excerpt.
Oh, wow okay.
 
I prefer the abuse of max, but oh well... quite fun writing an adhoc class
 
Also flagged
 
2:27 PM
@Swordy Not really, no
 
it takes too much of time and my system hanged..had to restart
:(
 
I blame it on long piece of code
 
@Swordy your PC hanging has nothing to do with your try except probably.
 
You should rewrite that to be short piece of code
 
@Veedrac just upvoted your self-answer, but then retracted it...
remind me to vote tomorrow when it's not capped off
 
2:30 PM
Thanks, shall do
 
@Swordy The only time Python hangs for me is when I allocate a list with a hundred million elements. Maybe that's what your code is doing.
I suggest not doing that.
 
no , my lists are small
 
Do you have many though? Are you doing crazy maths with them?
Do you have any while loops that might be broken (i.e. they don't manage to stop)?
 
>>> time python -c "[0] * 100000000"
python -c "[0] * 100000000"  0.33s user 0.05s system 99% cpu 0.379 total
Hardly "hangs"
 
Maybe the list starts small but grows large. Maybe you're doing seq = [(a,b) for a in seq for b in seq] half a dozen times.
@Veedrac On my piece of junk machine, it does.
 
2:34 PM
Well, OK
How about PyPy?
>>> time pypy -c "[0] * 100000000"
pypy -c "[0] * 100000000"  0.12s user 0.07s system 99% cpu 0.191 total
 
@Ffisegydd @davidism I'm going to install the security updates on sopython
 
h'okay.
 
so server might need a reboot
 
Umm I think sopython-site should automatically start as it's part of supervisor
 
okay... well rebooting now - let's see :)
 
2:36 PM
From those stats I googled why not use pypy, got stackoverflow.com/questions/18946662/… and saw Veedrac comments there. Weird for some reason.
 
@Ffisegydd just payed linode
 
Yeah I got t'email.
Though didn't read it.
 
bleh. I don't know how to catch or debug this error, exactly
 
bah... £49 - I hate the first of each month
end of each month, I get a few quid, then wave it bye bye the next day... sighs
 
@corvid That sucks.
 
2:41 PM
@Robert sounds interesting in Dallas :)
 
in my query string I am getting that my redirect url is incorrect, but I how do I print where it is trying to redirect to?
 
all hail the MTFL @tristan!
 
throws confetti
 
@JonClements that's fine, everything (including minecraft) will be started automatically
 
@davidism sweet :)
 
user559633
2:44 PM
cbg :)
 
@davidism hope you're not expecting an extension SoC set anytime soon... but great work!
 
user559633
switching workspaces, back in 30
 
seconds/minutes/hours/days/months/years/millenia?
 
SoC is plenty complicated without extensions, I won't get bored for a while. :)
 
He'll be back in 30 tristans.
 
2:46 PM
Bye all
 
Where 1 tristan is the time it takes him to clone himself and harvest the organs.
 
bye Robert
I'll miss you ;_;
 
rbrb @Robert
 
30 units of time such that 1 unit of time is 1/30 of the total required time to switch workspaces and sign back in
 
no wonder Sony's missing out on the mobile market
why the hell does anyone want a mobile that can take pictures underwater?
okay - that's nice in some sense... but it's hardly a majority selling point
 
2:48 PM
Octopuses!
But they don't have a lot of income. Bad demographic to target.
 
Divers. People who like swimming. Children. Octopuses. Fish who have evolved arms and hands. Aquaman. Cthulhu.
 
I don't think Cthulhu can operate a digital camera. I imagine he's got one of those Hogwarts-style technology disruptors.
Otherwise you'd be able to see Rlyeh in satellite images of the ocean.
 
Appears I've got my date/time for for my passport renewal
(cos I haven't had one in 12 years - need to do an interview or something)
 
Nah I reckon Cthulhu is all about modern technology. He's down with the kids. "Just off to devour humanity! #yolo #nyarlathotepismyhomie"
 
2:54 PM
Cthulhu lives more than once, too. He doesn't die, he just takes a nap for a few aeons.
 
in SQLAlchemy, is there a way to "pretty print" tables and relations?
 
I think characterizing Cthulhu as a misanthrope is a mistake. It's like characterizing a human as hating protozoa. Also he should be much taller than Hello Kitty. Factual inaccuracies abound in this "World Wide Web comic"
 
@Kevin cuteness and subtlety makes consuming souls easier :)
all your souls will be mine! but I shall defend you against such things
 
For our 1 year anniversary I bought my SO a ridiculously adorable Cthulhu plush. His name is Nibbles.
 
2:59 PM
@Ffisegydd we use to have them at work on monitors
and a couple arranged on a desk, in errr, shall we say, "compromising position"? :)
 
Yeah I only have Duckius Maximus at work.
 
@cor
That sounds like a question that would be legitimate for SO
 
@Ffisegydd I bought a "Gizmo Furby" for the office once - that lasted errr... all of 3 days
everyone had too much fun shaking it or playing football with it, while it was going: "Me no like! Me no like!"
 
@corvid do you mean print rows from the table / serialize the data into JSON, or print the table/relationship tree?
 
Global Variables are bad. But if I want to share some variables between two classes in Python, because Tornado is forcing me to put them into two classes, how do I make a container class? What's the thing that I google to get a tutorial on this.
 
3:05 PM
@davidism table relationship tree; but I am putting it on stackoverflow if you want to answer for rep btw
 
There's no easy answer
 
There's a few tool that will generate .dot files from connecting to a DB... my memory fails me what they're called right now though
 
Oh, are you asking about printing the data model from sql's point of view, like Jon linked, or printing the sqlalchemy relationship tree?
 
sighs - looks like I'm barely breaking evening this month (again)
On the plus side - last heavy outgoing month until end of Jan
 
3:20 PM
silly open
 
@davidism I point to it, however i don't know how to retrieve data.. i created models for those tables but i don't know how to retreive all values from a certain table
 
isnt there anything for open as such that would fail to open a file for writing if it does not exist...
ofc it is because it is copied from libc but it is still retarded :(
so I guess I need to do os.open and os.fdopen
sigh
 
@JoeSaad sounds like you need to read the django tutorial
 
@davidism i did read it and that's why I'm asking. there looks it looks like it is creating the db from the beginning, which is not what i want, i want to use a db already existent.. if you know where in the book, that would answer my question, that would be great
 
3:26 PM
@AnttiHaapala I think there's something in the newest Python versions
Maybe not
 
user559633
@AnttiHaapala why not stat the file and then open?
 
user559633
a stat call should be v. cheap
 
ah silliness,
 
@JoeSaad The docs show creating the database because that is the "beginner" "normal" way to make a django app. But if you already have a database, you just point at it and name your models/columns appropriately, and don't issue a create.
 
But race conditions!
 
3:28 PM
actually there is no support for open for "open an existing file only"
stat it is
actually it needs to be a fifo
 
@JoeSaad also, are you reading the book or the documentation. The book assumes you're creating a database, and is also a couple years out of date (not that that matters for your specific question).
 
@AnttiHaapala Use "r+"
And then truncate the file
 
wondering how when you call your bank from the mobile app, it pre-identifies you
must leave a ttl token for the account along with the phone-id or something
 
@Veedrac it is a fifo
I do not want to open it for +
ah I'll just use the fd...
 
@davidism thanks for your prompt replies.. i'm just not getting how to retreive data from model. when i did that, i'm getting 0 rows returned. there are no db errors.. also another question, when i create models, it results in (creating tables) which is confusing me a bit cause i really don't want to create tables..
 
3:41 PM
kills flying insects in seconds - sounds good, but apparently doesn't have an upper bound of seconds - so probably not false advertising
 
user559633
something something i used to tell my first wife that i can go for hours
 
I'm obviously dealing with some immune fly species
 
stat.S_ISFIFO(os.stat('/tmp/g13-0').st_mode)
must be like the ugliest code ever, thanks python stdlib :D
and ppl call java ugly :D
 
@AnttiHaapala what are you trying to do? :)
if you just want the mode, it's another function, you don't need to call stat and retrieve it
 
nope
one needs to know if it is a fifo
 
3:46 PM
It's about 2.37% prettier with pathlib
 
ahh :d
I am usign 3.4 now
 
But I agree; stat is ugly as hell
 
but cant guarantee I can get 3.4 insatalled on rasbpian
 
Meh. You can just get a backport of pathlib
 
is there a way to get all functions defined in a file, which were defined specifically in that file?
 
3:48 PM
My first and only (so far) pathlib answer
 
@corvid It depends how accurate you want to be
 
I would have gone with the accept answer though, 'cos not everyone has 3.4
 
@corvid hmm, toplevel should be easy
 
@Veedrac Well, I am trying to set a trace function on all programmer-defined functions in specific.
 
"set a trace function" meaning?
 
3:49 PM
@corvid use a decorator?
 
@JoeSaad create a question on SO, and add the actual model code, what you expect to happen, why you expect that, and what is actually happening. Right now, your responses are too vague to answer any more specifically.
 
def say_hi():
  print('hi')

def say_message(message):
  print(message)

def tracefunc(frame, event, args):
  if event == 'call':
    print("you called this function: <function {}>".format(frame.f_code.co_name))

if __name__ == '__main__':
  import sys
  sys.settrace(tracefunc)
 
@corvid I'd noticed you'd provided a settrace solution to someone's Q...
completely overkill imho - but didn't downvote it
 
@JonClements yep, bad answer to a beginner's question too
 
@corvid hint: leave the "dark magic" to people that will appreciate it :)
(and where it's actually the only choice)
 
3:53 PM
I just wanted a unique special snowflake response ;_;
no one would use settrace for something that trivial!
 
Well, when I read an answer like that, I have to scratch my head for a few seconds... a newbie will be just WTF!?
 
@corvid co_filename on python 3
at least
 
nice to see you're getting out of the completely noob stage, and starting to asking more intelligent questions and participating in the community more though... thank you @corvid
 
>>> foo.__code__
<code object foo at 0x7f0e501fb270, file "<stdin>", line 1>
>>> foo.__code__.co_filename
'<stdin>'
 
I am still a noob, just a slightly less annoying one
 
3:55 PM
@davidism alright, thanks!
 
@JoeSaad it's normally against the room rules to post newly asked questions here, but since you've been in discussion with members of the room, then when you've formulated one, you're welcome to post it here
 
@MartijnPieters how much was your illuminator score?
I am lazy to query :D
 
*Illuminati score
 
2291
holy Gsus
 
no no... we don't accept religious references here... "Holy Cabbage!"
 
3:59 PM
BasulC is Holy Gsus. I am Subcommander Gsus.
 
DSM
Cabbage, all.
 
it is unfair that all the new badges are for something that martijn does anw
my illuminati score is 12
it is 0.5 % of martijns illuminati score, yet I have closer to 5 % of martijns rep :D
 
There are no items for you to review, matching the filter "duplicate; [python]"
Yesss...
 
omg, martijn has generalist.
martijn has gold in list, can close all questions related to lists with mjölnir as dupes?
 
@Antti mostly because of all the I imagine :)
 
4:04 PM
Not surprised
 
I want generalist but it is so frustrating to get upvoted in the say json tag :D
 
no offense to @Martijn (don't Katana me) - I think a generalist across C, C++, C#, Java, Python, PHP is a much more impressive record that some people hold
 
I'll get there, eventually.
If only by sheer volume. :-P
I do have the generalist badge though.
 
Well team - we still need to convince @Martijn to run for Mod :)
 
I have 10 of the 40 tags at >15, and 10 more are at > 7
 
4:07 PM
I think we should replace mods with moar hammerz
 
@JonClements Generalist is only earned for the top 40 badges.
 
DSM
If he becomes moderator, though, he might have less time to answ-- Martijn for mod!!
 
you need a score of 15 or more in at least 20.
 
@DSM exactly... Martijn for Mod! Martijn for Mod! Martijn for Mod!
 
You can see your generalist progress at agent86ix.github.io/stackapps/badge
 
@DSM It seems the trick is to answer your own questions. That way you have the head start. It won't work if Martijn starts working in negative time, though.
 
omg i have more upvotes in C++ than in java even though I absolutely hate C++ and want nothing to do with it.
 
@Martijn seriously though, are you or aren't you going to run? If you do, I won't, but will back you - well actually, I think everyone here will at the very least, plus you've got the meta participation - you should seriously consider it
 
@AnttiHaapala On Meta.SE I have 40 out of 40.
@JonClements I may.
No promises.
 
haha :D
martijns customers will be angry
20 days above 200 rep :/
 
4:12 PM
@Martijn with already knowing the SE team, and your history of sock puppet detection etc... you'd be a sure cert... it'd probably be a no lose situation for you
 
user559633
what should i work on today? computer vision interactivity or run through data structures and algorithms in C?
 
@tristan neither - get angry with the world today, put on Kevlar armour, arm yourself with machine guys, and take it out on everyone
then steal a tank, destroy a few buildings
 
I hope you're saying play GTAV.
 
user559633
i'd have to build the machine guys first
 
user559633
so...that sounds like a vote for both?
 
user559633
4:15 PM
THANKS FOR NOTHING JON "MUSCLECITY" CLEMENTS
 
@davidism oh - that's a game is it? :)
oh bugger... thought it was an instructional video
that could explain quite a lot
 
DSM
The problem with checking SO stats is that it's tempting to start deleting low-rep answers to improve your ratios, and to refrain from answering questions unless you're pretty sure you can beat your current average.
 
Wait, you're not supposed to do that? ;)
 
@DSM I have a downvoted answer - I've kept it - but just edited it to say "misread the Q - don't do this"
 
GTA takes some creative liberties with the law. For example, did you know that running into your home and shouting "home base!" is not an acceptable defense for most crimes?
 
4:18 PM
@JonClements Sure, apart from the time commitment.. :-)
 
I've deleted my few downvoted answers, as they tended to be wrong or not as good as another answer.
 
@MartijnPieters let us know... I'll run if you're not running
 
You know something I don't though? No election is forthcoming just yet.
 
DSM
I can only think of one downvoted answer which comes to mind, and while I wouldn't have downvoted it myself -- because it worked and solved the OP's problem -- it did have the wrong explanation, so I deleted it.
 
4:20 PM
@Martijn I'm privy to the exact some info. you are (if not less)
So members, quick election test... right now if you had to vote - puppy/ninja?
 
DSM
Yes, puppy ninjas sound awesome!
 
@DSM nah seriously, I want to convince Martijn he's the right guy for the job if he has time
 
user559633
I wrote a full program in python3 and it was largely painless. Huzzah
 
cbg @Jerry
 
cbg @JonClements!
 
4:24 PM
@JonClements I thought he meant posting the question in the actual SO not in the room
 
I did, and he did too. He's saying you can link to it here after you post it.
 
DSM
@Jon: but I expect that the decision won't be based on a bunch of cheers from his chat.friends, but more reasonably based on time availability, then-current priorities, and the phase of the moon. It's not a secret that given his numbers his odds would be good if he runs..
 
@DSM I think last time if you didn't "know" me for a "well rounded" person, you wouldn't have voted
 
Cabbage all!
 
4:28 PM
cbg
 
cbg
 
How's life going for everyone?
 
@PeopleTalkingAboutDownvotedAnswers Have none of you ever been right and downvoted at the same time?
@Iplodman Don't be insensitive. Kevin's not alive but he's still part of our group
 
DSM
@Jon: Martijn has almost more rep on Meta than I have on SO. :-)
 
@Iplodman c'est bien ici. comment allez-vous madame?
 
4:30 PM
@Veedrac Sowwy @Kevin :c Hope the zambi relatives are doing well.
@JonClements I'll resist the urge to Google that, so I'll make a shot at I'm doing fine thanks!
Was I right? :D
 
/me crosses fingers for school boy French
 
@JonClements I never listened in French :C
 
Applying two semesters of french knowledge... "it is good here. how goes-you, madam?"
 
arhggh... close then
 
Bah, out-done by a zombie.
 
4:33 PM
I have a feeling that should have been "comment ca va madame?"
 
I think I'm more of a "spirit integrating with the collective earth mind" undead than a "animated yet decomposing body" undead
 
@Iplodman The Kevin is eternal in both body, mind and spirit!
 
@Kevin How about an presumably dead organism, who has enough intelligence to be smarter than a mummified lemur.
@JonClements @Kevin is love, @Kevin is life.
 
@JonClements Yes, but it just so happens that my body is separated from the rest of me, due to yesterday's incident. Remember? We had to put it in the closet because people kept tripping over it?
 
OH...
that wasn't the one we sold to buy new carpets after I kept weeing on 'em I hope?
 
4:38 PM
Our closet is so full of skeletons, so who can say which belonged to who(m)?
 
mind have to rent a van and go to the skip... ummm... nothing to see here, move along - all's fine!
 
This wouldn't be the first time that I was "donated" to "science". Not to worry. I usually get listed on eBay eventually.
 
user559633
no no no, you don't rent a van.
 
user559633
you need a small hacksaw and some plastic leaf bags -- the thick ones that you use to clear up brush
 
Your answer is correct, but I'm not helpful. I alone came to this conclusion before I write here. However we will accept your answer. — scalloty 9 hours ago
If he already knew the answer, why did he ask the question?
It was a pretty bad question, too.
 
4:41 PM
@davidism Or why not just answer it himself?
 
> However we will accept your answer.
???
 
I can barely understand what he's trying to say, so maybe it's for the best.
 
I'm going with "Your answer is technically correct, but not helpful to me in my particular circumstances."
 
@Kevin can speak English, French and whatever language that guys uses
 
Maybe an early Beta tester for KevinScript?
 
4:44 PM
@davidism hem, actually not correct but ugly..
 
@AnttiHaapala ?
 
@DSM @Ffisegydd almost finished building a custom pandas groupby
 
sqlalchemy default is not the same as server_default
 
Would a bibliography be suitable to show sources on a report?
 
I suspect the second sentence means "I figured out the problem before I made the previous comment [but after I posted the question itself]" although that doesn't quite follow from the previous sentence
 
DSM
4:46 PM
@Jon: groupby what now?
 
@Antti I'm saying don't use any default, as the remote ip doesn't make sense as a default.
 
@DSM well, I wanted to group 3 billions rows
 
DSM
That's.. a lot of rows.
 
job ad
0
Q: Where can I find a guru C++ developer that would like to build a latency sensitive trading system for a prop trading firm in NYC?

Headhunter -Algoritmic TradingI'm looking for a technologist with a strong background in C++ and network protocols to help build their trading system. They've typically found that candidates with managerial experience don't have strong programming skills and that most developers work on very narrow problems or technologies, b...

 
@DSM So I've got a custom kind of from_iter function
 
4:48 PM
Wow, watch those downvotes come in in real time
 
then, if it's a know set of agg funcs, I can slice the iterable, and keep aggregating the aggregated table
 
0
A: Ip address of visitor in model

Antti HaapalaIt is possible to have such a computed default value, however ill-advised it would be: def remote_addr(): return request.remote_addr ... regi_ip = db.Column(db.String(24), default=remote_addr)

 
I'm going to headbutt the person who upvoted this — LittleBobbyTables 43 secs ago
 
@davidism didn't get a downvote, but I did cast a delete vote
 
@davidism your answer currently says "you cannot have such default value because of x"
 
4:50 PM
@AnttiHaapala nice answer, I overlooked that
 
and... it's deleted
 
user559633
i wish there was a way to team up on stackoverflow -- e.g. make pull reqs into an answer and share the rep
 
@DSM anyway, for simplistic stuff I just wanted .agg(sum, len) etc...
without having 3 billion rows in memory
 
user559633
would do wonders to de-dupe answers and refine to a more "true" single answer
 
@DSM admittedly - how I first did it was just executing a GROUP BY on the server
 
4:53 PM
@tristan Serious deja vu right here.
 
But I wanted each row from the server first for other stuff, then aggregate
So I can do stuff on the row, then yield back to aggregated DF's
not happy with it, but works for now, so
reduced 7hours to 4 minutes
 
DSM
@Jon: we've had discussions about the right API for lazier ops-- for some stats it's easy to use chunks, which is the current official workaround, but for others not so much. Glad you managed to get OOM-level improvements, though. :-)
 
@DSM well for the stats I'm interested in, you can do that, others you can't...
 

« first day (1446 days earlier)      last day (3508 days later) »