HNHacker News
TopNewBestAskShowJobs

alexpopescu

434 karma · joined April 6, 2009

submissionscomments
alexpopescu··on VimSpeak
For everyone thinking this is a text-to-speech plugin for vim (boring): it is not. It's a voice controlled vim (quite cool).
alexpopescu··on Enable tab-completion in the interactive interpreter by default
I use a combination of all these 3 tricks as I have my dotfiles shared between Mac and Linux.

Basically my pythonstartup.py contains the extra check for os:

    AP_AUTOCOMPLETE=False
    import sys
    try:
        import readline
    except ImportError:
        print "Module readline unavailable"
    else:
      import rlcompleter
      readline.parse_and_bind("tab: complete")
      if sys.platform == 'darwin':
            readline.parse_and_bind("bind ^I rl_complete")
      AP_AUTOCOMPLETE=True
alexpopescu··on Setting up Sublime Text 2
It was only yesterday that I thought about using animated GIFs for demoing code typing. That's what I liked most about this post!
alexpopescu··on Immutable URLs
URIs are pretty much immutable. My impression is that what the OP suggests is a guaranteed lifetime of the content associated with the URI.

As for this second part, "once it's published it should always remain out there", I'm not very sure it's a good idea. In many cases I'd actually like to be able to say that a piece of content has expired (the content is not relevant anymore).

alexpopescu··on A Practical Intro to Data Science
I've recently seen this slidedeck [1] from guys on Twitter's data team where they say that most of the time the data mining process is basically:

1. Your boss says something vague

2. You think very hard on how to move the needle

3. Where’s the data?

4. What’s in this dataset?

5. What’s all the f#$#$ crap in the data?

6. Clean the data

7. Run some off-the-shelf data mining algorithm

8. ...

9. Productionize, act on the insight

10. Rinse, repeat

[1] http://www.slideshare.net/Hadoop_Summit/scaling-big-data-min...

alexpopescu··on The Rule of Awesome
Yeah, I'm pretty sure timely and imposed awesomeness is exactly what is needed.
alexpopescu··on The San Francisco Safety Net
> It's expensive,

Even if we like it or not, the rent is ridiculously expensive.

(someone new to SF that will probably never get used to the peeing in the streets)

alexpopescu··on The San Francisco Safety Net
A couple of places, please.
alexpopescu··on Google Keep – Save what’s on your mind
Is this sort of an announcement that Google failed to buy Evernote, so they decided to create a project that does exactly the same things and that will be discontinued after a while because it's not Google's focus?
alexpopescu··on IBM Selectric Typewriter
I always wondered if back in the days of typewriters there was a similar conversation going as there's today about keyboards.

Where there the IBM, Apple 2, Das keyboard fans?

alexpopescu··on A Tip That Will Help You Learn To Code 10x Faster
I find the "advice" in the post a bit confusing. Finding an answer on SO or a forum or a book will help you solve a specific problem (thus making you a "productive" coder). But I seriously doubt it will make you code faster in general if this "code snippet copy & paste coding" is not expanded into understanding so next time the search part is removed from the process.

In the early days, it always took me a lot more time to get from finding an answer to using that answer in my code. The main reason is that I didn't want to just copy paste something without understanding it. On the other hand, a more experienced colleague of mine was sifting through books and forums and pushing code a lot faster. I talked to him trying to understand what I'm doing wrong. As I've learned (actually both of us learned), the only difference was the existing knowledge each of us had about the environment and the app. Over time I got to be a lot faster at finding an answer and moving along, but that came only with becoming more familiar with the tools/lang/etc and being able to understand things faster.

alexpopescu··on RethinkDB 1.4 is out: better protocol, drivers, data explorer history
There's no decision made on this yet. So far, as @coffeemug explained in the previous comment we decided to focus all our efforts on improving the server and getting it closer to "production ready" state, instead of spreading our resources thin and creating a lot of drivers that are not as good as we'd want them to be. The initial protobuf spec was complicated and building drivers on top of it would have required a lot of effort (effort that we thought would be better used to improve the spec and the query language, things that everyone would benefit).
alexpopescu··on RethinkDB 1.4 is out: better protocol, drivers, data explorer history
Still not, but the new protobuf spec (and rewritten existing drivers) should actually make it pretty easy to get one. I've also heard of a couple of people working on Java and Scala drivers (they were following the new protobuf spec branch), but I don't know the status.

alex @ rethinkdb

alexpopescu··on Automate Your Life: Sending Emails
As far as I checked, today is 2013...
alexpopescu··on Code Reads
I also heard that they can see in the dark thus you can cut the light when you leave them in the office.

On the other hand, I've seen it in the movies that they can disappear... I assume that's what they do before someone can actually try to run their code.

alexpopescu··on Update from the CEO
Wait... where is this post saying what's going on with Andy Rubin? Let me understand: you have a guy that leads one of the most adopted projects coming out of Google and then you announce a new person to lead that project without mentioning anything about the former? That should be an awesome feeling for everyone at G...
alexpopescu··on Node v0.10.0 (Stable)
How is this any different to the status of other projects in other environments?
alexpopescu··on A Brief Intro to Profiling in Python
I don't think that using a client side generated id is actually a real step in optimizing. Except the case you block all writes to the db.
alexpopescu··on The Case for a True Mac Pro Successor
My comments about Xcode were uninformed, based only on the fact that I don't run into tons of complains about it. The only time I fired Xcode to compile a project, it took me quite a bit of time to figure out where it places the compiled files. But I categorized that as "I'm a newbie. I don't know where to look"
alexpopescu··on The Case for a True Mac Pro Successor
Years ago (but not as long as tolmasky's "exclusive"), I would have given everything to get a Mac (I was living in a place where Apple's product were neither available nor affordable).

I spend most of my time on my computer programming (or at least I did this until very recently).

What I've noticed in the last 2 years is that except maybe the Xcode environment, Apple has started to ignore every other dev environments. People have been working a lot on keeping things going (Fink, MacPort, homebrew), but by the day my feeling is that Apple doesn't care at all about this.

Basically the target audience shifted from geeks to mass audience (click to buy this app, watch a movie on this great display, etc.) and AppStore developers. Business-wise it's clear they can ignore the small segment of developers. Karma-wise I'm not convinced that's wise.

alexpopescu··on Fixing Database Connections in Django
"I'm not a Django person"

1. Using PGBouncer seems to be the ideal solution, but I'm not sure other databases actually provide a proxy. I haven't heard of something like this for MySQL (a) I might be wrong, please provide a link, b) I'm know some will say "just don't use MySQL")

This aside, I would expect a connection pool implementation to support at least the following:

1. min: minimum number of connections

2. max: maximum number of connections

3. idleTime: time interval after which idle connections are automatically closed

4. connection cleanup (most often done when returned to the pool). Basically making sure that the connection object is pristine

If it doesn't do all these, then it's probably not something you'd want to use.

alexpopescu··on Zero Todo ~ Todo workflow for inbox zeroists.
Email can be a good todo... inbox. But a todo inbox is completely different to a todo list (which has deadlines, priorities, dependencies, etc.)
alexpopescu··on Open Source And Responsibility
I probably fall in the category of those that think that authors of open source projects do have a responsibility for the code they share and its maintenance.

The main reason I'm saying this is that I feel that the open source world is not an infinite dump area where everyone just throws out code of any quality (in many cases just for having something to add on the 2nd page of a résumé).

This is not to say that authors are required to implement additional features or support a piece of code forever. But trying to deliver as much as the original "promise" of the project and making it clear what's the status of the project is the responsibility of the author. Browse GitHub and tell me how many projects are marked as "defunct" or "abandoned" or "unmaintained". (maybe Github should automatically do this...)

alexpopescu··on Please stop saying your software supports Python if it's only V2
Not long ago I've tried to find out what are the most popular versions of Python available.

I've started by asking people heavily involved in the Python world. Statistically irrelevant, but the majority of answers I've got back were:

1. production systems: 2.7.x

2. old maintenance mode: 2.6

3. some 3.x

I've also tried asking the PSF, hoping that they might have more data. They pointed out to the download page:

> "The current production versions are Python 2.7.3 and Python 3.3.0"

A statistically relevant survey would need to take in consideration:

1. what major Linux distributions include as the default Python version

2. what versions hosting providers support by default

3. the percentage of Python libraries that work with Python 2.7 and Python 3.3

A lot of effort would be needed to pull together all these details, but I think the Python community would benefit from having this data around (even if some might find this detrimental to the advance of Python)

alexpopescu··on Try RethinkDB in your browser
I don't have a similarly stylish and philosophical story as coffeemug's but the thing that changed the way I perceive criticism is something I've read a while back: before coming up with any answers or remarks, ask 3 questions about the original thing. Agreed these 3 questions shouldn't be: 1) WTF? 2) who is he to criticize? 3) should I bother?)
alexpopescu··on Try RethinkDB in your browser
The main difference is what happens if you chain together multiple operations. Are these executed one by one (each resulting in a roundtrip to the database) or executed all at once (single roundtrip to the db).

As a side note, each programming language has its own idioms. We tried to bring the ReQL query to each language in a way that felt as close as possible to the host PL (as opposed to say SQL which you need to use it as it is; and that led to the hundreds or thousands of wrapper libraries/ORMs. etc).

alex @ rethinkdb

alexpopescu··on Try RethinkDB in your browser
Both solutions are lazy. While ReQL requires .run(), the Django ORM requires you to do 'list()' (or probably other form of iterator over it). I'd say the only difference is that one is explicit and the other one is implicit.
alexpopescu··on Try RethinkDB in your browser
I appreciate your feedback. Really really helpful to us (you should see what it triggered on #irc ;-)
alexpopescu··on Try RethinkDB in your browser
Probably this is only "semantics", but I find these two quite similar :). I like the idea of having the query being executed only when needed, but I'm not sure that's always possible (or optimal with large result sets).

thanks,

alex @ rethinkdb

alexpopescu··on Try RethinkDB in your browser
> Especially .run() feels a bit weird, can you make queries lazy (like Django's QuerySets, which only run when evaluated)?

In a way queries are lazy. You can write a query and without calling `run` on it nothing happens. The whole chained ops are executed at once when `run` is called.

> That said, it is also my opinion that the ORM syntax needs a bit of love, for all the reasons stated above.

This is not an "ORM" per se. It's a query API or data manipulation language. The next version will bring a few improvements to it.

← PreviousPage 2 of 6Next →