« first day (1497 days earlier)      last day (3450 days later) » 

8:02 PM
I get the left half                                                      and the right one too.
 
I never understood the phrase "have your cake and eat it too". If you eat the cake, you still have it. It's not going anywhere very fast, at least for a few hours.
If they mean "have" in the sense of "To partake of a particular substance (especially a food or drink)", then it's a tautology.
 
DSM
I think they mean "have" in the sense of "keep/possess". If I have one apple, and then eat it, and then someone asks me if I have an apple, it would be very strange to say "yes-- by which I mean I'm digesting one".
 
What if I have my cake in a secure remote location, and want to eat it too?
 
"The proverb literally means "you cannot both possess your cake and eat it", once it has been eaten, you no longer have it "you cannot eat the cake and keep it" or "you can't eat the cake and have it still"."
 
hmm, does a cake stop being a cake if you rearrange its component pieces by chewing it?
 
8:07 PM
Yes.
 
Put a cake in a blender and ask a bystander what it is. You're more likely to hear "brown slurry" than "cake"
 
@Kevin only if you turn the blender on before hand though...
 
Therefore, you can have your brown slurry and eat it too.
 
0
Q: converting .py to windows executable using cx-freeze

P_O_I_S_O_Nwhen i try convert .py to windows executable this type of error Warning: Can't read registry to find the necessary compiler setting Make sure that Python modules winreg, win32api or win32con are installed error: [Errno 2] No such file or directory: '/usr/lib/python3.4/distutils/command/wininst-6...

 
8:09 PM
@JonClements Good catch. This is why thought experiments should always be done in pairs.
 
@P_O_I_S_O_N hello to you too.
 
Oh come on client... phone up and confirm you want this email campaign to be sent... I wanna chill out...
 
I love the German term for thought experiment, gedankenexperiment
 
@P_O_I_S_O_N you've got your answer there in the first comment: cx_freeze doesn't cross-compile from linux to windows
 
Which is in fact Latin-German mixed term according to wiki
 
8:22 PM
good question, but it looks simple at first glance and attracted a ton of bad/wrong answers: stackoverflow.com/questions/27069448/…
 
The ones saying "you have to do sayHello()" seem to be missing the point
"everything in Python is defined at runtime" may or may not be true depending on your definition of "defined" and "runtime" and "everything", but in any case I don't think that's the root cause of the sayHellos being unequal.
 
there are now three answers saying the exact same thing, two of them basically copying what the first, +5 answer says
 
Incidentally, the OP's code produces False in both 2.7 and 3.X, so it's not something specifically related to 2.7's method wrapping weirdness.
 
yeah, I thought bound methods weren't a thing in py3, but I guess not
I removed the tag
 
The code doesn't have surprising behavior to me, in any case. If we change sayHello to return self.message, Then it makes sense that Person(message="hi").sayHello doesn't compare equal to Person(message="cbg").sayHello.
 
8:34 PM
I know something changed about methods in py3, but now I can't remember what it was.
 
@davidism the bound/unbound semantics
ahhh - the client's stuck in Stanstead Airport - but nice of him to phone and say he wouldn't be back for a couple of hours... sighs
 
The most prominent difference that comes to mind is, it no longer polices the type of self.
class Widget:
    def frob(x):
        print(x)

Widget.frob(Widget())
#python 2 output:
#<__main__.Widget object at ...>

#python 3 output:
#<__main__.Widget object at ...>

Widget.frob(23)
#python 2 output:
#Traceback (most recent call last):
#...
#TypeError: unbound method frob() must be called with Widget instance as first argument (got int instance instead)

#python 3 output:
#23
 
@Kevin what? self doesn't need to be the first argument to instance methods?
 
That's what my interpreter tells me
I wonder if 3.X's staticmethod decorator is just def staticmethod(f): return f
 
Actually, that doesn't seem very useful, it's basically static methods
 
8:46 PM
(dark magic hint: you can strip away the self protection in 2.7 with Widget.frob.__func__(23))
 
DSM
I think either Martijn (natch) or abarnert once gave a nice explanation of this.
 
We have rudimentary nidaba objects :o
 
Huzzah!
 
@Ffisegydd you know you don't have to make prs just to merge branches, right?
also good work :)
 
I couldn't find out where the merge button was, it only said PR
I assumed I'd be able to
 
8:53 PM
yeah, but you can just merge a branch into master on the command line, then push master
 
Ah right okay
 
github's ui kinda obscures all the other ways you can use git
 
I was looking for doing it on GH.
 
I'll have to write up how I use my sopython fork but don't produce a ton of commits/merges for features when I push to the main repo.
It's all about remotes, rebases, and merges
 
Sounds scary :P
 
8:56 PM
Took me a couple hours to work out a good flow, but now it's easy.
It is really painful to read about ORMs in other languages: woss.name/articles/representing-trees-in-postgresql
 
More commits means more work though, right?
We need over 9000.
 
<3 SQLAlchemy
 
@Ffisegydd Work is good for you.
dons Puritan hat with belt buckle
Leisure is the devil's tuning fork
(Puritans were not very good at metaphors)
 
9:14 PM
It annoys me that questions are in html format, rather than markdown, in the SE data dump/api
Though maybe it'll work out easier, as it'll be easier to find <code> tags etc
As opposed to checking for indentation and backticks.
 
was going to say it might provide more features for vowpal to pick up on
 
I retract my previous annoyance, now I've actually thought about things.
 
actually, I'm still going to say that
 
Sorry @Ffisegydd, had a crud evening. Only managed to get on now
 
No problem mate. These things happen.
I've been watching old episodes of Great British Bake Off.
 
9:18 PM
Avatar is a clip show this week :-|
 
So, are we keeping the upstream repos "clean"?
All tests passing and the like?
 
if even one test fails, ever, we must start the project from scratch
 
I haven't been, but davidism suggests we should. I think it shows how active and awesome we are to have 67 commits to add one test...but no. MORE STRIFE!
 
I agree that we should
 
9:22 PM
Yeah it makes sense.
 
Not that I couldn't get cracking on it.
Should keep upstream master clean, but any other upstrean branches are fair game?
 
Yeah I think if you branch you can have it as messy as you like, the idea is just when you merge it, it looks clean.
I'm currently looking for the easiest features to implement to call "dibs" on.
We can also think about having tox or such to test it upon push.
 
@Kevin somehow that doesn't seem completely appropriate
 
I actually meant Travis CI, not tox.
But yeah.
 
Yeah, was thinking about CI. I'm partial to Jenkins/Hudson
Trying to think of the best way to do language analysis without classifying with a large corpus
 
9:35 PM
vowpal wabbit does have the ability to add string features easily. You can just pass the string and the feature value (1 or 0 or whatever) and it auto hashes the string.
Then uses the hash as the "key"
I've seen some people literally split all their strings and just throw them all in :P
 
Hahaha awesome
 
10:05 PM
Hmm for some reason when I install nidaba using pip install -e . I can't find any of the subpackages
I can import nidaba but there's nothing in the package.
If I stick import core in the __init__.py then I can access nidaba.core, but that isn't normally necessary, right?
Can someone confirm or deny my sanity wrt the previous? Before I go to bed and dream about Python packages chasing me down an endless hallway.
 
10:24 PM
@Ffisegydd did you look for __all__?
 
@AirThomas __all__ only affects from nidaba import * no?
 
@Ffisegydd Off the top of my head... not sure. I am a sleep-deprived zombie today.
But I know that when you import MySQLdb you don't get MySQLdb.cursors
So I think it's "normal" behavior... depending on how the package is written
You're right, it's not __all__ because cursors is actually in there. Um. Hrm.
 
@Ffisegydd that's normal
 
Gah. I've reverted my changes in local trying to fix it. If anyone works out the answer, give me a ping. I'm gonna head to bed.
Ah nvm
@davidism really? I didn't realise you had to put the imports in.
 
you need to import whatever you want to access into the thing you're importing
right now, you're saying, "I have an empty python module, why can't I use my function from that other module"
 
10:31 PM
My issue was that they're sub-modules of each other, and so I assumed they'd actually be there.
But now I think about it, it's only the __init__.py that is actually ran when you import, right?
So if you don't put anything in the __init__.py then nothing will be there?
 
yeah, they're submodules, so you can establish a from x.y.z import a path, but the import path is not the same as attribute access
 
Hmm right, ok.
 
Looks like if you import anything at all from the subpackage in __init__.py, you'll have access to the whole subpackage. (?)
Yeah. I added an import of just one class from cursors to the main package's init file and suddenly had access to the whole subpackage by importing the main package.
 
rbrb, time for vacation (== work on sopython when I get home)
 
Yeah. ta @davidism and @Air
I'm off now too, I'll not be on tomorrow but will be pingable as I'll be at the computer.
 
10:37 PM
Delicious rhubarb to you both.
 

« first day (1497 days earlier)      last day (3450 days later) »