« first day (1116 days earlier)      last day (4057 days later) » 

14:00
@GarethRees I don't recall that prior to 2003
Prior to 2003 the limit was £75
Joe
Joe
@JonClements are you the company owner?
Interesting... here I do the "that was the accounts department responsibility"
@Joe it was a company I worked for yonks ago
I expect Accounting took it out of the attendees' pay
I don't recall having pay deducted nor anyone moaning about it either... so... moving swiftly on here...
How's the weather everyone? :P
Joe
Joe
14:04
that would explain why it doesn't bother you that much Jon. If that was my firm, I'd be pissed
@JonClements Cold!
I'm just amazed that 46 people could run up a £24k bar tab. That's £521 each.
Best Champage bottle for everyone.
@Gareth there was a little over a 100 in total though
(just not all employees)
Joe
Joe
freebees + free alcohol = big bill
14:07
@Joe what probably didn't help is that the bar wanted to close at 2am... but the MD insisted he stay open... so they got more staff and opened up another room...
Wait, what?
They wanted to close, but you wanted it to stay open, so only then they opened another room?
@JonClements I'm not happy with the website, but they are. I guess it's the best of all worlds ;)
@IntrepidBrit that's one way of looking at it :)
@poke I vaguely remember going to reception about 6am and booking another night cos there was no way I could drive home if I checked out at 11am
xD
@JonClements continues tinkering unpaid with the website
Joe
Joe
14:10
@IntrepidBrit can we have a look at it?
Hi folks,
can anybody has chance to look into the problem
http://stackoverflow.com/questions/19790795/django-python-to-access-defined-constant-by-equivelent-string
@Joe Nope. It's not available on the publick intertubes :)
Joe
Joe
@IntrepidBrit no problemo
please do let me know if it does not make any sense :)
Joe
Joe
django python! maybe I can help
14:12
Thanks @Joe
Don't worry @MaNKuR, it's a relatively easy one. You should be flooded with answers soon :)
Joe
Joe
@IntrepidBrit they're gonna tell him to read the documentation I suspect
13 minutes and no answers yet; I’m disappointed.
is that right? @IntrepidBrit. Please help me how i can get it
here too :( @poke
@MaNKuR Well, my first comment would be to not stick it directly in the settings (for version control reasons)
14:17
Unfortunately I have no idea about Django, so I can’t really help..
And import from some kind of constants.py file in the same folder
INTO settings.py
np @poke
And I would just use a django dictionary
*python dictionary
Joe
Joe
Is an API a subset of the MVC design pattern?
(brain not engaged error)
14:18
@IntrepidBrit [X] flag: Not an answer :P Good to know but no answer to the question ;P
How doesn't it answer the question? He wants to access a constant global value by a string name
Well, the actual question is, when there is a constant defined somewhere, how can I use it in a template. So far, you have only moved the definition around :P
you are right @IntrepidBrit I already had this in a separate file and included this in custom template tags file where i can able to access it by defined constant name but not its equivalent string :(
(Again disclaimer: I have no idea :P)
14:21
@poke I'm missing something here, it doesn't say anything about templates in the question?
yeah its right :)
and the reference to that @CONSTANT() thing
Joe
Joe
@MaNKuR You want to access the constant using a string in your template tag?
I want to have it in template but if i could know how it would be accessed in view
then I can access it in anywhere
@poke I have no idea about @CONSTANT(), and I generally ignore tags as a rule of thumb (unless it's to do with version numbers etc).
Argh! I wasn't going to get myself tangled up in answering this ;)
Joe
Joe
14:25
Have you tried something like this: context_dict = {'categories': category_list}
@IntrepidBrit it must be the "say something so everyone can decompose it to the point you wish you hadn't mentioned it" day :)
now i have edited this replacing django-templates to django-views :)
@JonClements Clearly. And I'm running on like 10 hours sleep for the last 4 days
Joe
Joe
sometimes its easier to explain why you're doing this, and then people will normally explain a better way to achieve the same thing.
how this context_dict = {'categories': category_list} would help in this case @joe.
14:28
@JonClements So I'm not at my most eloquent ;)
Joe
Joe
@MaNKuR but what I'm saying has something to do with what @IntrepidBrit said using a dictionary
If i understand you correctly that means i have to define a dict in settings having key as defined constant and its corresponding value :)
than we can access it easily :)
@MaNKuR Yep. What's the constant for btw?
Joe
Joe
@MaNKuR defining a key:value pair in settings.py? Does that sound correct to you? @IntrepidBrit
@Joe That's close to what I do for genuine django-wide constants
14:32
yeah @joe that was my next question thanks :)
Joe
Joe
@MaNKuR As @IntrepidBrit said, what is the purpose of the constant?
That's why I thought there'd be loads of answers because it's more of a Python question than a Django one
Umm.... @poke finding some interesting questions that are no longer about....
@Jon huh? :o
@poke I need help in hairy ball problem, I am trying to learn computer graphics and theorems myself - was a maths.se post
14:37
@JonClements What kind of question?
Sadly I ignored non-SO posts :(
I have list of label text of each template where user can able to edit it. And we are saving it in our DB corresponding to that user and displaying that text only to the user otherwise fetching the default value.
@Jon wtf
Cool or what :)
@MaNKuR Then you presumably have a defined model for storing the user templates?
14:40
@poke It has a strange name, right?
But what made me laugh was the first information wikipedia showed me..
"Hairy balls" redirects here. For the mayor of Fort Wayne, see Harry Baals.
@poke it was tagged ["general-topology", "geometry", "algebraic-topology", "differential-topology", "curvature"] so ummm... for it to have been deleted, it might well have been someone pranking based on the name...
The German name is even better. "Theorem of the hedgehog"
That guy wasn't so lucky.
@poke Hahaha
because you can't comb a hedgehog without it getting bald at some point
rbrb
I need to save the label_text against its (html tag field id) name (column name in model) where a single template can have multiple edited text label. is this answered to you question @IntrepidBrit :)

Actually I have created a model having user_id, text_label and we defined this text_label in constants.py files with default text
14:48
@MaNKuR So rather than having a global constant, wouldn't it be better to that constant defined in the models.py? Or will this constant differ between deployments?
yeah It can be set default to the field of that model. but cant we access it like I mentioned in stackoverflow @IntrepidBrit
But if you define it exactly in the same way as we've done for settings.py (ie, a dictionary containing the values), we could put that definition in models.py
And it should work
Sorry I could not get this :( @IntrepidBrit
would you mind to sharing some example(link) if you have chance to.
I wonder why reversed(some_ordereddict.viewvalues()) fails.. shouldn't the view object be easily reversable?
(i know, it happens because __reversed__ is not implemented for the view object, but it doesn't seem to make sense)
@MaNKuR Hey no worries. Is your solution working now?
14:57
Create a bug, and a patch :P
@MaNKuR All I'm suggesting is effectively a "cosmetic/maintenance" improvement based on my ideas on how information should be gathered :)
thank you @IntrepidBrit, @Joe I will implement this keeping your suggestion in mind (valuable one)
@ThiefMaster same reason it's not implemented for sets.... or dicts... (it doesn't make sense)
but for an ordered dict it makes sense!
okay okay... I missed the ordered first time around :P
15:07
anyone familiar with Oracle databases?
@Crowz have you asked Neo?
har har (okay I actually laughed a little)
how familiar do I need to be to help you?
@poke hope your mind reading skills are turned on...
Always
15:14
Okay... I'm thinking of an animal... let's make it trickier.... two animals... what are they?
hi there @BadgerGirl
Easy. Not a badger, but rabbit and kitten.
Hey. Will you all be my second best friends?
Damn, I was sure it was a mongoose and echidna
Sure, but who’s going to be the first second best friend?
You are.
15:16
yaay!
You're German and I like your tweets.
@poke you have a stalker! Congrats.
Interesting. So there are people who read my tweets.
Yeah, I'll follow you.
@poke I think I figured it out... my query was running for like, 4 minutes so figured something was up. Turns out I just don't know how to sql.
15:17
It takes all sorts to make this world of ours
@Poke yup - you've met 'em now ;)
Have to shut down for a bit, don't want my prof to get mad, rbrb!
(bleh, uni)
Don't leave! :(
Argh. My language skills are failing me
What's the word/term I'm looking for
I went back to ubuntu
Support is way better for it
15:21
starts typing out the description, remembers the word. Shuts up
@GamesBrainiac I both love and hate Ubuntu
What word was it?
Multi-discipline(d)
[[1382713629.457573, 'comment-add', None],
 [1382713630.05548, 'post-edit', None],
 [1382713652.931614, 'comment-add', None],
 [1382713705.342278, 'score', -1],
 [1382713711.591872, 'score', -2],
 [1382713715.240802, 'score', -3],
 [1382713719.563525, 'score', -4],
 [1382713719.855901, 'score', -5],
 [1382713721.684593, 'score', -6],
 [1382713722.829034, 'score', -7],
 [1382713725.720059, 'score', -6],
 [1382713743.842908, 'score', -7],
 [1382713746.707334, 'score', -8],
 [1382713748.564192, 'comment-add', None],
@poke yup - looks like downvotes happen bloomin' quickly
This is a time I would pay to be not British. Blowing one's own trumpet just isn't cricket damnit!
array([ 0.59790707, 23.47404099, 75.88470507, 82.13429904,
85.78322911, 90.10595202, 90.39832807, 92.22702003,
93.37146115, 96.26248598, 114.38533497, 117.2497611 ,
119.10661912, 124.54828095, 131.4199791 , 132.26483607,
134.03205109, 139.34289718, 143.132792 , 156.06850696,
228.2403121 , 228.87000203, 234.95400405, 237.28988004,
308.63253713, 311.36545801, 574.18187809])
Okay... so it looks like 90 - 180 seconds is the "danger time" :)
15:30
@JonClements The time taken to get a notification, click and read?
So - looks like downvotes are really before comments
That's what I do ;)
Umm.. errr... what question is that relating to though... not sure I've filtered out Python only
A deleted c# question that ended up on -19 ...
It's c#. It probably deserved it
Mhm, that's hard.
15:48
Wow... looks who has turned up - how are you @Colin? :P
tired, bloody mondays
@ColinO'Coal :)
I see your daylexia is improving slightly
^^ never ends (I fear)
There's always tomorrow... or yesterday... or errr....
something...
15:50
There will always be ...
That'd be a good "famous last words"...
but no weekday is so horribke like sunday
I hate sundays
Reminds me of this skit from Louis C.K.
I'll have a look in a sec. :)
Warning: it's got swearing, and its hilarious. You will die laughing. :) (The part that I am reminded of is at the end)
15:54
Oh right... so, I should be making sure my LW&T and estate is all in order before watching play?
haha, the vid is really cool
Is this like "The Ring"... so you're trying to get others to watch it so you don't die?
Oh come on. It's an expression.
You could be counting on the fact I'll take it as an expression, then use it as your defense that you did warn me
I could.
15:57
@Colin are you still alive?
no, try stopping me laughin whith my work room (filled up with several colleagues)
harharharh
made my day
oh - he hasn't finished watching it yet... I'll hold off for a moment and get the ouija board just in case :)
Oh come on.
15:59
@)
umm... I appear to have morphed into cyclopuppy
haha, "why?" ... "because I'm stupid"
that I've to remember to use at home too muhaha
Can someone help me figure out how to use this snippet of code Guido posted here stackoverflow.com/questions/14542175/… ? I'm a bit of a Python newb. Am I supposed to add that to my model?
"model" ?
next top super model?
oh .. damn .. okay
16:05
So, Colin finished watching and is alive. @JonClements you can watch it now :)
@TylerW Add that to your code
before the class declaration
What do you need it for?
no no
I don't finished
paused to go to toilete ;)
You have like 10 seconds left or something then, if you already got to the "why?" ... "because I'm stupid" part.
Seriously? You left right before the end? How ant-climactic.
presure
okay. i added it to my code. i think the problem is when I try to use it
16:08
haha, finished
i tried something like c = Counter.my_get_or_insert('first_counter')
but get "unbound method" error
time to end up work day
(watch again)
@TylerW you need to add a @classmethod on that method
@PaoloCasciello ahh!! thanks! :)
16:16
Joining chat from phone actually works? Awesome.
No auto completion though..
why not? it's a simple webpage using websockets... :D
Well, it's responsive
And not the same big thing
whoa... at the end of 2013?? :D (sarcasm alert) :P :P
@poke it's actually not bad... except you need to switch to desktop site to upload important pictures of cats and rabbits
@JonClements Watched the vid?
16:26
so... anyone familiar with sql? ._.
@Crowz What about sql?
@Crowz And read this: ChatRoomEtiquette
no one uses sql
LDAP/MSQL is probably one of the most common protocols.
16:29
m... my sql is called by python, does that count?
@Crowz Just ask the question.
if you have two queries with only one field in common, can you left join on them like that?
Sql is better than just the database, yes
Yes.
@Crowz Crowz. You NEED to include your code. I simply can not help you (nor can anyone) based solely on description of your problem.
16:34
it's a LOT of code though.
I can. Yes.
@Crowz Just the query. - Or use pastebin.com or something.
Question was; can you join two queries? Yes, if course. Does that make sense? Maybe.
@user2650309 It seems you don't have enough reputation to send messages in the chat. Let me make an exception for you, hold on.
@poke lol :D
16:36
@InbarRose sadly - that doesn't work... 20 rep min is a must :(
Shame.
It's annoying
Lets vote his question up then.
hi
I need some help, there is an infinite loop somewhere
I am not sure whats causing it
@JebediahKerman ABANDON SHIP!
16:39
def pin_correct(pin):
    pin_attempts = 3
    acces_granted = False
    while pin_attempts > 0 and not acces_granted:
        acces_granted = False
        len_pin = len(str(pin))
        print('Please enter your {} digit PIN.'.format(len_pin))
        print('You have {} attempt(s) remaining.'.format(pin_attempts))
        pin_user = raw_input()
        #if the user enter wrong format
        if len(pin_user) != len_pin or not pin_user.isdigit():
            print('PIN has to be a {} digit number'.format(len_pin))
Okay.
You should reduce the pin_attempts every iteration. Not just under a certain condition.
s/acces/access/
but if the pin is 1234 and they enter 34
I do not want to take of an attempt
why do you even tell them about the length?
idk, I am nice
16:41
don't reveal any information about a password.
its only HW
doesn't matter :)
and you can just return True when the pin was correct. no need for the access_granted flag
aha
thats what you think
16:42
To be fair, PINs are usually fixed length anyway.
but then It would keep asking them for the correct although they already entered it
return breaks through the def...
maybe I should use break
no it would not. return exits the function. no matter if there are loops or not
really?
did not know that
16:42
of course
i think the only language where this is not the case is VB6
but that's because there's no return value-style statement at all
so I did the break thing now my code looks like:
def pin_correct(pin):
    pin_attempts = 3
    while pin_attempts > 0 :
        len_pin = len(str(pin))
        print('Please enter your {} digit PIN.'.format(len_pin))
        print('You have {} attempt(s) remaining.'.format(pin_attempts))
        pin_user = raw_input()
        #if the user enter wrong format
        if len(pin_user) != len_pin or not pin_user.isdigit():
            print('PIN has to be a {} digit number'.format(len_pin))
        #correct format, wrong pin
        elif str(pin) != pin_user:
Try my version.
Made a small error.
I get an error
16:46
I fixed it,.
Oh, I am calling it with a string, you are using an int.. hold on...
btw, unless you from __future__ import print_function you shouldn't use print(foo) but print foo
 def pin_correct(pin, attempts=3):
    pin = str(pin)
    while attempts > 0:
        print('Please enter your {} digit PIN.'.format(len(pin)))
        print('You have {} attempt(s) remaining.'.format(attempts))
        pin_user = raw_input()
        #if the user enter wrong format
        if len(pin_user) != len(pin) or not pin_user.isalnum():
            print('PIN has to be a {} digit number'.format(len(pin)))
        #correct format, wrong pin
        elif str(pin) != pin_user:
            print('Incorrect PIN.')
another errer TypeError: object of type 'int' has no len()
isalnum checks for alphanumeric, not just-digits
Yeah, I didn't know you are feeding it an int.
16:47
cbg folks!
Should be find now,.
cbg Dawg
just offered ma first bounty :)
cool
@InbarRose I get an inf loop when I get the PIN right
16:48
1
Q: How can I open two consoles from a single script

K DawGApart from the scripts own console (which does nothing) I want to open two consoles and print the variables con1 and con2 in different consoles, How can I achieve this. con1 = 'This is Console1' con2 = 'This is Console2' I've no idea how to achieve this and spent several hours trying to do so ...

@JebediahKerman Impossible with the code I sent you.
I am not home right now, no ide, every online interpreter sucks, will try it later, thanks @InbarRose @therest
>>> pin_correct(1234)
Please enter your 4 digit PIN.
You have 3 attempt(s) remaining.
1234
correct
True
No inf loop.
@KDawG I told you how to do that. Remember?
Nevermind. I have to go. Rhubarb everyone!
16:51
the last else: is paired with the while loop, correct?
@InbarRose yeah BTW still didn't provide a working example
did not know you could do that
@JebediahKerman :)
16:51
@InbarRose bye
A while statement is like an if statement that keeps calling itself until its false. Then it goes to else. Once you know that, it makes it much less scary to work with them.
rhubarb @Inbar
with statement?
gotta look that one up
While.. woops.
It's late :P
good night
16:53
@PaoloCasciello you up man?
yup @KDawG
where em working solution?
I'll write one for $200
i'm on linux. so i can only say that using pygtk is a viable solution to your question. in windows there's wxPython
Rep aint gonna buy me an xbox
16:56
@Kevin goto hell :P
i'll write 2 different solutions for a ps4 :D
Hey man, that's capitalism. Murica eagles and apple pie
Ya'll planning for CoD ghosts or GTA V?
gta v, under dogs and ac4 :D
just wait for the pc versions :P
17:00
agree :)
the only pc version i'm waiting is GTA.... at least if they do it >_< i played all of them from gta1... with my own mp3 in the car stereo :D
@PaoloCasciello seriously in case they don't do a pc release I'mma wage war on microsoft and sony :P
ahaha :D i agree :)
BTW @PaoloCasciello make sure you present a working example if you want some quick rep that is :D
................................................
gotta go, rhuarb all.......
Funny, it's usually the question answerers that demand a complete example from the asker, not the other way around
17:06
i'm not a rep whore :D
Who fancies helping us out for a few mins, just checking to see if stuff ties up on an SO post
after lunch perhaps, brb
@Kevin enjoy
17:25
Umm, odd:
[19591720 '2013-10-25/17:05:07' 'accept' 19592346 None]
[19591720 '2013-10-25/17:05:11' 'accept' 19592074 None]
[19591720 '2013-10-25/17:05:18' 'accept' 19592346 None]
[19591720 '2013-10-25/17:05:23' 'accept' 19592074 None]
Looks like the OP was indecisive for a few moments...
back
Which post are we checking?
One sec:
19596475
Against:
[19596475 '2013-10-25/18:55:09' 'answer-add' 19596490 None]
[19596475 '2013-10-25/18:55:24' 'post-edit' None None]
[19596475 '2013-10-25/18:55:52' 'answer-add' 19596499 None]
[19596499 '2013-10-25/18:56:04' 'post-edit' None None]
[19596499 '2013-10-25/18:56:49' 'post-edit' None None]
[19596475 '2013-10-25/18:57:26' 'comment-add' 29086425 None]
[19596499 '2013-10-25/18:58:26' 'post-edit' None None]
[19596499 '2013-10-25/19:00:04' 'post-edit' None None]
[19596499 '2013-10-25/19:00:41' 'post-edit' None None]
I've done a couple, and apart from the times being an hour different... they're pretty much okay
two answers, five comments, three upvotes for Martijn. All checks out.
Cool... I'm hoping with a Martijn answer it might also identify stuff like how many revisions a post has that don't get into the post revisions
3 revisions were recorded on the page but your log has like 10 xD
17:36
Yup - that's what I want to check I've got - revisions made that aren't recorded because o the grace period
@poke Hi (2nd) bestie
That's the question where the OP pulled the switcheroo on you, yes?
@Kevin Exactly.
@BadgerGirl I would prefer “1st 2nd bestie”.
Looks like the suggester wants to update your code to correspond with the OP's changes
I don't especially approve. I only edit code blocks that I myself wrote. It would be better if he had left a comment asking you to change it
Last time I edited someone else's code, I introduced a bug and briefly made him look bad :-x
17:46
Well, I have a disclaimer at the top describing why my code does not exactly fit the question in its current state :P

« first day (1116 days earlier)      last day (4057 days later) »