21,281 karma · joined Nov 23, 2012 (14y ago) · 6,748 submissions
blog: https://rtpg.co
email: raphael at above domain
comment 9y ago · link · parent
Before you could always call a third-party rendering library, but it usually meant you wouldn't get things like the Django context renderers or template file lookup by default
comment 9y ago · link · parent
If you want to add a custom action to the instance view of one of your models you have to:
- write a view for your custom action
- override the generated urls for the model admin
- override the template(???) for the admin instance view to show the action
Considering the Admin itself already has the styling in place to add more custom actions, the main issue is that no one has put in place enough infrastructure to make this easier for people.
(Internally we've written a couple helpers for this, though our way of doing thing relies on internal patterns so might not be great for Django itself)
comment 9y ago · link · parent
If it's 20% of Chicago but has 50-100x the national per capita average, that's pretty crazy. If it's one house where everyone in the house was murdered (1 murder per capita!), well it's not really representative of much.
comment 9y ago · link · parent
Also "200 million Americans don't even live in areas with bad stats" is another way of saying "100 million Americans live in areas with high murder rates"... seems like a larger issue than you're implying
comment 9y ago · link · parent
There's a lot of competition for this skillset, so you have to keep on giving more to the engineers... but then they have a bunch of money and they have less lock-in for the job. When you have $20 million in a bank account, why are you going to go make a powerpoint for your manager?
But if you give them "options" that might be worth nothing... well why not just go to Uber with their millions of Actual Real Cash(TM)? Or why accept "founder" salaries instead of real salaries?
Not that there's anything wrong with this, but the classic employer/employee relationship starts falling apart when the employees end up being this value.
comment 9y ago · link · parent
Maybe "lazy" is the best word, but moving from Android's classic "grant permissions on install" to "prompt for permission" is a major change that they spent a long time working on (I think Android 4 already had a lot of the backend for this?).
It's not like it was secretly granting permissions to apps, and you could always choose to not install something that took too many permissions.
You could say they made the wrong choice, but we're a long way from "this binary can do everything on your files" model of Unices/Windows
comment 9y ago · link · parent
There's a spectrum of danger that a lot of us have had the privilege to not experience. I could imagine getting mugged in some places in Europe, but not really imagine dying in the "mugging gone wrong => someone is dead" scenario you hear about in the US.
And of course the idea that I might get killed in a traffic stop is something I have the privilege to not experience.
comment 9y ago · link · parent
There's noticable lag when switching keyboards that seem endemic in the model of "multiple app keyboards", whereas a more integrated experience would benefit some
Agreed that the "Play Store" model is better for consumers on phones that don't get updates (been there). I hope they try to pull stuff into the core project as well, though. Kinda sad to see Android becoming what people always thought it would end up (a Google-centric venture)
comment 9y ago · link · parent
Building busted stuff in the middle of NYC hurts everyone, because there's limited space.
Visionaries can build where other people don't want to be, or convince the people around them that what they want to do is a good idea.
comment 9y ago · link · parent
I suppose that this is more "Python (the language) for other systems" more than "Python (the environment) for other systems". Is any of the standard library supported given this import scenario?
comment 9y ago · link · parent
No disrespect ot the work, but I'm always a bit worried about a thing that starts with "we're swapping out the Python interpreter for a compiler". For example, this doesn't include generator support, which is a big part of my Python usage.
"Just" having the CPython bridge is so tempting, because your python code will work (modulo C extensions), plus we get all the performance work too. I believe you tried this, of course.
For VOC, is there a guide to calling Java code from Python code? I see you have Toga, but being able to write my own abstractions without much work would be neat.
comment 9y ago · link · parent
there's more operational complexity, because now you're running two things instead of one. But there's also less complexity in other areas, because parts of your code are firewalled off from each other, so you have a smaller problem space when making changes/fixing bugs.
I think that there's a tendency to view things that are harder to set up initially as more complex, when the long-term complexity might be lower. It mainly depends on what you think is important.
I think a lot of the difference in viewing complexity is due to difference in foundational knowledge. People doing Haskell see monads for DSLs as nice and easy abstraction, but people outside see it as a crutch, needed because of a lack of native effects in the language.
Some people see Javascript toolchains as needlessly complex, others see people using Javascript instead of <some compile to JS language with better abstractions> as needlessly complex.
Differentiating between what kind of complexity is brought is important. Because a team of people bad at operations shouldn't be rolling out a new service every week. But a team good at operations but bad at separation of concerns might gain a lot from being "forced" to chunk things out.
comment 9y ago · link · parent
So I remember hearing that a difficulty with hooking Python to Android is that there's some sort of limit to the amount of Java methods you can access through the JNI, but I could never find a proper explanation of this.
If I just had a version of CPython compiled on Android, given Java's nature of running on a virtual machine, wouldn't it be possible to dynamically load arbitrary classes through the JNI and use the native Android stuff?
What are the primary difficulties to this, if you ignore performance?
comment 9y ago · link · parent
I think $10 a day is reasonable if you're moving around. It's a bit more than a movie ticket, and if you rent in the morning you get a full day's usage.
Though to be honest I don't know many US cities that would be fun on a bike...
comment 9y ago · link · parent
Meanwhile you have things like ad campaigns that have "unlimited" budgets. Hell, there's tripling staff size in a year without some matching revenue growth!
Chairs don't kill startups.
comment 9y ago · link · parent
There's documented evidence of intent here. The guy was trying to give their victim a seizure. There's nothing accidental here.
Of course if someone accidentally gave someone else a seizure, there should be different standards applied. Of course!
Also, yes, we need to make sure photosensitive people can browse more safely (for the same reason we put airbags in cars).
The book you throw at them isn't "giving someone a seizure", it's "attempting to harm someone intentionally with super malicious intent".
comment 9y ago · link · parent
Imagine someone running up to someone with epilepsy in public and showing them strobes? What sort of deranged person does that?
Imagine someone sending death threats through snail mail over and over. Of course that's horrific! But brigaders doing it through twitter is kinda fine because "hey, you're on twitter, stupid stuff happens".
So much harassement is extremely cruel but we (myself included) tend to discount it when it happens over social media.
comment 9y ago · link · parent
JAL/ANA have very new planes with cool entertainment systems, but they also fly their older planes on some routes with a bunch of stuff that looks like it's powered by VCR.
To your question: they probably don't for their major international flights.
comment 9y ago · link · parent
Of course AirBnB could forward the money to the host but doing it they way they do cuts out the problem entirely.
comment 9y ago · link · parent
I've found that for smaller commits, if you have something long you want to explain in the commit message body... you should probably put it in a code comment!
If you don't think it merits a code comment, it's probably not important enough for people to look up the commit message body either (if only because the commit message body is less likely to be seen).