« first day (2884 days earlier)      last day (2289 days later) » 
00:00 - 20:0021:00 - 00:00

21:09
If there is 1/4 chance of winning a day and you play every day for a year (365 days), what is the chance of winning at least once? I suck at math, can anyone help me?
Whenever you need to calculate a "at least once" probability, you actually need to do the opposite: Calculate the probability that you don't win a single time. Then subtract that from 1.
The probability of not winning a single time is (1/4^365) right?
Ahh yeah, that makes a lot more sense, thanks.
3/4 * (woops)
@RyanCameron yes
searching questions that i can answer, but are not of poor quality
21:28
^ good luck
It's easy to find good, answerable questions. You just need to sort by "votes". Unanswered questions on the other hand... (:
@Aran-Fey hehe, that's the catch
@Aran-Fey we do have a dupe target for python open() gives IOError: [Errno 2] No such file or directory:. Time to go on a mass closing spree.
@smci Good find, thanks. I'll try to clean it up a little, maybe post my own answer, too.
All together now...
21:40
Reducing a lengthy question to a minimal verifiable example is so satisfying
@Aran-Fey Yeah except you also changed file1 = open('recentlyUpdated.yaml') to with open('recentlyUpdated.yaml') as file1. Newbies won't understand the equivalence. Probably the question should show both ways.
...they won't? That's unsettling. Scary, even.
If I remove the with statement, the code almost doubles...
file1 = open('recentlyUpdated.yaml')
data = yaml.load(file1)
file1.close()
return data
@Aran-Fey I'm being serious. Also, Google won't find it. SO search won't find the literal string file1 = open(...) Don't be too clever.
@smci using with is not being too clever
@smci mass closing sprees are usually discouraged
21:46
Wait wait wait wait wait. How exactly does using a with statement prevent google from finding the question?
and I agree with roganjosh (and Aran's original point)
It just needs a link to context manager docs
We don't need data = yaml.load(file1) in the example, and we don't need file1.close() in the example. Everything after the open()`` falure is irrelevant. We are not teaching them how to write a file-read method, just how to troubleshoot the open()` failure.
I don't know the question we're talking about here but good practice is good practice
True, but I want to expose people to the correct way of doing things everywhere I can
21:49
OK, the powers that be actually say it's OK to mass hammer meta.stackoverflow.com/questions/255738/…
@roganjosh No. You cannot "improve" the code in a simple one-line example, in a way where neither newbies nor search-engines will understand (or even locate) the equivalence. The right way is show both alternatives: f = open(...) and with open(...) as f:
@roganjosh well it's code in the question
if we want a canonical why not have both in the question? Say, the non-idiomatic version in a comment?
with open('recentlyUpdated.yaml') as file1:
     ....
# or:
# file1 = open('whatever')
@AndrasDeak That's precisely what I said to him 5 min ago
ah, OK
That's just noise and distracting. I'd rather just use the file1 = open(...) syntax then
@AndrasDeak Yeah we collided
I still fail to understand how the with statement makes the question incomprehensible for newbies. They see an open call, they see a "file not found" error, and they don't need to understand anything else
@Aran-Fey You don't interact with newbies much, do you...? anything non-obvious will lose people. Show both ways and that's enough.
I don't agree it's incomprehensible; I agree it might have worse google-fu for newbies
Nobody should try to learn from questions. The question only matters for discoverability
Do people actually google code fragments like file = open(...)? Does that work?
21:53
I'm absolutely sure they do, and it rarely works
This is silly. I learned python mostly from SO and would appreciate those kind of suggestions
like, copying their line of code where the error is coming from
So, using with is good practice and link me to the docs
don't forget that we have people who open google to google for google in order to click on the link to google
@roganjosh that should be in the answer
I guess people are quite resourceful when it comes to finding ways to suck at googling
21:54
And if I landed on a question that suggested it, then I also see the link
So put the link to the docs in the answer and we're done here?
we're talking about two different things :)
but yeah, I guess
I'm not a fan of answers that fix every tiny detail in the OP's code. The OP asked a question, and the answers should stick to answering it.
Chat is too complicated for a Saturday night with multiple convos :P
21:58
for the record I didn't read the question
what is a good entry point to learn about (not user-) interfaces?
"interface" is a very broad term. What kind of interface are we talking about?
@Null you mean APIs?
Interface = internet + facebook. So facebook.
I think yes, in german it's called "Schnittstelle".
DSM
DSM
22:00
Brief after-supper-but-before-the-evening-plans-begin cabbage for all.
"Schnittstelle" isn't any more specific than "interface" :P
cutstand!
@AndrasDeak Remember that much newbie traffic comes from Google. Also being visible boosts SO's SEO ranking. @roganjosh if you didn't know SO existed in the first place, you wouldn't have learned Python from it. You would have learned from whatever (2.x) tutorials or examples you could find.
basbbtepbcbg for DSM
@smci nonsense, how do you think I knew SO existed?
22:03
No we're not done yet. I also had to clean up the canonical answer for clarity. stackoverflow.com/posts/12201952/revisions . Another common cause is Windows users forgetting r'' rawstring with C:\path
we should suggest switching to linux, it's a canonical answer after all
And I believe another cause is (Unix or Windows) permissions, esp. when Python was installed as user not administrator. But maybe don't need to mention that. Both Windows 10 and recent MacOS have gotten too clever by half with various directories that the OS magically hides from user. MacOS with ~/Library or whatever
But you told me how I learned python and didn't answer my question
I wanted to delvote that -3 answer, but I'm not 20k anymore [feelsbadman.jpg]
hehehe
22:07
@roganjosh Just because we expose the expanse of water to horse, not all horse come
@smci not gonna lie, your assumption there has got my back up a bit.
DSM
DSM
Example #51834 of why SO voting shouldn't be taken seriously: over the last few weeks I've come up with some answers I'm pretty proud of, some of which faded into obscurity. OTOH, I point out that a guy needs parentheses, and you can just watch the upvotes flow in. :-/
everybody needs parentheses in their lives
@roganjosh I can't understand what you're saying. We cannot expect all users will have started out with SO. By the time they eventually arrive at SO they may have tons of misconceptions. Just because you did, or I did...
Found this on the python-requests docs landing page. "If you are using Python 3, congratulations — you are indeed a person of excellent taste."
22:10
@smci yet you have decided the path they will follow
@roganjosh No I didn't. Why do you keep misrepresenting me?
I'm not getting into this
@coldspeed Basically "I see you're a man of culture as well", huh. Nice.
DSM
DSM
I feel like I could look that up on TV Tropes and lose the next hour of my life.
requests would be a nice place to sabotage incentivize people using 2 to switch
22:12
yes
Here's something else problematic: the square brackets in Python open() gives IOError: [Errno 2] No such file or directory make it invisible to the duplicate-question-search-engine, so it suggests bad alternatives. Sigh...
the internal search is chronically garbage, don't sweat that
@AndrasDeak The dupe search. It actually works ok by considering votecounts too. But it cannot match []
22:16
what "dupe search" are you talking about then?
DSM
DSM
@coldspeed: "Fight On!"
@coldspeed I'm saying all of us will need to manually find and remember this dupe target. I'm CV'ing dupes right now as promised..
@smci Mjölnir'd
@coldspeed with that song on repeat in my local pub, it only incites hate within me :P
@DSM ✌️:D
22:18
@AndrasDeak close a question > "Why should this question be closed?" > select Duplicate > pops up a search window for Closing > Duplicate with top-8 suggestions. It's bad that brackets will make our dupe target invisible
Ah, yes. Utter garbage.
@roganjosh The message behind it is pretty alright :P
Is changing the CWD just to open a file with a relative path really a reasonable solution? I don't really want to include that in my answer
@smci Hammered both
Hey here's an interesting non-dupe: Trying to use open(filename, 'w' ) gives IOError: [Errno 2] No such file or directory if directory doesn't exist. aka open-for-write doesn't create directory if doesn't exist
22:55
What do I do with very similarly-named questions but about a failed install, not user code trying to open a file: what's mean “error: [Errno 2] No such file or directory: 'src/webkit_server'”? about some package dryscape
I'd edit the title to something like dryscape installation fails with "no such file or directory: src/webkit_server"
23:10
Hello! I am creating a form input via Django. I followed the instructions in the django docs but the issue is that the form is not rendering on the site.
Here is the link: repl.it/@xMikee/Calendar
If you need more details or specifics let me know.
Huh. How the heck did this edit history happen? The source for revisions 2 and 3 is exactly identical, as far as I can tell stackoverflow.com/posts/52240080/revisions
@Aran-Fey User 'sissi' is your alternate personality, in the best Philip K Dick manner...
I don't know who Philip K Dick is. Is that bad?
You're kidding right? The SF novelist who wrote/inspired Blade Runner, Total Recall, The Man in the High Castle, Through A Scanner Darkly...
@connectyourcharger You'll probably have more luck earlier in the day, before 90% of the chatroom goes to sleep. It's also more active on weekdays.
23:19
none of you happen to know the answer, do you?
@smci Nope, never heard of him or any of those books
@Aran-Fey BOOKS?! Blade Runner and Total Recall are movies... perhaps the Austrian names?
@Aran-Fey I reordered the answer so "Check the files exists in your cwd" comes before "Change your cwd". It's hard to do a one-size-fits-all answer; if the user is on Windows, it's always the stuff about rawstrings or escaping backslashes (even though Windows accepts forward-slashes since 1995...); of course that's irrelevant to Linux users
@AndrasDeak According to wikipedia he's an author, so I assumed they were books
maybe books too, but they're also movies, very famous I might add :P
and also Dick is a famous scifi writer indeed
23:23
@AndrasDeak because few have heard of the actual books "Do Androids Dream of Electric Sheep?" and "We Can Remember It for You Wholesale". Frankly the former is a dreary read and David Peoples and Hampton Fancher (Blade Runner scriptwriters) really did a good job on the script.
similar category as Asimov, but less well-known
@smci nice
I admit I probably only know about Dick because I have a friend who's a fan; saw him reading Dick's books in high shool
Wow you're missing out.
I have Asimov on my long-term TODO list
Dick will have to wait :P
oh you sneaky little starrer
soooo nobody can answer my question?
lol
Like how Frank Herbert is not as famous as he deserves to be, because he came before CGI could do justice to his oeuvre. Else, Dune might be bigger than Game of Thrones.
23:26
@connectyourcharger please read our room rules and not post problems here that you've recently asked on the main site
@smci I never got the hang of Dune movies, but I'm not sure it's just because of their quality. I read the first three books as a teenager and I prefer my imagination to whatever others can cook up
I'm talking the Dune books, not the films, which never really got traction. The whole thing is often the film does not do justice to the book. Philip K Dick is one of the rare cases where the book needs to be reworked to make a decent movie.
@Aran-Fey how about Die totale Erinnerung?
While I'm at it, Alex Garland's 'Dredd' was superb, 30-years overdue bringing Judge Dredd to the big screen properly. But he doesn't want to do a sequel.
@smci I'm not sure I see your point then. CGI vs books...not a typical connection. Before CGI became a thing people actually read.
@AndrasDeak Nope. Try something Fantasy-themed, I'm more likely to know those
23:31
Weird!
at least Die unendliche Geschichte should ring a bell then :P
Andras in general yeah there's a tension between SFX and plot, but the SFX in the 1984 Dune film weren't great so we never really saw Herbert's vision... a sad loss...
Talking about, high time to release Avatar 2/3/4/5
You're losing me. First you say it's about the book, but now you say it's about Herbert's vision vis-a-vis movies...
@AndrasDeak I know that one! \o/
@Aran-Fey Hmpf!
I've read it, too
Twice, even
23:34
@AndrasDeak In general books are the better source, but often not as well-known. But when it comes to the film adaptation, too little SFX is also bad as too much SFX.
@Aran-Fey Me too. Once, I mean. In English, alas. The first book I've read that had two colours for text.
@smci I'd argue that proper fame comes from the books themselves (something something hipsters)
Did you guys see Alex Garland's 'Dredd'? It was superb. But there's a much darker and more political slant on the 1980s IPC comic Judge Dredd. Think Robocop, without the happy bits.
nope, not my cuppa
Imagine if Dashiell Hammett and Raymond Chandler were alive and doing films today... would be terrific
I want Adams and Pratchett to be alive today :'(
23:40
I just realized my favorite author released 4(!) new books that I haven't read yet. I really need to start reading more again
who dat
You won't like him :P The name's Hasekura Isuna, and the books are light novels
Anyway in the future AIs will write scripts about androids becoming sentient... but will we notice...
@Aran-Fey you have no idea what I like :P
ah, furries!
Do you read a bunch of different genres?
23:42
Not really :) Frankly I rarely read at all. I pretty much only read fantasy when I do.
Fantasy? That's unexpected.
hehe, shocking
I'll check that out sometime, thanks
Don't Panic
wim
wim
23:45
Invalid license plate :(
damn, the Neverending Story theme stong is stuck in my head again
@AndrasDeak WTH... a forced watching of 'Howard the Duck' will cure you.
The good news is that the theme song ends at some point, unlike the story :P
@smci ew!
What if I told you the Eric Idle character in 'Nudge Nudge, Wink Wink' was a replicant....
23:57
@smci that's fun
I hope Avatar 2/3/4/5 are worth the wait
00:00 - 20:0021:00 - 00:00

« first day (2884 days earlier)      last day (2289 days later) »