« first day (1151 days earlier)      last day (4020 days later) » 

00:08
I'm just trying to refactor some code and I have been told to implement something in terms of a named tuple. I want to add some methods to the named tuple class so that existing code can keep using it without needing changes. What's considered the clearest way to write such code?
One specific question: is there some way of conveniently adding a docstring to a namedtuple class?
class MyClass(namedtuple('MyClass', 'x y')):
    """Docstring...."""
    pass
Is this an ok way to go about it?
Oh and this is python 2.7 so no _doc_ unfortunately :(
01:08
Morning, all!
@inspectorG4dget hi :)
Hi @shuttle87
What's happening?
cbg @shuttle87 @inspectorG4dget
cbg @samrap! done with school for the day?
I got out a few hours ago, but done with homework now! It's 5pm over here
01:15
Nice! It's 6.45AM here
I guess it would be a good idea to use the 24 hour clock in this chatroom!
School today?
@samrap: seconded
Just switched my phone time to 24 hour, I gotta get used to this
I guess the pattern is that if the time is > 12 you subtract 12 to get the 12 hour time
@samrap: or should we perhaps post the local time since epoch and let everyone else figure it out?
Could just use UTC perhaps?
01:23
Or invent our own time system ;)
It's half moon (sunset) here
But UTC is the same for everyone
how about the offset from UTC?
Hi all!
01:39
cbg @Raoul
What's that?
and everyone
I feel like 24 hour is best
Cabbage
Why do they even make FTP applications it is so much better from the command lin
line
@samrap: because most people are muggles and don't know how to use this command line wizardry you speak of
If only they knew how awesome it is. I learned from linuxcommand.org it was so easy to at least learn basic navigation
Now I use the command line for just about everything except programming
01:43
@samrap: you might be interested to read this. It's a good laugh
But yea haha the command line is complete magic to the noobs
I feel like we need a command line wizardry meme
This comes kinda close, but doesn't quite do the job
I just call them "Lesser Mortals"
That's what I said! :)
HAHAHAHA
That is the best meme ever
I like how linux fanboys view each os, especially microsoft
We need a meme called "The cave dwelling developer"
It's gotta be a guy who hasn't shaved for 3-5 days, sweating at the forehead, and greasy hair pulled back but fanning to the sides
01:51
Look at #2 here
amazing
I LOLed at #1 quite hard. I really want that mug now!
#1 is classic
I like the guess the browser one too
I'm on #8 right now. Definitely saving to bookmarks
Hahaha that was the best laugh I've had in awhile
02:12
yeah, that's a real pick me up. I've bookmarked it and read it every time I have a shitty day
Just found out that FTP is insecure, so I tried using sftp but it's not responding
From the command line: sftp [email protected] and then I just get a blank response
that's expected, if the server doesn't allow an SSH connection
Dammit iPage
 
3 hours later…
user559633
got an edit that fixes an answer rejected
@tristan -- It's a pretty major change.
In this case, I'd suggest you go ahead and post another answer
It's unlikely that you'll get a change that significant to go through on a post which has 30+ upvotes.
user559633
@mgilson it's closed because it's a duplicate.
user559633
AFAIK, i can't add a new answer (I agree this is a good thing)
user559633
I suppose it's not the most dangerous "wrongish" answer, but it's definitely not a good answer.
05:40
Ahh, didn't realize it was closed.
 
1 hour later…
06:53
I'm back! :D
Cabbage all you guys! :D
07:38
@InbarRose Hey man! :D
Hows it goin?
I got a job interview today
Got any suggestions for me?
Is this your first one or something?
Yea, my first one.
07:49
Well actually the second one.
But, this is the first time I'm going to be giving it to a y-combinator startup
So, I guess I'm just a little scared.
Okay, so lets start with a Socratic approach.
What do you feel you did wrong in that first interview?
Erm, the first interview lasted 5 minutes. The guy liked me instantly.
07:51
Erm, probably because he saw that I tried to study outside of what my university told me to study
LIke my university started with C, I started learning python on my own.
He saw my stackoverflow account, and decided to hire me.
And how did you inform him of these things? (learning python on your own, SO account)
I asked "how"?
Oh, sorry. Erm, I just told him I learnt Python on my own, using MITx's online course.
I showed him a couple of questions I answered.
What did he ask you in order for you to say that?
What would you have done would there not have been a computer in the interview so you could show him those answers?
07:53
He asked me why did you learn Python, its not mainstream?
@GamesBrainiac What did you say to this?
Just what I told you, MITx and then SO.
That's "how" you learned python, not "why"
Well, I told him that I wanted to learn a language where I could be a lot more productive without having to worry about low level details. I chose Python, because thats what MIT and a lot of other good universities start with.
And what prompted you to decide to research this?
07:57
My frustration with the horrible syllabus at university. I mean, we spent 3 lessons learning about how to use pointers to loop around arrays.
I wasn't able to build anything useful with what I was learning.
I mean I could generate fibonacci just fine, but that wasn't enough for me.
Also, at the time everyone was learning either C/C++ or Java.
I just did not like any of them.
Java the least.
How long have you worked in your current job?
2 Months.
Then there was a dispute between the partners, and all hell broke loose :P
that is really short, how come you are already looking for a new job?
So the company went under?
No, it did not go under, its still there, but what happened is that one partner decided to withdraw all the firms money. He was able to do this, because another partner gave him a cheque to withdraw some money for employee salaries.
The cheque was a blank cheque.
So the partner withdrew all the money from the joint account, leaving the business in a horrible situation.
My boss who was planning to hire two more, was not even able to keep us employed.
I'm looking for a job, primarily because I want to gain more practical experience.
I can only learn so much by myself. Working with a team who're about to push a new product to the market is a great opportunity to learn from.
I mean, I could use the experience when I try to push my own idea to Y-Combinator.
Okay. So - now let me give you some general pointers. And then I will address what we talked about now.
08:04
Sure man.
First of - (I shouldn't really have to say this) you need to tell the truth. Now - I don't mean "no lying" I mean, if you are asked something like "do you know php?" you should only say "yes" if you really are a php developer, not if you just know a "hello world" in php. This is true mostly for things like MSQL where some people know how to write DB selects etc, but not everyone knows about joins and groups etc... so, firstly - is to be honest, and that includes not bloating your resume.
Second - Experience is the most important thing that potential jobs are interested in - that is the only thing that (unless you simply lied on your resume) can tell them if you really know your stuff.
To expand on that.
A job won't keep someone around for long if they don't know what they are doing. So, if someone has lots of experience (especially an extended time at 1 place) that is very beneficial.
08:08
Ahh, I see.
The fact that you have only 2 months and that is your only experience is not in your favor (but more on that later)
Oh to be sure. I know that. 2 months of job experience is not going to help me much.
During interviews, often times you will be asked to tell them "bad things" about yourself, for instance "what do you feel is your greatest weakness?" or "when was the last time you failed your task?" etc.. questions which are meant to judge your responses, and how you are as a person. You need to already think of examples that are not "so bad" and that can also kind of make you come out alright.
I have a couple of those ready.
For instance a question like "what do you feel is your greatest weakness as an employee?" Answering "I hate authority and I like doing things on my own" is the worst kind of answer, but wording the exact same thing in a positive way is much better, something like "It is hard for me to work with others and I find that I work best on my own, often times I will continue projects beyond the required so that I can do it on my own - sometimes this clashes with the teams scheduling, but ...
... as a perfectionist it is hard to stop before I feel what I work on is finished"
08:14
Ahh
There are endless articles about these things - I am sure, but I am giving you what I think is the greatest gems of advice from what I feel helped me.
Ahh, I see.
Next - They might ask you to talk about "good" things you have done in work like "what projects that you have worked on do you feel were your best?"
This is the best kind of question in an interview.
This is your chance to expand on things so that you come out like superman.
Hmm, I see.
For instance, a project where you and a friend wrote a game like minesweeper (for example). You could say "A friend and I wrote a minesweeper game" and that's it.. or you could really give a good answer..... like.....
"A friend an I decided to test our programming skills by copying the classic game minesweeper, we first analysed the game - learned how it works, then we started by distributing the work - I was working on the logic, my friend worked on the GUI. We used git to maintain our code, and used a unittesting framework to check our work. Once completed we tested it with some other friends and made sure to fix any bugs that we found until it was perfect"
This is just an example - I am sure you are intelligent enough to understand the general idea I am trying to convey here.
08:21
Absolutely! :D
I made a connectfour game with AI
so, I guess I could use that to my advantage.
Okay, give me an example.
Explain your project.
Well, I wanted to take on an ambitious project that involved me having to learn something new, or using my python skills to be absolute max.
And perhaps also to enhance them.
I previously made a tic-tac-toe game in Java, so I was thinking that making a connectfour game in python would be something interesting to make.
At that time, I just finished a course from pluralsight on how to test code
and started learning how to use tkinter properly from Lutz's Programming Python.
So, I thought that something like connectfour would be interesting.
Now, I wanted to do this with someone else.
The reason for this being that most project I've done, I've worked on my own.
And thats all well and good, but getting the synergy working in a team was something that I wanted to pick up as well.
So, I asked falsetru, a member of Stackoverflow and a python veteran.
I made the initial commit, and he worked on testing the code.
I wanted to see how he wrote the testing code, so that I could pick up a few things.
Initially, we chose py.test, but later on moved onto unittest, since our debugger provided enough information regarding the test failures that we did not really need py.test
also py.test's fixtures are not all that great.
don't digress. that is bad.
Ahh, okay.
I was just trying to show that I used different testing frameworks, but okay.
I worked mostly on the logic, and the app itself, while false worked on the GUI using tkinter.
if you digress - change subject - avoid a topic. That might mean you are hiding something - and subconsciously it will be affecting the interviewer.
08:29
Ahh, okay.
I mean this last line "also py.test's fixtures are not all that great."
Has nothing to do with the project.
well they're not! :P
Okay, will avoid digressing.
That sentence could be "the sky is blue" and it would have the same impact
08:31
And as things stand, we're still adding the finishing the project, but there's a working prototype.
That is a good trick - if anything you say that would be replaced by nonsense like "the sky is blue" would not change anything about what you are saying? don't say it.
Okay then.
Okay - so I feel you are okay for the general questions.
How are you on confidence?
I don't know how you are physically - like - how confident you are speaking.
Well, I'm a pretty confident speaker.
But as things stand, I'm not too confident about me getting the position.
So no worries there?
hmmm
How come?
08:33
Well, I'm Bangladeshi.
If I were a startup based in the US, I would do my best to find someone from the US.
Oh - I see.
You know what I mean?
Where do you live now?
Dhaka, Bangladesh.
How exactly do you have an interview with the American company then?
08:35
Well, I applied and sent them an email
The job was posted on hackernews
Oh - okay.
Is it a relocation job?
Yup.
As things stand, I'd really like to join because I'd like to learn more about how a startup works.
I'd like to make a startup myself.
Wow - well.... Then I don't think your skills/experience/personality are going to be the most important things in the decision of the company - but you definitely won't get anything if you fail those... So... I guess that you really need to show your worth above others. Why will it be a good choice to take you specifically .
I work in a startup.
Let me tell you what kind of skills are admired.
Very interesting to hear your discussion on interviews
@InbarRose Oh please do! :D
I love hearing about startup stories.
08:39
Initiative, dedication, working well with others, --- let me expand on that before I continue, in a startup, you have usually a small group of people, everyone is working closely together, many aspects of the company are not fully realized, maybe there is no secretary, maybe no QA yet - maybe your job is the developer of the app, but also the webmaster - So you need to be good with others, and have initiative, and be able to do many things at once...
You will usually have lots of workload - strange schedules - sometimes staying a whole night will be important - so you need a flexible schedule.
@InbarRose Oh I'm good with working with others and adapting to needs.
An advantage you have is that if you are relocated - the only thing you will pretty much have where you mvoe is the job. So you will be able to be there many hours.
My startup is a very close group of about 20 people.
So we are constantly going to lunch together, spending time after hours in bars near work - so I would say being sociable is also important.
That sounds amazing Inbar.
I really want a group of people who will become good friends.
A startup is a great place since you have similar goals, ambitions and skill sets.
So - that is the kind of person you need to be in the interview.
what is your startup
08:42
Okay then.
@SašaŠijak I can not say exactly - because it is in the security/encryption field, so I have to keep anonymous about it.
@InbarRose Thanks man! :D I humbly appreciate it.
Of course. My pleasure.
If you guys need a pythonista, please feel free to give me a knock :D
is anyone here using Flask
08:46
cabbage
cabbage?
yes cabbage
Cabbage.
08:50
@MirkoCianfarani That is so disturbing. And for all the wrong reasons./
lol, why this veggie talk? :D
Wzup
Cabbage!
this is peas
Cabbage fellers :D
@Jerry Long time no see
Exams over yet?
08:57
hai
yes
well, I saw you online a couple of times of skype though xD
yes, I have been online :P
what are the biggest websites made in python? I know of disquss
it is in django
I doubt huge websites are in pure python
but I guess the largest would be dropbox
well, i found dropbox to be very huge
why would not they be in python?
not 100% python
thats for sure.
I'm sure they've put in a couple of C extensions in there somewhere.
09:05
well, ok with some libraries with C extensions
for example we use java Spring on work
@JonClements cabbage! :D
which is considered de facto for enterprise
but I can do all that which spring can in python`s flask with extensions
but faster
much faster
True, python cuts down development time a lot
Perhaps you can take a look at falcon-python
Cabbage all
@Games cbg cbg...
benchmarks looks nice
but it is barebones
@SašaŠijak Its an API framework, what did you expect?
some batteries included
like flask
it compared itself with flask in benchmarks :)
09:25
Cabbage @JonClements
hey again @Jerry - how goes it?
cabbage all!
back at work and there are broken things left and right...
cabbage inspector
well then @Jerry, walk the fine line in the middle
This one's for you, @Jerry
@inspectorG4dget break things equally each side?
09:33
@inspectorG4dget Nice one xD
@JonClements: a biologist, a chemist and a statistician go out hunting. The spot a deer. The biologist shoots and misses by 5 feet to the left. The chemist shoots and misses 5 feet to the right. The statistician rejoices "yay! we got him!"
Unfortunately, the fine line is not really a proper line, more like a broken line but that's okay, I guess I will wait for other people to fix it.
Then now might be a very good time to learn hopscotch, @Jerry
oh cool, I never learned the english term for that game
girls used to play that back in elementary
@inspectorG4dget groans :)
09:38
lol @JonClements
@Jerry: where dost thou call 127.0.0.1?
I'm still waking up - let me get more tea in me before any more onslaught of such things! @inspectorG4dget :)
127 is my country I believe
@JonClements: make some for me too, please?
or maybe it's the relay the IT has been using arg
@inspectorG4dget it's breakfast tea - not anything fancy... but sure, I'll make extra
@jerry do pokemon actually live on earth?
09:40
Thank you @JonClements. I'll expect to get it in tea minus ten minutes (sorry, couldn't help the pun)
if you believe they do, they will @JonClements :)
oh cool, okay I think 127 is the correct IP
oh well, it seems to fluctuate quite a bit
I was 108 a while ago
127 is the loopback block. So it's whichever country you happen to be at, at the moment
ahh
anyway, to answer your original question, that country is named Mauritius
ah! Lovely place (or so I've heard). Never been, though. What's the weather like, right now?
@inspectorG4dget come get it
09:45
@JonClements: that actually looks really good. IwantIwantIwantIwantIwant!!
@inspectorG4dget It's really hot right now and the temperature is expected to go up some more in the next months :s
yowza!
isn't this your "winter", though?
@Jerry ahhh.... so that's where this global warming is occurring...
@JonClements It's a teeny bit colder in winter than usual as well, so I guess yes
@inspectorG4dget Summer's top hot months are usually January and February
ouch! Come to Canada - we have plenty of snow to go around in Jan
09:48
that'd be cool indeed :)
both literally and figuratively
Errr... if you're in Canada... doesn't that make it stupid o'clock there?
flask with websockets reccomendation?
@JonClements: I'm visiting my parents in India for Christmas break
Ahh yes - you did mention - sorry - I might wake up at some point
No sweat! The great thing about my schedule that I stay up late, so when I come here, even though I'm technically jetlagged, I sleep and wake up with the rest of the family :P
You're somewhere in the UK (if I remember correctly)?
09:57
Yup - Good old England :)
Where abouts? how close is that to Reading?
At the moment in the Leeds area...
Oh, about 200+ miles from Reading
oh! nvm, then

« first day (1151 days earlier)      last day (4020 days later) »