6,699 karma · joined Jul 18, 2012 (14y ago) · 1,967 submissions
Backend-focused full-stack engineer with 8+ years of experience, mostly focused on Go, Rust, and TypeScript, but open to other options.
Resume: https://drive.google.com/file/d/1VNC272B3n7ZEfppMHkm2wGgaINwYl4Av/view
comment 5y ago · link · parent
Go has proven that a good package manager can work without that feature. You say that feature is something the C++ Committee could never tackle. My whole statement has been "fine, learn from Go!" Instead, you keep harping on this nice-to-have feature and saying it can't be done.
Package management is solvable in a way that suits C++. It seems inevitable that standardized package management will eventually happen for C++.
I understand your perspective now, but I just don't think I agree with it.
comment 5y ago · link · parent
Your edit implies that I'm talking about a useless tool that can't do anything in the absence of Google, which simply isn't true.
The Go Modules tooling does not depend on any central resource to work. Google could shut down tomorrow, and nothing would change for existing projects. The go CLI tools would still be able to find, download, and verify the dependencies. I would still be able to add new dependencies, and the tooling would be able to fetch those.
What are you talking about, if not a functional package management system? Google's websites are nice, but they're not required for everything to Just Work.
Anyone in the C++ community could stand those websites up at any time after the package management tooling came into existence. They're not required for the functionality of the package manager.
> It's relevant if the particular person wondering "why C++ doesn't have a package manager?!?" uses a mental of model of how npm and cargo work. They don't have to know if it's github vs gitlab vs somewhere else. The tool just works without thinking about the location. That's what a canonical repo as a default convention for the client tool provides.
Go's CLI tooling literally doesn't provide any way to search for packages at all. You may think it's a requirement, but it's really not! Go requires you to know where the dependency is located, because Go sure doesn't unless you tell it!
It feels like I'm really awful at explaining things.
comment 5y ago · link · parent
Literally no one is required to do any of that. That is the answer. Plain and simple.
> I think the disagreement is rooted in how we compare ISO C++ committee vs Google Inc. To me, releasing a C++20 language specification* does not say anything about implementing a canonical repo* so that a command line tool magically works the way people expect.
But I'm saying that's not how Go works at all. The dependencies are hosted on GitHub, GitLab, or wherever else.
There is no central package repo. There is no "canonical repo".
Package discovery tools are not very relevant to the discussion. You can have a package manager without having a discovery tool or a central repo. Searching GitHub to find a C++ package, then adding that repo as a dependency of your current project seems like it would be entirely reasonable, if C++ had a standard package manager that worked. Some community members might build a website to help you find popular packages... but that discovery tool doesn't interact directly with the packages at all.
proxy.golang.org is a proxy. No one publishes packages to it, and you don't have to use that proxy. You can use no proxy at all, which was the default once upon a time, or your company can host a proxy, or you can potentially find some random third party proxy online. The proxy isn't where packages are hosted -- it's just a means of accelerating downloads, if GitHub were slow, for example.
C++ code is hosted in a myriad of locations. The Go approach is to specify the GitHub repository that you're depending on, and that repo will be cloned by the package manager in your terminal. The `go.sum` file contains hashsums to verify that the dependency you downloaded is untampered with since the last time you fetched it, and those hashes can also be used by any proxy that happens to be used.
Go's package management system is truly distributed. It isn't centralized at all. Yet it still supports SemVer, downloading the correct, exact version of a dependency, checking the integrity of dependencies, recursively collecting dependencies of your dependencies, etc. All the features you would expect out of a package manager.
Unlike Cargo in Rust, someone can delete one of these repos from GitHub and cause a real mess. `go mod vendor` is an option for anyone who prefers to vendor their dependencies.
Google has certainly provided some nice web tooling around the Go Modules system, but none of it is integral to the type of package manager that I'm proposing would suit the C++ dependency model. Go's package manager is very distinct from what you were discussing with Cargo, NPM, and others. It's much more attuned to the problems that C++ faces, and it walked a similar path to what C++ will inevitably have to do.
comment 5y ago · link · parent
You’re moving the goalposts, and complaints about discussions of Rust tend to be far more annoying than the actual discussions. How dare people want to discuss related languages they enjoy? I mean, right?
Most language discussions will have people join in and discuss other languages.
I’ve spent quite a few words in this very thread discussing Go’s package manager! Should I apologize to someone? No... I think language discussions normally involve discussions of languages.
comment 5y ago · link · parent
But you keep coming back to this idea of how Rust has to fit your workflow perfectly and you’re unwilling to make any changes to have things work better with Rust...
If you’re unwilling to change anything at all, then it’s laughable to imply that you would use an entirely different programming language for anything, even if it fits your workflow exactly.
So, I just don’t see the purpose of this discussion. You’re basically saying that you’re not going to use Rust, no matter what Rust does or does not do. That’s neat?
comment 5y ago · link · parent
If they want to reproduce their workflow using Rust, cargo allows vendoring and many other solutions.
comment 5y ago · link · parent
That is the role of the ISO C++ committee, is it not? They are the major stakeholders. They would just have to care enough. They cared enough to release C++20, didn't they? It's not like they never get anything done, which seems to be the implication a lot of people make in this discussion.
> Instead of a top down decision it's a negotiation between the various actors.
My understanding is that the various committee members represent the disparate interests of the broader C++ community. I agree it would be very much like a negotiation.
That doesn't mean that it can't be done. This whole thread is discussing things that have been done by the C++ committee: C++20.
> But the last thing we need is for the C++ standards committee to standardize a package manager. That would take forever to do, would result in a messy tool that tries to compromise with all the actors in some ways, make it very hard and slow to evolve over time and would likely result in a lot of pain, etc.
You just summarized my feelings about C++ in general. I would much rather people use Rust or Go or any number of other languages instead of C++, depending on project needs. Such opinions are rarely taken well in threads like this, though, so...
I've been trying to be optimistic and point out that C++ could get package management. If the C++ committee process works well, then the package manager should also end up turning out well.
I'll leave the reader to decide how well they think the long term direction and guidance of the C++ standard has been going and apply that to their feelings of a hypothetical future package manager.
comment 5y ago · link · parent
No. I'm not talking about either of those. Your whole comment is, unfortunately, irrelevant.
pkg.go.dev is not a package repo. It's just a place for documentation to be rendered. It renders documentation from third party hosted code, such as on GitHub or elsewhere.
"go get" predates Go Modules, which is the current package management system. The whole original design of "go get" was to simply download code from somewhere on the internet, and place it in the right spot of the $GOPATH. This has nothing to do with a proper versioned package manager like Go Modules.
AFAIK, "go get" was also never really designed for Google's internal use cases. They use a monorepo that was perfectly content with $GOPATH, and all their code was developed in the monorepo to begin with. There was nothing for them to "go get", except for the rare outside dependency that they were embedding into their monorepo, I would imagine. I've never worked for Google, these are just things I hear about.
Go Modules was also not designed for Google. It was designed for the community, based on findings from community developed package managers for Go. Google has no real use for it — again, they use a monorepo.
Nowadays, "go get" can be used with Go modules, but in practice, it feels like it almost never is. Maybe someone would use that command to upgrade an existing dependency, instead of editing the `go.mod` file to change the version there?
So, your comment just shows that you haven't researched this enough. Yes, Go Modules was still guided by Googlers, who were even more in control of the language direction back then than they are now. Yes, change always causes some drama. But, I'm not really here to explain the history of Go package management...
I'm just saying that C++ could have a nice, distributed package management system, it would just require the major stakeholders to all care and work together on it. The ISO C++ language committee is a finite number of people. They are the major stakeholders, as far as the language direction is concerned.
If they didn't have the power to enact major language changes, we wouldn't be here talking about C++20.
The stakeholders for Go were able to develop a package manager that is distributed (an idea compatible with how all C++ code is scattered across the web these days), and that achieved broad adoption, and this was some years after the language went into wide use.
It’s an extremely relevant analogue for C++ to study, if the committee members wanted a package manager badly enough.
> But it's easier to care if there was an influential C++ behemoth that captured everyone's mindshare to move the entire ecosystem forward. C++ has no such "industry leader" that dictates (or heavily influences) technical direction from the top down.
You edited this in while I was replying, but I agree entirely. Getting the committee to agree to a package management solution would be much more difficult than having a single behemoth guide the decision. Does that mean it is impossible and therefore no one could do it? Everyone here talks like it is impossible, but it doesn't really seem to be.
comment 5y ago · link · parent
But, to your question, no. Where would the submodules even point? The dependency source code artifacts are stored "immutably" (except for takedown notices or extreme abuse cases) on https://crates.io. They aren't git repos, and there's nowhere for git to point.
comment 5y ago · link · parent
comment 5y ago · link · parent
Go's package manager also came years after the language became widely used, and it is now very widely adopted according to the most recent survey[0].
I think C++ could have a good, unified package management story. It would just require the major stakeholders to all care enough to make it happen, which seems to be the missing piece here.
comment 5y ago · link · parent
comment 5y ago · link · parent
I think it's specific to Access Points, so not a general purpose centralized controller for MikroTik equipment, but... centralizing access point management seems to be the main thing under discussion here.
comment 5y ago · link · parent
Glancing at articles from when this Waymo product was originally announced a couple of years ago, I saw some equally unhelpful speculation of “no more than 50 feet.”
If it was 500 meters, surely they would say, because that would be really good.
comment 5y ago · link · parent
Really disagree. Loading a few megabytes of kernel would take way less than a second even on microSD. eMMC can be noticeably faster, yet you’re still saying it takes 6 seconds on your eMMC BeagleBoard.
Hardware initialization takes time.
Can it be faster? Probably, but you haven’t provided a compelling example by referencing the BeagleBoard being one second faster.
7.7 seconds isn’t mind blowing, but it’s not crawling. It’s more than adequate here.
If they optimize it more in the future... cool.
If you want open systems, the upcoming RISC-V SBC revolution seems likely to be much friendlier than Broadcom, but the Pi is already more open than most ARM platforms, in my opinion.
comment 5y ago · link · parent
I just measured, and my M1 MacBook Air takes 32 seconds to boot to the unlock screen, and then a further 8 seconds after the password is entered before it reaches the desktop. As I'm sure you're aware, the M1 processor is no slouch, and Apple includes an NVMe SSD with respectable (though not mind blowing) performance in this laptop.
comment 5y ago · link · parent
Swift is the only one on that list that really feels tied to any particular platform.
C# has been extremely portable for years now thanks to .NET Core. Even SQL Server runs on Linux these days, if you really just enjoy spending money.
Java has always had a strong focus on portability, of course.
Nim... I don't know much about. Doesn't it compile to C? I don't think it intentionally has any particular platform affinity, although I wouldn't be surprised if it worked best on Linux.
comment 5y ago · link · parent
The M:N scheduler is great, and the ability to easily spin off Goroutines is really nice, but I think most people shouldn't need to manually launch goroutines most of the time. Goroutines should just be an implementation detail.
comment 5y ago · link · parent
The rest of your points I’ve already addressed. More thunderbolt ports is actually bad for most users if it comes at the expense of ports they can actually use without a dongle. The build quality is not really any better... I’ve owned both as well, and I’ve also had a work MacBook Pro 15 with the butterfly keyboard. Until recently, Mac keyboards were the worst in the industry, including reliability. Now they’re decent, but nothing to write home about. Definitely not an advantage. Trackpads are what you make of them... Apple certainly makes good ones, but it’s not 2010 anymore. Every mid-to-high end laptop I’ve used in the last 5 years has had a good trackpad, but I still reach for a mouse even on my Macs.
I already addressed the display as well. It’s a trade off. Apple doesn’t offer high refresh rate displays on their laptops, which matter to some people. If they didn’t matter, Apple wouldn’t put them on their iPad Pro.
System76 used to offer 4K displays (optionally matte) on the Oryx Pro, and mine was exceptionally good! And that’s higher resolution than Apple uses, in addition to the wonderful matte effect cutting down on glare. I’m just guessing the massive ongoing part shortage has affected which displays they can actually acquire for the moment.
So yes, I agree you get different things with a Mac, but those things are unlikely to be worth 50% more to most people, with the exception of macOS itself... and that’s only valuable to people who like macOS or are literally required to use macOS.
> in general, statements about the price inflation are overblown. It exists but it's not as bad as many people think.
I started this conversation by pointing out the price inflation I care about the most: storage, and it’s on the order of a 400% markup. It’s extremely awful.
If Apple would be environmentally friendly and allow people to repair and upgrade their computers, we wouldn’t even be having this discussion, because I’d have a 1TB SSD in my MacBook Air, and it would have cost me $100. If Apple would charge a healthy 100% profit margin, I would probably have paid them for the SSD... I’m just not willing to go to 400% markup.
Apple has basically always charged egregious upgrade prices, it didn’t start when they started soldering things down, so the small number of people like myself who would actually upgrade components should not be considered a threat to their profit margins... but even if most people did it, Apple should allow it because it’s the right thing to do long term, even if it impacts short term profits. Instead, they seem to be optimizing their products to eek out every last percentage point of profit. Which is understandable... it is a company, but it would be nice if they didn’t. They already have hundreds of billions of dollars of cash.
comment 5y ago · link · parent
Since we’re on the topic of System76, a fully upgraded Oryx Pro (except leaving the GPU at the base option) costs about half of what a fully upgraded 16” MBP costs (also leaving the GPU at the base option), while offering similar specs — $3158 vs $6000. The System76 chooses to go for a 144Hz panel instead of a HiDPI panel, but different people value different things. The System76 obviously has a better port selection (for most people), while obviously not being as sleek — but it’s not huge either, it’s reasonably thin and light. It’s more durable while not as shiny. It’s easy for people to pull out the “no true Scotsman” defense at this point, but it all depends on what the customer is looking for. It’s Apple’s fault if they don’t offer enough variety to meet the needs of their customers.
I’m sure I could dig into comparative analysis of other OEMs vs Apple and come up with other examples, but this one is easy enough.
Spec for spec, Apple charges much more than twice as much for many important upgrades... so a sufficiently upgraded Apple laptop can be more than twice as much, even if it’s often “only” a 70% markup or something. That doesn’t excuse charging egregious prices for storage. Customers want storage, and Apple withholds it unless customers want to pay a large ransom. They solder the SSDs so that customers cannot upgrade their own computers.
I own an M1 MacBook Air. I’m not some “Apple hater”, but their upgrade pricing is truly appalling, and for all their talk of environmental friendliness, their attempts to thwart aftermarket repair and upgrades significantly hinders the total potential lifetime of their products, which increases their environmental impact relative to what could be.
I bought the 256GB/16GB model, and that 256GB SSD is borderline too small for me to deal with, and I’m not even like an average user that would be attempting to store music and pictures on it. I’m almost exclusively using it for software dev and web browsing. I would swap out the SSD, but... that’s obviously not possible.
If I can’t make the 256GB of storage work long term, I think I would rather sell this thing and buy something else than give Apple $0.52/GB. The M1 is good... but it’s not priceless. My opinions are subject to change, of course.
comment 5y ago · link · parent
Retail prices already include higher profit margins than bulk order prices would include, which makes this markup even more egregious.
I calculated it the other day, and Apple is charging $0.52/GB for SSDs on their M1 MacBook Air.
Samsung's 980 Pro is under $0.20/GB for the 1TB model on Amazon right now. That is arguably one of the best SSDs on the market right now, and I'm fairly sure Samsung' 980 Pro is actually significantly better than the internal SSD that Apple is using on the M1 MacBook Air.
That means Apple is charging a 160% markup above retail price, minimum.
The Western Digital SN550 1TB PCIe SSD is priced at about $0.10/GB at retail on Amazon, which means Apple is charging over a 400% markup relative to the retail prices of that perfectly good SSD. Most users would not be able to tell the difference between the SN550 and the internal SSDs Apple is currently using.
I recognize that other OEMs can sometimes charge steep upgrade markups too... but Apple's prices for storage are personally annoying to me because the M1 MacBook Air seems reasonably priced until you get into the upgrades. I wanted to get more storage, but I'm not going to pay $0.52/GB for additional storage these days... I just don't find it reasonable.
comment 5y ago · link · parent
In general, the more rural an area is, the lower the cost of living. Rural college towns are more likely to have an abundance of cheap apartments than the average rural area.
However, it's all highly relative. San Francisco and NYC are the two most expensive locations in the United States. By comparison, everywhere else is cheaper. Lots of major US metro areas are extremely affordable by comparison, and $120k could probably last a frugal person for 2 or 3 years near those locations especially if living with roommates... so you don't have to live in the middle of nowhere to be somewhere affordable. Compared to a lot of places outside the US, even the affordable parts of the US probably seem expensive, but my limited understanding is that most of Western Europe is relatively expensive... so probably not too different from the US in many places, but definitely outside my area of expertise.