Julien Danjou
julien.danjou.info · Personal blog · on HN since 2010
Julien Danjou, a Python developer and open source contributor, writes about Python performance, profiling, Lua, and tech in Europe.
What HN saysHN commenters cite his posts on Python atomic counters, his Lua critique, and Europe's cloud problem, and list him among notable Python bloggers.
81HN people shared it
19linked it in comments
74stories submitted
509story points
3 months agolast shared
2010people per year2026
Most-shared posts
- 1Rant about Github pull-request workflow implementation6 people · 10 points · first shared 2013 · discussion on HN
- 2Why not Lua4 people · 84 points · first shared 2011 · 43 comments on HN
- 3Why not Lua4 people · 7 points · first shared 2012 · discussion on HN
- 4Emacs gets Google Maps support.3 people · 85 points · first shared 2010 · 17 comments on HN
- 5Thoughts and rambling on the X protocol3 people · 14 points · first shared 2010 · 1 comments on HN
- 6Python bad practice, a concrete case3 people · 6 points · first shared 2014 · discussion on HN
- 7High-Performance in Python with Zero-Copy and the Buffer Protocol3 people · 5 points · first shared 2019 · discussion on HN
- 8Profiling Python using cProfile: a concrete case3 people · 3 points · first shared 2015 · discussion on HN
- 9Emacs rainbow-mode3 people · 1 points · first shared 2010 · discussion on HN
- 10Dependencies Handling in Python2 people · 4 points · first shared 2019 · discussion on HN
- 11Europe's Cloud Problem Isn't the Tech. It's the Mindset2 people · 4 points · first shared 2026 · discussion on HN
- 12Bad practices in FLOSS project management2 people · 4 points · first shared 2016 · discussion on HN
- 13Python's single dispatch, a step towards Common Lisp's generic functions2 people · 4 points · first shared 2013 · discussion on HN
- 14Twenty Years of Stacking Commits2 people · 4 points · first shared 2026 · discussion on HN
- 15The Hacker's Guide to Python released2 people · 2 points · first shared 2014 · discussion on HN
What HN people wrote when they linked it
babarock · 2013-08-04
I'm a huge fan of Github. I recognize the huge effect they've had, transforming the Open Source community, and I'm grateful for it. I also love how they run their company, how open and talkative they are about their organization. Their blog holds many gems.
However, I cannot work on Github. In my opinion, the Pull-Request mechanism is weak because it fails to address a major point: It's highly improbable that I accept the PR on the first try. There's going to be a lot of back and forth discussion, reviews, remarks, etc.
Standard PRs I deal with on Github usually end up with several redundant commits. When I ask people politely to rebase all the commits they're sending into one, most don't know how to do it. (It's okay not to know. It's weird when someone with several contributions per day never had to do it before). If I `git commit --amend`, my PR is actually overwritten and I lose the history of the first patch I've sent.
I started disliking working with Github ever since I started working on OpenStack. The process to send a patch there might seem a bit daunting at first, but it's really not that complicated. Using Gerrit (https://code.google.com/p/gerrit/) for code review has many advantage, like limiting your patch to one commit, keeping a detailed log history of successive patch sets, and generally making reviewing more inviting. On top of that, the whole suite of tests is ran against each submitted patch in a virtually never resting CI server.
And finally, I don't…
znpy · 2026-06-30
the issue with EU companies is often the mindset: https://julien.danjou.info/blog/europes-cloud-problem-isnt-the-tech/
As tech worked who has worked in US FAANGs (still in europe)... the difference is immense.
EU companies simply can't compete and will never be able to compete until they change the mindset. And the change must be pervasive, across all aspects (including IC compensation).
miohtama · 2022-02-21
In the Python VM there is no atomic increment bytecode. So `counter += 1` should be exactly same as `counter = counter + 1`.
Here is an example what thread safe increment looks like in Python:
https://julien.danjou.info/atomic-lock-free-counters-in-python/
You need to lock it explicitly.
Note that `INC` instructor for x86 architecture needs explicit hints/locks as well, so this should suprise anyone:
https://stackoverflow.com/q/10109679
mrsmn · 2017-01-30
David Beazley : http://www.dabeaz.com/
Kenneth Reitz : https://www.kennethreitz.org/
Armin Ronacher : http://lucumr.pocoo.org/
Julien Danjou : https://julien.danjou.info/
Hynek Schlawack : https://hynek.me/
Donald Stufft : https://caremad.io/
SeanDav · 2016-02-23
What is your one-size-fits-all-possible-use-cases scripting language they should all use instead?
Lua? Counterpoint: https://julien.danjou.info/blog/2011/why-not-lua
Any scripting language will have issues. It is far easier to reason about and deal with issues created by your own DSL than some other 3rd party language that you have minimal or no control over.
deng · 2014-11-25
Yes, the pre-commit workflow is also why I won't use it. I want to review branches, not patches. With branches though, there's another problem which AFAIK no code review tool can manage, with the sole exception of Gerrit: force pushes. While you might recoil, I think force pushes are often an entirely reasonable thing to do on a feature branch which is not yet merged into mainline, especially when cosmetic stuff gets fixed, like trailing whitespace, hanging braces or whatever the reviewer did not like. You really don't need that kind of history in mainline. See also this comment w.r.t. to GitHub's inability to deal with force pushes, to which I entirely agree:
https://julien.danjou.info/blog/2013/rant-about-github-pull-request-wo…
icebraining · 2012-12-16
Well, I've been enjoying Joey Hess' build log of git-annex assistant [1], and I like Julien Danjou's [2] too, even though he writes more about Emacs, while I'm a VIM user.
Then there's Old New Thing, LtU and John Resig's blog, but those are less obscure.
[1]: http://git-annex.branchable.com/design/assistant/blog/
[2]: http://julien.danjou.info/blog/
JoshTriplett · 2012-02-01
For a different perspective, take a look at http://julien.danjou.info/blog/2011/why-not-lua (submitted to HN as http://news.ycombinator.com/item?id=3536131 ).
shabble · 2011-12-28
Going pretty far off topic here, but you might enjoy rainbow-mode: http://julien.danjou.info/software/rainbow-mode as a partial alternative (although it's more a preview than a picker)
sciurus · 2011-08-12
You may be interested in git-annex.
http://julien.danjou.info/blog/2011.html#Handling_my_music_collection_…
flocial · 2011-08-12
git annex might be of interest to some:
http://git-annex.branchable.com/
http://julien.danjou.info/blog/2011.html#Handling_my_music_collection_…
silentbicycle · 2011-04-14
Well, Emacs is very much "a day to learn, a lifetime to master". I've been using it for years, have led sessions teaching other developers, and just yesterday I discovered rainbow-mode (http://julien.danjou.info/rainbow-mode.html). Before that, it was magit and halp.
thristian · 2010-12-22
Interesting that XCB is now included in the release, despite complaints about it being abandoned:
http://julien.danjou.info/blog/2010.html#Thoughts_and_rambling_on_the_…
naner · 2010-06-29
That rainbow mode also looks useful.
http://julien.danjou.info/rainbow-mode.html
cookiecaper · 2019-10-16
Thank you for sending me on a trip down memory lane. :) Still can't believe that most of this stuff is from +/- 10 years ago. Getting old is weird.
Julien Danjou, original awesomewm author, ruminates on the X11 saga and the resistance to XCB in [0], dated 2010-06-01.
While that post expresses the bleak outlook for X11 and the Freedesktop project in general, it seems the real clincher about the freeze on awesomewm comes from a LWN article from November 2011 [1], which quotes Julien thus:
"The missing parts are advanced stuff like new XInput and multi-touch support, but we were blocked by XCB for those, and users seem to be able to live without them. Now, since everyone seems really happy with the 3.4 branch, I think it's enough that we just keep maintaining it."
Taken together, my interpretation at the time -- and I think the general community consensus -- was that the hours and days spent rebuilding cairo to enable the XCB backend and then rebuilding anything that depended on it, which was (is?) basically every substantial Gtk application, were not going to get any easier.
Venturing into the comments on that article and seeing the links to issues with users pleading for distro packagers to enable XCB out of the box brings the old days flooding right back.
[0] https://julien.danjou.info/thoughts-and-rambling-on-the-x-protocol
[1] https://lwn.net/Articles/467559/
sdegutis · 2014-09-30
Yes, there is a difference between embedding and extending. Extending means your app is just a module that lives in the language's interpreter. Embedding means the language interpreter lives in your app.
One advocate[-1] of extending prefers it simply because he got bitten by his own poor design.
Another advocate[undefined] prefers it simply because he prefers JavaScript and the easiest way to embed it is to write your app as C plugins that hook into V8[NaN].
The Python community[2] will unfailingly tell you to choose extending over embedding, delegating their reasoning to this highly questionable rant[2].
[-1]: https://julien.danjou.info/blog/2011/why-not-lua
[undefined]: Zhivago in ##c on freenode; please go say hi to him and make sure 2 use abbvs and dont use punctatng or spell thngs rite b4 him
[NaN]: http://stackoverflow.com/questions/6334618/experience-embedding-javasc…
[2]: aka #python on freenode
[2]: http://twistedmatrix.com/users/glyph/rant/extendit.html
freshhawk · 2013-07-11
"doing this in the terminal requires a crazy number of steps"
"Switching contexts from your browser into your terminal."
"you can simply make the change right there without leaving your browser, saving you time and maintaining your zen-like frame of mind"
Sending a pull request for a typo in someone else's project is way faster using the github web editor, no question, but for everything else?
I'm in a terminal or, most likely, my editor way more often than I'm in the browser and for any non-trivial change it's way faster to use git in the terminal or fugitive (vim-git integration) than the web interface.
Once you have to use the proprietary pull request functionality to send that change it changes the balance a bit but that's just saying that Github's vendor lock-in strategy that forces you to use the Github site makes it faster to use the Github site than both the site and the git command. Not a bragging point, just a reminder that I should be nervous about Github having gotten as far as "embrace" and "extend" in the microsoft playbook even though I really like Github.
http://www.wired.com/wiredenterprise/2012/05/torvalds_github/
http://julien.danjou.info/blog/2013/rant-about-github-pull-request-wor…
iso-8859-1 · 2013-03-04
http://askubuntu.com/a/11877/19466 :
X has two drawing APIs. One of these is a part of the core X11 protocol, which is ancient, useless, and nobody uses. The other is the XRender extension which provides modern composite operations, among other things such as gradients. This is what Cairo, for example, uses. X also has font drawing APIs.
http://julien.danjou.info/blog/2010/thoughts-and-rambling-on-the-X-pro… :
The X11 protocol (without extensions) defines about 120 types of requests: create a window, move a window, etc.
Nowadays, there's at least 25 % of them which are useless: usage of server-side font, or the drawing of squares and polygon, are unused by any modern application or toolkit. All of this is superseded by requests from extensions, like the XRender one.
The handling of multiple monitors displays has totally been screwed up. X11 has been designed to work in Zaphod mode (independent monitors). But Xinerama, and nowadays XRandR have replaced it up: recent X servers (released after ~2007) does not support Zaphod mode anymore, even if it's a core piece of the X11 protocol.
The_Amp_Walrus · 2020-11-05
I'm working with some researches on about ~40k lines of Python disease modelling code and these are the things that helped us becomes more productive:
- tests (unit, smoke, acceptance) (eg. https://mattsegal.dev/alternate-test-styles.html, https://understandlegacycode.com/approval-tests/)
- continuous integration (via GitHub actions eg: https://mattsegal.dev/pytest-on-github-actions.html)
- 10x performance improvements via cProfile (https://julien.danjou.info/guide-to-python-profiling-cprofile-concrete…
- getting fast feedback on code changes by visualizing outputs with Streamlit (https://www.streamlit.io/)
- input parameter validation (eg. https://pydantic-docs.helpmanual.io/, https://mattsegal.dev/cerberus-config-validation.html)
- total automation of data processing job (eg. https://www.prefect.io/ - we don't use this but that's the kind of thing we have)