Better HN
topnewbestaskshowjobs
Log inSign up

rtpg

21,278 karma · joined Nov 23, 2012 (14y ago) · 6,746 submissions

real name: Raphael

blog: https://rtpg.co

email: raphael at above domain

Submissions

comment 3y ago · link · parent

TS's type system is fun but a part of me always wonders how much faster TS's compiler would be if it was written in a compiled language (assuming "good implementation", which is a big assumption!)

comment 3y ago · link · parent

"you can drink outside but you can't go home afterwards until you're not drunk" seems wild to me, but maybe I'm misunderstanding how the center works.

comment 3y ago · link · parent

The adage is that you can either moderate a community or you can be a very active participant in the community, but really you shouldn't be both.

Thank your local admins.

comment 3y ago · link · parent

I am assuming here that the ISP is who would get in trouble for not sending the money to the locality, not the N individual customers. I'm also assuming that if I sent my ISP money for the internet cost, minus the passthrough costs, the ISP would act as if I owe them money.

I get what you're saying about the fee being for the consumer. It's just like... OK then, well tell the consumer how much they are going to pay. You mentioned that the lobbying is to get rid of these locality's taxes, and I'm not pro-federalism so hey why not.

But all of these places have to collect the money anyways, so there is _a_ logic to how much to charge. Many places in the world, the price of internet is "type your zip code into a box and then we tell you". This seems eminently reasonable. This precludes a nationwide campaign to say exactly how much the service costs (unless ISPs just decided to eat the costs themselves!). But wouldn't it be good for people to know how much something costs?

comment 3y ago · link · parent

> The FCC order said the requirement to list "all charges that providers impose at their discretion" is meant to help broadband users "understand which charges are part of the provider's rate structure, and which derive from government assessments or programs." These fees must have "simple, accurate, [and] easy-to-understand name[s]," the FCC order said.

The point is that the fees are charged to the ISPs, and then the ISPs want to pass it onto the consumer but not actually say that that's what is going on.

Yes, some localities will charge more things. Hell, listing them out would add pressure to make these fees go away! The FCC isn't the one imposing these fees. But ISPs are choosing to charge the users, but also not advertising these fees ahead of time! Advertising "this service costs X" but actually costing X + Y is something that feels pretty unambiguously bad.

Then again the US is the land of "every locality sets its own sales tax" so....

comment 3y ago · link · parent

So what happens is that you have the one query that runs for a specific page and fetches the data and the relevant fields? I could definitely see that working for many projects, at least while your objects don't have too many tiny little details to pull out of thhe DB

comment 3y ago · link · parent

Yeah I can understand wanting to split out the ORM model from a separate class that holds data. I just think absolving oneself of an ORM or query builder entirely for a DB schema that doesn't (glibly) fit on a postcard feels like a good way to generate a lot of busy work.

I somewhat disagree about your point on caching. If you're working with models (that, namely, are 1:1 with DB rows) stale object problems are a reality no matter what, and having the ID be put into a pure data object generates the same issues. But these are things that are not very interesting to discuss outside of specific contexts.

I am a bit of a functional programming nerd, but I've just found that for Python stuff in particular, swimming upstream is its own bug generator relative to writing concise stuff in a very imperative fashion. Using the fat models directly is a part of that calculus for me, but YMMV and every team has different strengths.

comment 3y ago · link · parent

If you're going to end up querying all the fields and putting them into a model like this dataclass anyways... Django can do that for you. If you're going to later pick and choose what fields you query on the first load, and defer other data til later.... Django can do that for you. If you're going to have some foreign relations you want to easily query.... Django can do that for you. If you're doing a bunch of joins and are using some custom postgres extensions for certain fields and filtering... Django can help you organize the integration code cleanly.

I totally understand people having issues with Django's ORM due to the query laziness making performance tricky to reason about (since an expression might or might not trigger a query depending on the context). In some specialized cases there are some real performance hits from the model creation. But Django is very good at avoiding weird SQL issues, does a lot of things correctly the first time around, and also includes wonderful things like a migration layer.

You might have a database that is _really_ unamenable to something like an ORM (like if most of your tables don't have ID rows), but I wonder how much of the wisdom around ORMs is due to people being burned by half-baked ORMs over the years.

I am curious as to what a larger codebase with "just SQL queries all over" ends up looking like. I have to imagine they all end up with some (granted, specialized) query builder pattern. But I think my bias is influenced by always working on software where there are just so many columns per table that it would be way too much busywork to not use something.

comment 3y ago · link · parent

I 100% agree and did this at a previous job. It would be cool to have devcontainer support be a bit more ubiquitous in IDEs

comment 3y ago · link · parent

It’s just annoying? Especially if you have access to everything, at one point just having a monorepo makes git “actually work”.

comment 3y ago · link · parent

I mean a devcontainer is just docker with some extra stuff to run VSCodes stuff inside the container.

comment 3y ago · link · parent

And for everyone who has these problems and aren't, like, people who need access to Photoshop, it's "native performance" on Linux cuz there's no VM layer.

It could be that the VSCode remote container stuff also gets around this problem somewhat by working "in container", effectively opting out of the Mac->Docker FS stack issues (especially with file watching....).

The fact that we have an enumerable number of tools that write files and somehow ended up with a bunch of stuff built on file watching instead of signaling to a build daemon on file save/checkout is... It feels cleaner but in practice is a mess of downstream problems.

comment 3y ago · link · parent

In the real world, localities are routinely using Line or Twitter to send information to inhabitants. This is maybe on top of some paper fliers or announcements on loudspeakers.

I don't know what this looks like in other countries, but we're talking about telling people about something, not updating your registered address.

comment 3y ago · link · parent

Japan is Twitters second biggest market.

comment 3y ago · link · parent

I do wonder how much sharing could be done at a project level for libraries. Would it be possible to have at least debug builds with matching compilation settings be compiled down into a shared place?

comment 3y ago · link · parent

The CPython source is really a bit of a joy to look through. The lowest level stuff is really tough, but generally it's all relatively straightforward.

Though with the specializing compiler work, some stuff is... less obvious. But I still generally find it straightforward when I want to know some detail about how the language works.

comment 3y ago · link · parent

This isn't _that_ relevant because China is there as an option but there are no flights direct from Japan to Russia, for the same reason there aren't EU to Russia flights right now either.

comment 3y ago · link · parent

I would probably put a trait implementatoin on Value that does `.invert_bool`, and have that panic. That way eval is just `eval(m).invert_bool()` and if it panics it panics.

What you really probably want is to make this a Result type-returning thing, and then have have `not` be a function of type Value -> Result<Value,ErrType>, and then you can do not(eval(m)) and panic at the top-level.

comment 3y ago · link · parent

> For starters, fewer industries need unions these days. Unions don't help most office-work and white-collar careers, where pay is on-average sufficient or high, and hours are standardized already (nobody in Accounting or HR is working 12 hour days on the routine).

I routinely hear about people doing super long hours in loads of industries. Sit-down jobs. Hell, loads of people in IT get put through the wringer.

> Additionally, in some sectors, unions are a net-negative. Take software for example, where folks routinely make bananas money for regular work. In those environments, unions typically protect unproductive peers, and limit high-performer's maximum compensation.

Would you rather make the obscene amount of money or work with a bunch of people who aren't permanently stressed out from internal rat races? How many stories about people getting chewed up at places like Amazon do we need to hear about?

> As an aside, people do need to learn to say no to work. Just because you want to work on say, video games or VFX doesn't mean you should accept a job that compels you to work horrendous hours for little pay. Just say no and move on... the market forces will correct and adjust accordingly out of necessity.

Unions and labor action can make all of this happen on a way smoother time scale, and without squeezing half a generation of people dry. Why sit around and wait for a bunch of companies to collapse, people to go jobless, when you could instead coordinate efforts, figure out what people want, and move towards that in a coordinated way?

There's nuance, but employers negotiate as a bloc (in that even a single company has its own overall policies), having employees do the same just feels like common sense.

A bit of an aside: I do think it's important to look at what actual union agreements look like. Places like Netflix got better deals when they were smaller. Unions often end up with tiered payments anyways. Agreements get made over multi-year periods offering a good amount of stability. The idea that a union forces everyone to get paid the same and for a strike to be inevitable the instant the kind bars disappear from the break room is prevelant, but the reality is much more nuanced (partly because people usually just want to do work and get paid and do what they want to do).

comment 3y ago · link · parent

I think there's a combo of "I like doing this work", maybe not fully grokking a residual structure, and ultimately feeling like all of the work is contractor base.

It's kind of like how everyone in games was so underpaid, but since everyone was like that you just kind of accept that as the status quo (especially if you're just out of college and don't even really grok that you can't live on a ramen budget forever)

comment 3y ago · link · parent

yep, I've gotten loads of phishing SMSs regarding missed deliveries using duckdns.

comment 3y ago · link · parent

Ah that's a good point. I had a similar experience with moving services (to a smaller scale).

comment 3y ago · link · parent

I mean the "real thing" is 3D Secure, which isn't exactly 2FA and card issuer dependent, but makes things a hell of a lot more of a PITA to execute for fraudsters.

comment 3y ago · link · parent

How much of a problem is this outside the US? In Japan I get maybe 1 call like this a month (always from a "weird" area code). Meanwhile everyone in the US seems to be constantly getting these calls. Surely other countries also have marks!

(I know about the scam calls to old people in Japan being a thing. Having a cell phone probably removes me as a mark)

1
535455
225