7 ms·
Ha! “ a safeguard to prevent misuse of our system in a way that might impact the stability and safety of the system." Google: We have identified modern web de
by bigiain 4y ago
Ha!
“ a safeguard to prevent misuse of our system in a way that might impact the stability and safety of the system."
Google: We have identified modern web development as a threat to our systems, and have taken measures to ensure npm users cannot store their npm_modules directories on GoogleDrive. Please consider rewriting your nodejs projects in Go.
- kube-system 4y agoWhy do people put their NPM modules in google drive?
- drusepth 4y agoThere's a surprisingly large number of groups of people that use Google Drive, Dropbox, and similar for "source control" and/or collaboration on projects instead of real VCS.
- lazide 4y agoThat seems really illadvised.
- nickphx 4y agoeveryone is differently abled.
- bigiain 4y agoCynical view, a lot about npm seems really ill advised. One additional bad decision after that choice seems easy enough to go along with… ;-)
- tomjen3 4y agoA lot of it is. And yet, it works so well it conquered the world.
- bigiain 4y agoSo did Mc Donald’s and Starbucks. I’m not entirely happy with the idea of living in a world conquered by the lowest common denominator solutions.
- listenallyall 4y agoGet over yourself. McDonald's is far from "lowest common denominator." Go travel the world a bit and see how real people live and what they actually eat every day.
- wincy 4y agoWe had a drive thru grass fed burger place open up across the street from McDonald’s and it was gross. It lasted maybe a year. McDonald’s makes pretty good burgers, not what I want every day for sure but in a pinch they aren’t bad.
- throwaway50601 4y agoSpeak for yourself, I find it great. Much better than the alternatives like pip or nuget. And the ecosystem has endless amount of solutions ready.
- heleninboodler 4y agoAnd I love big macs, but they may not actually be a good thing.
- throwaway50601 4y agoIn this case it is a good thing. And as I said, still much better than the alternatives.
- yjftsjthsd-h 4y agoWhat do you think npm does better than pip?
- bigiain 4y agoI have worked with colleagues who expect to be able to keep their current work in Dropbox/GoogleDrive, so they don’t need to take their work laptop home every day but still have easy access to their current work from home. “Hey, why can’t I get Dropbox to work on this laptop? I need it so can do emergency bug fixes from my personal laptop at home!” “Yeah, nah. Remember that security policy you signed as part of your employment contract? The one that says exfiltrating company or client data or code to non corporate systems is a fireable offence?”
- lenkite 4y agoGoogle Drive many-times IS the enterprise approved cloud storage/sharing solution.
- justeleblanc 4y agoWriting the files to your home hdd, even using the approved solution, is exflitration of data.
- bigiain 4y agoI want to say that the sort of place that had GDrive as their "approved cloud solution" is unlikely to also be the sort of place that has the sort of data the required firing-offence rules for exfiltration to non company systems, but I know that's not the world we actually live in... I'm reminded that Lastpass got popped via an employee running a well out of date version of Plex with known RCE exploits and getting a keylogger installed: “This was accomplished by targeting the DevOps engineer’s home computer and exploiting a vulnerable third-party media software package, which enabled remote code execution capability and allowed the threat actor to implant keylogger malware,” LastPass officials wrote. “The threat actor was able to capture the employee’s master password as it was entered, after the employee authenticated with MFA, and gain access to the DevOps engineer’s LastPass corporate vault.” The hacked DevOps engineer was one of only four LastPass employees with access to the corporate vault. I mean, I know exactly why. But why the fuck was the corporate Lasspass vault available to a staff member's home machine running Plex? Is the expense of a corporate vpn-locked laptop and a pair of Yubi keys too much for a fucking _Password Vault_ senior developer??? "Should we spend a couple of grand buying a work laptop for this guy who literally has the keys to our kingdom? Or do we save a few bucks and get him to work on the machine he already owns, the same one he runs outdated media server software and probably bittorrents all his porn with? What could possibly go wrong?"
- bdcravens 4y agoI don't do that, but I was once bitten by iCloud. I always put my code in ~/code and copy it over when I get a new machine. I once had the idea to just put it in ~/Documents/code, thinking it'd be automatically synced. Turns out that iCloud doesn't sync dotfiles.
- brycewray 4y agohttps://stackoverflow.com/questions/35853139/can-git-and-icloud-drive-be-effectively-used-together https://stackoverflow.com/questions/35853139/can-git-and-icl...
- cableshaft 4y agoI use Git for version control but for some of my personal projects I also have a copy in Dropbox, so I can make changes on my laptop downstairs, not be ready to commit it, save it, go upstairs, and continue work from my desktop pretty much seamlessly. Some of my projects aren't set up this way, and it can get annoying to have made a few small changes and be forced to commit them in order to pull them from upstairs.
- deleted 4y ago[deleted]
- thunderbong 4y agoThe reason this happens is Google Drive is marketed as a backup solution, so people add their work folders to it which consists of all these files.
- Takennickname 4y agowouldn't package.json be enough?
- codetrotter 4y agoThey probably have a folder that auto syncs with Google Drive https://support.google.com/drive/answer/10838124?hl=en https://support.google.com/drive/answer/10838124?hl=en Same way that Dropbox works So they are not manually choosing what to sync, they just put all of the work and other files they want to automatically sync inside of that folder. This ends up including things like node modules and things like that
- NoZebra120vClip 4y agoI don't sync folders. I mount my accounts as network drives. As for corruption or overwriting files, I have rarely encountered issues, but Drive has file revision histories as well as a Trash can, so if you notice the problem and it's not spread over 5M files, you can roll back to last-known-good versions.
- codetrotter 4y ago> I don't sync folders. I mount my accounts as network drives. Implementation-wise under the hood is it really much different? In my simplistic, probably overly naive idea it seems that a “network drive” built on top of Google Drive would still cache the files in memory, and improper shutdown or loss of network access could still leave your files in an inconsistent state. Probably they have a lot of advanced logic on top, that could roll back partial updates, or keep track of things so that the updates are not applied before sync is complete. But anyways from this point of view sync vs network mounted drive feels like sync is a kind of network mounted drive that flushes to local disk in addition to working with the remote. One of these days I want to build such things from scratch myself so that I can experience first-hand the horrors that lie underneath sync / network disk service setups modelled on my idea of Dropbox / Google Drive etc
- tomjen3 4y agoIf I was teaching anybody programming I would teach them to copy the folder over every time they added a new feature, rather than teach them git at the same time. With some C++ libraries or node_modules that can run up fast.
- q7xvh97o2pDhNrh 4y agoWhat? Why would you teach someone to do things the wrong way?
- renewiltord 4y agoI must apologize. We have purposely trained them wrong. As a joke.
- Xylakant 4y agoYou can’t teach all of the things at the same time. People will just freak out, be confused and learn nothing. There’s a lot of the things that you’ll teach “wrong” at the beginning. You’ll never talk about CI/CD at that stage, deployment, packaging, etc. either, despite a lot of this being a requirement for a lot of software engineering projects.
- jbverschoor 4y agoWhy would you have nodemodules in every project? It shouldn’t be a local directory anyway
- ikiris 4y agoThey’re probably a math teacher and want them to learn about punch cards before introducing complex concepts like a floppy disk.
- Brian_K_White 4y agoIt's not teaching them the wrong way. It's teaching them a simple version of the right way. You can't do everything at once and git is counter-productive on day one, and the most important thing was they find programming remotely interesting at all. The next most important thing is always working on a new copy. How exactly you make those new copies barely matters at all compared to just having them at all. Using something arcane and unforgiving and inscrutable and complex like git to accomplish those copies is way way down on the list. The new student is barely interested in the actual coding to make a game if you're lucky. They would rather mow lawns than learn administriva like git. It could even be argued as irresponsible to hand git to babies and expect everything to be fine. Just because we all have about 5 git commands we use 99.9% of the time, and have no problem 99% of the time because we learned how to "hold it right" and just always carefully do things in the right order, does not mean git can actually be made safe and simple. Those 5 or so commands aren't actually enough.
- kbumsik 4y agoI mean, why not? I use both git and Dropbox, because I have multiple devices to sync: laptops, a desktop, and linux servers. If you use a desktop and a laptop back and forth, git is quite inconvenient. You don't need to commit and push from the desktop to switch to the laptop with a folder level realtime sync solution. Also, git only protects files that are staged, but Dropbox can restore any files to any point of file event (not periodic snapshot, but it keeps all file events). So combining both you are safe from any kinds of mistakes. I use Dropbox because Google Drive sync wasn't stable enough for this kind of workflow but I am not sure if it has been improved lately.
- stinos 4y agoI mean, why not? Because git combined with Dropbox and the likes can be slow, lead to broken repositories, mad sync conflicts and so on? At least that is what I've witnessed with colleagues. This was years ago though, and I assume you dont have these issues or maybe a different workflow, so this is more like a word of warning for others: test this properly first before just diving into it.
- kbumsik 4y agoHmm I haven't have significant issues for almost 10 years. And a few years ago Dropbox introduced a folder-level rewind feature so you can easily restore any broken folder. Anyway, YMMV.
- youngtaff 4y agoYup, I’ve been running this config for personal projects for over 10 years too
- Dylan16807 4y agoMaybe if you shut a laptop while it's syncing and then start editing the same things on a different computer without considering that you should finish the sync, but that seems pretty niche. Are you sure those people were using their own personal dropbox folders? If they were sharing with each other that's a different thing entirely and requires a lot more care to avoid problems.
- _v7gu 4y agoI don’t like to do it, but I like to sync my projects folder and google drive does not offer me an “exclude folders named node_modules” option
- bluedino 4y agoI worked with a guy that put all of our Rails apps in his Dropbox
- RobotToaster 4y agoI'm guessing, but github desktop by default uses the documents folder. By default Google drive backs up the documents folder.
- NoZebra120vClip 4y agoI use Google Workspaces at work, and I have configured my notebook more like a netbook. Every possible file and folder gets stashed in Drive, and the agent runs to integrate with the Windows filesystem. This is especially important for Company Data and Confidential Materials. I have modest storage needs in my role, but imagine a developer, Big Data user, or video editor used it. As long as they could tolerate the latencies, they might stash quite a bit in there.
- throwaway689236 4y agoI even exclude them from my TimeMachine backup, they're pinned.
- inamberclad 4y agoOut of curiosity, I checked how many files were in my node based autocompleter: $ find .vim/plugged/coc.nvim/node_modules/ | wc 12715 12715 952711
- epilys 4y agoShould be wc -l
- switch007 4y agoThe first column of the output is the lines
- ElectricalUnion 4y agoWithout parameters, wc prints `newlines`, `words` and `bytes`.
- rovr138 4y ago~/Development master ± find . | wc 1029821 1237285 118990227 ~/Development contains 3 projects I worked on this past week. Only 3 because this is a new laptop. I'd hate to think what this looks like on my old laptop. But I'll run it later.
- paulddraper 4y agohttps://preview.redd.it/tfugj4n3l6ez.png?auto=webp&v=enabled&s=b919a7283e56d929e37758af3b34e532c1a71453 https://preview.redd.it/tfugj4n3l6ez.png?auto=webp&v=enabled...
- onion2k 4y agoGoogle: We have identified modern web development as a threat to our systems, and have taken measures to ensure npm users cannot store their npm_modules directories on GoogleDrive. Please consider rewriting your nodejs projects in Go. That's a bit unfair on Node and NPM. The modules directory rarely grows to more than 4 million files.
- yjftsjthsd-h 4y ago> The modules directory rarely grows to more than 4 million files. The article says the limit is 5 million files, so... 2 NPM projects? That's not really better...
- hnfong 4y agoI think the GP is sarcasm, but I only have like 70% confidence.