Hacker Newsnew | past | comments | ask | show | jobs | submit | more ryanseys's commentslogin

Alphabetical order seems pretty arbitrary and optimizing for the wrong thing in most cases.

The only reason as a dev you would really care about this is if you navigate / search code by scrolling until you find the function you care about. The invention of Ctrl+F makes this strategy of code navigation obsolete.

In my opinion ordering should be something along the lines of:

- initializer / constructors

- public functions from most commonly used to least common, with similar functions (perhaps with different inputs) being close to their relatives, and functions that call each other being close to each other

- deprecated public functions

- private functions following a similar ordering pattern to public ones, ordered by most used by the public functions to least used


I think doing secondary sorting within such sections might have a benefit. That’s what Java does for documentation (example: https://docs.oracle.com/javase/8/docs/api/java/util/Abstract...)

Going fully alphabetical is consistent with the go documentation, though (example: https://pkg.go.dev/bufio@go1.19.3)

A third option is what Rust does. Its documentation follows source code order (example: https://doc.rust-lang.org/std/vec/struct.Vec.html). I like that best, but it requires programmers to do more work.

Also, if alphabetical order is deemed the way to go, I would make this a formatter, not a linter.


> Going fully alphabetical is consistent with the go documentation, though

Nope, look how initializers are at the top of each section. That is not fully alphabetical at all.


The missing feature in an IDE to make this even better is to have LSP-aware regex tokens.

Let say something like /(?@<functionDef>)toErr/ that would match only the string "toErr" when it is in a function declaration/definition (decided by the LSP integration) rather than an invocation or a docstring


I'd love some shorter keywords here for searching so this was quickly composable into something useful.

E.g.

p: or f: instead of path: for filenames

l: instead of language:

-f: to exclude specific filenames (makes it easy to filter out tests)

You get the idea.


Great idea, ryanseys. Thanks for the suggestion. - GitHub PM


Then break the legion of builds in the name of security.


That seems along the lines of "I can just turn off the ability to log in to prevent account hacking!" level of security thinking.


If your choices are "disable all logins" or "anybody can log into my bank account and make whatever transfers they want", the correct choice is the former. (Obviously I would prefer a third option, where the company actually fixed the login bug sometime during the 104-day lead-up, but that's not the point.)


For some accounts you do exactly that if you have to.


What if we could have both, just by sending an email? Hit compose underlying!


But the 30% cut by Apple has been standard from the beginning. Why does that suddenly come into question once they have been successful? Serious question, I'm not an expert in antitrust laws.


It isn't the size of the cut that's the problem. Focusing on that is misdirection.

The problem is that Apple require vendors not to advertise, link to, or even mention that other payment methods are available outside of the walled garden.

That's the stunning uppercut. The size of the fee is merely a follow-up kick to the nuts.

No doubt Apple's PR team have been feeding Bloomberg background that pulls them towards only thinking about percentages, because "high prices bad" is an much easier story for lazy hacks to write than "Apple's T&Cs are distorting a marketplace and forcing vendors to mislead consumers", and much easier for Apple to leak about and subsequently respond to without addressing the core problem, especially when they're eventually forced to sit down and haggle with consumer/anti-trust regulators.


> Why does that suddenly come into question once they have been successful

Because people don't have a choice. If you want to build a successful software as a service offering in 2020, chances are you need to offer apps for it. Those apps have to be available for iOS and Android else they're dead on arrival, especially for iOS.

While Android lets you easily sideload apps (but even that is rarely enough as most users won't deal with that), iOS is a very strict walled garden. You have to play by the rules, and the rules are finicky and vague.

Like in the Hey mail saga, Apple's whim can make or break an entire business. That's not okay.


Depends what you mean. I'm a software engineer working on clinical study software and it makes sense to me. Though, I'm sure there are plenty of problem spaces that I don't work in whose jargon wouldn't make sense to me.

Here's a brief breakdown of the various terms though:

> trial execution

The act of running the clinical study.

> 21 CFR Part 11 compliant remote data collection

21 CFR Part 11 compliance is a set of standards that must be adhered to when running clinical studies. To be compliant means you meet these standards and people or businesses that want to run studies can be sure that you're following the rules.

> Telemedicine

Medical visits typically done over video chat / phone calls or other digital means as opposed to going physically somewhere to be tested or evaluated.

> Biostatistics

Data science + medical data

> Sample kits for at-home specimen collection

Like 23&Me but for collecting other stuff from people at their homes. E.g. stool samples, COVID-19 swabs, etc. You mail the participant a kit, they collect their sample, mail it back to you, you process the sample, and that informs the data in your study.

> Protocol writing

Writing and codifying the procedure of how the clinical study will be run. Covers everything from enrollment, inclusion / exclusion criteria for the study, study running, and study closing and archiving.


It's just a URL right? So could you not mirror the packages to your own server if you're so concerned, or better yet import from a local file? Nothing here seems to suggest that packages must be loaded from an external URL.


> or better yet import from a local file

And this is different from NPM how? Except that I've now lost all the tooling around NPM/Yarn.


It's different because it is much further removed from a centrally controlled dumpster fire. The JS, Node and NPM ecosystem is a pain on so many levels. Blindly trusting developers to follow semver by default. Leftpad. Build toolchains. The whole micro-depedency madness. Having a peek into your node_modules is like looking into the depths of hell.

Not saying Deno won't devolve into this sad state at some point. Maybe it already has. But it seems to try to combat some of the problems by being honest and pragmatic about dependencies, promoting minimal external tooling and removing some of the dangerous abstractions from NPM.

To me Deno seems like a desperately needed and well thought out reset button.

Semi-related rant over.


It's different because it doesn't rely on require() which is non-standard JavaScript.


Node v14 supports ESM modules and the import syntax, which is standard Javascript.


setTimeout is non-standard JavaScript too but I bet your code base has multiple instances of its usage.


Is it? It's on every browser I know.



Ah, makes sense, it's not part of the spec so it might be missing on other environments. Thank you.


Reminds me of John Oliver's coverage of AccuWeather. [0]

[0]: https://www.youtube.com/watch?v=qMGn9T37eR8


I was so about to mention that!


I will have to watch. I didn't realize this was all a thing


Nope.


Relevant xkcd: https://xkcd.com/605/


Disclaimer: FTE at Verily (Google Life Sciences)

Sounds like this isn't the first time this has happened and won't be the last. Both Compass (the firm that employs these cafeteria workers) and Google both have experience working with unions and are committed to working through this. Happy that these employees are getting the representation they deserve. I hope this means that these people will get better benefits that Google FTEs enjoy and stronger protections.

As a FTE at Verily (an Alphabet subsidiary), the management's priorities are very clearly not focused on challenging the status quo in these areas -- they are focused on running the "core business". I can only guess the sentiment is similar within Google.

I look forward to seeing this issue continue to get light and hope that business priorities evolve to incorporate the more humanistic aspects of running a business instead of simply focusing on the bottom line all the time.


> Google [has] experience working with unions and [is] committed to working through this.

My impression is that Google's experience is mostly in seemingly illegal union-busting (well, preventing) efforts. Then again, my impression is wholly based on reading HN articles on the topic, generally related only to engineers.

But I suppose they'll do what they're legally forced to do, more or less.


Or Google could just leave.

I hope they do.

Good riddance.


> Or they could just leave.

Who? Google or the employees


“Committed to working through this”

“Look forward to seeing the issue continue to get light”

“Business priorities evolve”

You didn’t say anything particularly disagreeable but I wonder if you realize how this kind of language comes across- this is the way people talk to you right before they fire you or take away your healthcare or something. This kind of business speak just screams, I’m someone who cannot be trusted. It’s the language of power. We all cringe and grimace when the boss talks like this. It’s why you’re getting downvoted, I’d guess.


Guess I've worked in the corporate machine for too long...

Thanks for keeping me in check. I didn't mean any harm from my comment but I can see where you're coming from, just wanted to give a summary of what the article seems to imply and a bit of perspective from the inside.

To me this whole thing feels like a complex issue with a lot of nuance, varying perspectives and information asymmetry, so downvotes don't surprise me.


> I look forward to seeing this issue continue to get light and hope that business priorities evolve to incorporate the more humanistic aspects of running a business instead of simply focusing on the bottom line all the time.

Do you really? Because the next step is automating the cafeteria.

When was the last time business priorities evolved to become more expensive?


The corporation can only do things like automate away the cafeteria if its employees let it. The point of a union is that workers - the people who do all the work and keep the profits rolling in - take back some control and decide things like this for themselves.

It's defeatist, and extremely unrealistic, to think we just have to roll over and let the bosses do whatever they want just because that's what we've always done up til now.

There's not some deterministic invisible power that says immiseration via automation is inevitable. It's just a matter of collective will as to whether we accept or reject power's desire to screw us over in that particular way.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: