Lurker News
Yet somehow https://www.githubstatus.com is ALL GREEN! smh

Comments (272) 60 threads

Show all comments

Showing thread 1 of 60

xfbs10 replies#
It's amazing how much stuff breaks when GitHub goes down. I'm doing some Rust coding right now, the rust-s3 crate tells me that to look up what feature I need to enable (tokio + rustls), I need to look into the Cargo.toml. Well, the repo won't load, and nor can I clone it. Well okay, fuck that I can use the default dependencies. But no wait I can't, I can't even do a cargo build because cargo uses a github repository as the source of truth for all crates. No more Rust for me today :(
revskill3 replies#
I guess same story for Go!
krasin2 replies#
In Go, it's customary to use 'go mod vendor' to put your dependencies into the main repository. While it's not universally recognized as a good technique, it saves the adopters of this approach from the downtime today.
jen204 replies#
I’m not sure this is customary at all - I rarely encounter a vendor directory anymore.

Note you also need to build differently if you go this route: `-mod=vendor`, otherwise the directory will be ignored in modern Go.

Continue this thread — 4 replies

avl999#
These days with go mod and the go team maintaining their proxy there is very little benefit to vendoring and any benefit is not worth blowingup up the size of your repos and messing up code reviews on PRs that introduce new dependencies.
ggktk1 reply#
I think Go dependencies should still work, thanks to Google's module mirror[0] (enabled by default), which has cache.

[0]: https://proxy.golang.org/

ra7#
The ones using GOPROXY=direct will fail, although it’s used rarely.
jlouis#
Go uses a proxy for downloading modules, so there's no Github involved. And you could run your own proxy-cache if you wanted. In addition, your work machine has a local proxy cache of the modules you already downloaded.

Go doesn't use a repository as a single source either, which is another problem in of itself.

pasabagi2 replies#
Cargo has an --offline option. It's actually pretty possible to use rust totally offline - the doccumentation can be built, for instance, then locally served with (iirc) cargo doc.
jiggawatts1 reply#
Offline should be the default, not an option.

Otherwise nobody will notice how fragile their workflow is until it is too late to fix it!

Aeolun#
I recently realized I was the only person running the API locally when suddenly all our unmocked tests started failing only on my machine.

All other tests, including the ones on the CI server, were connecting to the hosted integration environment for any unmocked call (and thus randomly modifying state there).

xfbs1 reply#
I build and host documentation on every commit anyways in the CI. And yes, that is true, I eventually figured it out (had some issues with it at first) but it seems like GitHub is back up so all's well anyhow. I do however wish that there was some public mirror that cargo could fall back to, wouldn't that make a lot of sense?
still_grokking#
It would be good if such things would be hosted decentralized on something like say IPFS.
birktj1 reply#
You can view the source of a crate on docs.rs (see [1] for the Cargo.toml of rust-s3). Also I am pretty sure cargo only depends on GitHub for authentication for uploading crates and not for the actual contents. Trying to build an empty crate with rust-s3 as a dependency right now seems to work fine.

[1]: https://docs.rs/crate/rust-s3/0.28.0/source/Cargo.toml

ATsch#
As I understand it, the crates themselves are not stored on github, but the crate index is, as it uses a git repo to get "free" delta compression and auditing.
anothernewdude2 replies#
I can't stand builds that just reach out to the internet for things.
lanstin1 reply#
Yeah seems like basic hygiene especially given the supply chain attacks but also a lost cause. No one has the skills to do builds without the internet. Even forcing teams to use an allow list for the internet involving fighting a lot of angry people.
contingencies#
One of the few decent uses for containers is to enforce proxied internet so build process artifacts can be auto-stored for subsequent builds.

For the worst offender I am aware of, try building a flutter project... it silent internet gets artifacts from at least three different packaging systems (node, cocoapods, android packages), all of which have caused hard-to-debug failures.

duped2 replies#
How do you build software in 2021 then? Do you write everything from scratch?
spoils191 reply#
... yes? I've often been ridiculed for wanting to build everything in-house, but events like these just validate that sometimes, to get the most reliable and best software, you'll have to reinvent the wheel a few times.

Continue this thread — 1 reply

still_grokking1 reply#
One can use the packages provided by the distribution. That's how it worked since forever for things like C/C++.

For example distris like Debian even mandate that you build software for them only relying on things that are already packaged. No arbitrary internet downloads allowed during build. The build environment contains only what is provided by the stated build-dependencies of your package, which are themself of course Debian packages, and some common minimal build base (like shell and some utils).

duped4 replies#
What if the package you want isn't provided by the distribution?

What if the distribution's version doesn't support the features you need?
What if it can't be built by relying only on things that are already packaged?
How do you distribute your software so it runs on other distributions? Do you maintain a different build for each package manager?
What if you want to run on platforms that don't have standard package managers, like MacOS or Windows?
How do you update the packages without internet downloads during provisioning the build?
The C/C++ model has proven to be fatally flawed. It hasn't worked, that's why modern languages eschew reliance on the distributions' package managers, and greenfield C/C++ projects use the same model.
I'd go so far as to say this model is a key reason why we need containerization to deploy modern software today - since you can't trust software written on distro X runs on distro Y because it packages dependency Z differently all the way up to the root of the dependency tree (glibc, usually).
The fundamental flaw of this model is that it inverts the dependency tree. Build time dependencies are local to individual projects and need to be handled separately from all other software. With few exceptions, Linux distros make this mistake and it's why we can't rely on distro package management for new projects.

Continue this thread — 4 replies

etra01 reply#
Beside the `--offline`, you can also use `--vendor` to include all the dependencies in a folder to be committed alongside your project. Useful when you don't want to rely on external fetch every time!
jiggawatts1 reply#
Both should be the default.

Rust has a robust memory model, but everything else about it insists on copying the fragility of the NPM ecosystem.
The recent hoopla around a bunch of Rust mods quitting revealed that my suspicions are precisely true — key Rust staff also sit on the NPM board!

pclmulqdq2 replies#
Cargo is the one thing keeping me off the rust ecosystem. The fundamentals of the language are great, but the tight coupling of the rust language with cargo's package management really irks me - it introduces as many correctness and security problems as the memory model solves.

Continue this thread — 2 replies

dandotway20 replies#
In the 1970s-80s we managed with email lists and tarballs on multiple mirrors. Git itself decentralizes source control, and yet we all want to use single-point-of-failure Github.

Anyone remember when Github took down youtube-dl?
I wonder how much Big Brother data Microsoft is gathering on Github developers. "Oh, as part of our hiring process, just like we scan your FB and Twitter, we also scan your Github activity to evaluate your performance as best as our machine learning overlords can assess it. Do you create Github projects and then abandon them when unfixed issues accumulate? Our algorithm thinks you're a bad hire."

Continue this thread — 20 replies

Continue this thread — 4 more replies