npm


  • BINNED

    @blakeyrat said:

    involving deleting various folders of cached shit.

    that sounds like getting OneDrive for Business back to syncing it's shit at least those folders are under local and not under roaming.



  • @Luhmann Ok. Relevance?



  • @blakeyrat said:

    @cartman82 said:

    On the other hand, if Blakey used Mac or Linux, which is probably what his frontend people are doing, none of this would have happened.

    Bullshit. It's the same CLI. I have no reason to believe the experience would be any different, much less better, on OS X.

    It's the different file system that's screwing it up the most. Mac organized their fs and directory structure similar to linux, so that's what most of these spartan tools are designed for.

    The problem is none of this shit works, and when it fails (which is inevitably does), there's no fucking error messages.
    The "solution" is a series of magical incantations involving deleting various folders of cached shit.

    My experience on Linux and Mac was that everything humms very smoothly and just gets out of your way. Errors, when they happen, give you the full stack trace and all the information you need to solve them.

    That's why I presume your problem is mostly with Windows. Oh, and using global installs. If you need administrator access to modify your modules, you screwed up your setup. Pave it over and do it right.



  • @cartman82 said:

    It's the different file system that's screwing it up the most.

    Oh so when you say Windows you mean NTFS.

    @cartman82 said:

    Errors, when they happen, give you the full stack trace and all the information you need to solve them.

    Bullshit. I know for a fact this NPM error is the exact same vague useless message on OS X. Because I spent a half hour Googling for every webpage on the Internet that mentions it.

    @cartman82 said:

    That's why I presume your problem is mostly with Windows.

    ... or maybe NTFS.

    @cartman82 said:

    Oh, and using global installs.

    I only did that because the other way didn't fucking work. It's like adding sudo. Which shit doesn't work you try it the other way.

    @cartman82 said:

    If you need administrator access to modify your modules, you screwed up your setup. Pave it over and do it right.

    Strangely, Visual Studio works the same way regardless of what permissions it's run under. I guess it must be magic.


    Now the problem is I had complete insomnia last night, and I basically can't do anything with my job until I go in and deal with this CLI shit again today. I don't think I have the patience after an entire night of no sleep at all. But if I work from home I won't be able to talk to the one other guy in the company who's gotten it working. (Who, of course, has not documented anything.)



  • @blakeyrat said:

    Strangely, Visual Studio works the same way regardless of what permissions it's run under. I guess it must be magic.

    my visual studio 6 fails expectacularly if I don't run it as admin


  • FoxDev

    @blakeyrat said:

    Strangely, Visual Studio works the same way regardless of what permissions it's run under. I guess it must be magic.

    So you can debug an IIS session without admin privileges? Because last time I checked, an unelevated debugger cannot debug an elevated process.


  • BINNED

    @blakeyrat
    Oh yeah forgot we can only post 100% relevant things in "your" threads.

    MS itself makes applications where you need to clear some unholy cache folders to get things working again. The cache folders are at best located somewhere under 'Office' or named 'groove' , that was the name of the thingy in like Office 2010.


  • BINNED

    @fbmac said:

    my visual studio 6 fails expectacularly if I don't run it as admin

    It's trying to do you a favor but you keep on insisting


  • I survived the hour long Uno hand

    @lucas1 said:

    as per usual you are trying to run before you can walk.

    Nobody wants to sit through seventeen lessons on how NPM is architected before they can actually write their goddamn code. Teams exist in which one person has the requisite knowledge and the rest are beginners, and it should be easy to put together a build system the other members can use.

    I mean, for fuck's sake, it should be painless to build the goddamn application! That's like, lesson 1 of having a team at all! There's always going to be a new guy who doesn't know your system. So congratulations, Node Community, you've regressed all the way back to the fucking dark ages.

    @blakeyrat I'd be glad to help with any knowledge I've picked up if you need it.


  • BINNED

    @Yamikuronue
    I'm having a déjà-vu ...



  • @RaceProUK said:

    So you can debug an IIS session without admin privileges?

    Huh? How the fuck is this relevant? For the record: you don't need to; it ships with IIS Express.



  • @Luhmann WHO CARES?! We're talking about NPM.


  • I survived the hour long Uno hand

    @Luhmann One of the most irritating cargo cults around here is that if Blakey says something, it must automatically be false. If I complain about NPM, it's fine, but if he complains and I agree, now I must be wrong somehow. Fuck that shit, I was hating on NPM before it was cool.


  • Grade A Premium Asshole

    @blakeyrat said:

    Oh so when you say Windows you mean NTFS.

    Which is a part of...?


  • FoxDev

    @blakeyrat said:

    How the fuck is this relevant?

    You brought it up.

    @blakeyrat said:

    For the record: you don't need to; it ships with IIS Express.

    Ah, I see, I guess there's no such thing as remote debugging.



  • @Yamikuronue And usually with really sensible and logical arguments, like if I'd read the manual (which, I remind everybody, does not exist), NPM would no longer store cache in Roaming AppData.

    When you're making that argument, you got nothing. You might as well just post, "wow Blakeyrat is entirely right."



  • @RaceProUK said:

    Ah, I see, I guess there's no such thing as remote debugging.

    What the fuck are you talking about? You know what, nevermind. Time to find the NodeBB "ignore" button.

    Per usual, I regret trying to participate in this forum. You howling jackals will have to find someone else to pile-on.


  • FoxDev

    @blakeyrat said:

    And usually with really sensible and logical arguments, like if I'd read the manual (which, I remind everybody, does not exist), NPM would no longer store cache in Roaming AppData.

    You're right, there's no official documentation on how to configure NPM to use a different folder for caching. Except for this official documentation on how to configure NPM to use a different folder for caching.



  • @blakeyrat said:

    I only did that because the other way didn't fucking work. It's like adding sudo. Which shit doesn't work you try it the other way.

    If you need administrator access to modify your modules, you screwed up your setup. Pave it over and do it right.
    Strangely, Visual Studio works the same way regardless of what permissions it's run under. I guess it must be magic.

    The point is, these are anti-patterns. When I hear you describing your problems, it's like someone shows me a heap pile of copy-pasted stack overflow code and whines how "this shit doesn't it work".

    Stop. Think. Try to understand what's going on. Don't just copy-pasta your way deeper and deeper into a hole.

    And BTW, you should never just add sudo where you shouldn't. It always causes more problems down the line.


  • I survived the hour long Uno hand

    @blakeyrat Exactly!

    For the record: I like Grunt. It's a terrible bitch to get set up, but once it's set up, mostly it's easy to use (grunt verb, so that's on par with npm verb or node file, which makes it easier to remember) and when you need to see what the configuration is, it's all condensed into a json object in a file (unlike npm, which gives you one line, or gulp, which gives you executable code for configuration), so you can figure out what is going on. There are downsides on the configuration side (mostly the connection between plugins and the config they require is basically impossible to deduce, you have to read the documentation for each plugin to figure it out, which is time consuming and awful), but I prefer it to gulp (where I have to read arbitrary code instead) or npm if you're doing anything complex.

    That said, like everything Node, when grunt fails? It fails spectacularly, in a way nobody's ever seen so no fixes are documented, and often for a reason entirely unrelated to the error message. Also it's not quite right on Windows, again, like every Node tool. The Node community needs higher standards.


  • I survived the hour long Uno hand

    @cartman82 said:

    Try to understand what's going on.

    @cartman82 said:

    you should never just add sudo

    Dude, trying to learn Linux is a bitch. I just want to get my programs installed and walk away, and it's whining at me about a million things I have no idea how to fix. I could spend the entire day googling, or try just adding sudo. I'm going to just add sudo, every time. Slowly, I'm picking up more and more knowledge, but you can't blame beginners for being beginners.

    (You can totally blame Blakey for being Blakey, but don't hate on beginners).



  • @blakeyrat said:

    This tool is awful.

    So I'm trying to get our company's front-end app working. It's in angular, and to build it you need a bunch of npm and grunt. Ok fine.

    Supposedly all you need to do is navigate to its root folder and run "npm update -g". Which gets me:

    It's "npm install" in the root folder, dumbass.


  • BINNED

    @Yamikuronue
    Sorry, wasn't talking about you. I saw posts double ...


  • I survived the hour long Uno hand

    @Luhmann said:

    I saw posts double ...

    Oh. NodeBB strikes again. Sorry 😸



  • @Yamikuronue

    I don't think it is unreasonable to have some instructions on how to run the build script properly or add a step to make sure all the prerequisites installed. How any of this is the fault of NPM?


  • I survived the hour long Uno hand

    @lucas1 said:

    I don't think it is unreasonable to have some instructions on how to run the build script properly

    It should be one step, easily executed. If not, the author of the build script should do more automation. If the one step fails, the maintainer of the build script needs to make it more robust. It shouldn't ever be on the individual trying to build to have to debug the whole node stack just to get started.



  • @Yamikuronue said:

    It should be one step, easily executed.

    I agree, they should fix their build system because it is borked. It isn't NPM.



  • @lucas1 said:

    It isn't NPM.

    Right; because putting cache content into Roaming AppData isn't a bug. And "cb() not returned" is a clear error message that's intuitively obvious to everybody.

    If you honestly don't think either of those two things aren't bugs in NPM, you need to be kept FAR away from software development.

    Now how do I ignore this fucking thread!


  • I survived the hour long Uno hand

    @lucas1 The only thing I was complaining about in your post was that you said he was trying to run before he could walk, when what he was trying to do was build the software. If he was trying to write a build script before he'd ever run one, sure, but this is like... day 1 on the job stuff. "Here's your laptop, here's your choices for IDE, here's your instance, here's how you build."



  • @blakeyrat said:

    @lucas1 said:

    It isn't NPM.

    Right; because putting cache content into Roaming AppData isn't a bug.

    Report the issue, use the work around and stop bitching. You are in the wrong profession if you think everything should always be smooth sailing.

    @Yamikuronue said:

    The only thing I was complaining about in your post was that you said he was trying to run before he could walk

    I don't know enough about what they have there. But a lot of the complaints were NPM / Bower 101 and can be found on the first result of google ... except the shitty cache thing.

    TBH these complaints are trivial compared to some of the 1 week environment setups I have to deal with and you don't see me bitching constantly.

    Also blakey_rat gets a lot of shit on here because he obviously bitches before he googles and then acts like an arsehat about having to use google.


  • I survived the hour long Uno hand

    @lucas1 said:

    Report the issue

    Pfft. Like NPM's maintainers give a shit about cache. Or disk space. Or anything Windows.

    They have over 2,000 open issues in Github. It's painful to even search for the word "cache", there's like 8 pages of open issues with that word in them. The closest thing to my issue has been open for over a year:



  • @blakeyrat said:

    285 MB of shit.

    In a folder labeled "cache"

    In the Roaming AppData.

    Sun used to do that with Java. Not sure if Oracle still does; for that and related reasons, I gave up on roaming profiles a long time ago.



  • @Yamikuronue said:

    Pfft. Like NPM's maintainers give a shit about cache. Or disk space. Or anything Windows.

    They don't and why should they? Most of their main contributors don't run it.


  • FoxDev

    @lucas1 said:

    They don't and why should they?

    Because they officially support it as a platform



  • @Yamikuronue said:

    Dude, trying to learn Linux is a bitch. I just want to get my programs installed and walk away, and it's whining at me about a million things I have no idea how to fix. I could spend the entire day googling, or try just adding sudo. I'm going to just add sudo, every time. Slowly, I'm picking up more and more knowledge, but you can't blame beginners for being beginners.

    Trying to learn programming is too. Doesn't mean you should silently accept WHERE user = $user because "I just want to get the job done".

    Look, I get it. I'm not some guru genius. I oftentimes fall into this pattern as well. It's just important to recognize this is a frustrating and often futile way to do things. And that you can profit by slowing down and trying to understand the situation, before you start typing stuff.


  • FoxDev

    @RaceProUK said:

    @lucas1 said:

    They don't and why should they?

    Because they officially support it as a platform

    exactly, either support it properly, or don't support it at all.

    yes windows is drastically different than linux. that doesn't mean it's okay to ignore it of say "it mostly works, and that's good enough"


  • I survived the hour long Uno hand

    @cartman82 said:

    It's just important to recognize this is a frustrating and often futile way to do things.

    I'm just saying, users don't use sudo all the time because they're dumb stupid poopypants who hate learning, they use it because they need to get shit done and it's very difficult to figure out the right way to do it and very easy to do it the wrong way. Interaction design 101: make it easier to do it right than to do it wrong, or people will just do it wrong and walk away.


  • FoxDev

    @Yamikuronue said:

    Interaction design 101: make it easier to do it right than to do it wrong

    QFT.

    Also the design philosophy of C#, funnily enough.



  • @Yamikuronue said:

    I'm just saying, users don't use sudo all the time because they're dumb stupid poopypants who hate learning, they use it because they need to get shit done and it's very difficult to figure out the right way to do it and very easy to do it the wrong way. Interaction design 101: make it easier to do it right than to do it wrong, or people will just do it wrong and walk away.

    You're saying: "If you don't have enough trash cans around the park, people will litter."
    I'm saying: "Even if there are no trashcans around, you shouldn't litter"

    Same situation, different POV-s.


  • I survived the hour long Uno hand

    @cartman82 said:

    You're saying: "If you don't have enough trash cans around the park, people will litter."

    I'm saying "If you want people not to litter, add trash cans, don't stand around in the park yelling at litterers."



  • @Yamikuronue Fuckers are gonna litter anyway. I have lost count of the number of times I've seen smokers toss their butts rather than grind them out on the lip of the garbage can they're standing right next to.



  • @RaceProUK said:

    Also the design philosophy of C#, funnily enough.

    And Mac Classic, where I learned computers and programming. In fact the cleanness of the C# libraries (especially compared to the Win32 mess) is a lot of what attracted me to switch from OS X to Windows in the first place. Apple was selling an OS full of 48,000 tiny files and no coherent design, while Microsoft who had already been an OS full of 48,000 files and barely any coherent design had just done an AMAZING job actually designing their new API.

    The open source philosophy is more like, "make the right thing difficult or impossible, and yell at anybody who does the wrong thing anyway."



  • @cartman82 We had this exact discussion about sudo a couple years ago when I was doing something on Ubuntu Server. sudo is, for all practical purposes, a "magical keyword" that makes errors go away-- because the designers of Ubuntu neglected to provide any way of authenticating after a command has started (but before it detects it need to do some sort of administrative act).

    They probably didn't design it that way on purpose, but accidental design is still design, and Linux is still training people that sudo is a magic word that makes confusing vague errors go away.


  • FoxDev

    @cartman82, @Yamikuronue, you're both right.

    It is correct to say that people should take the time to understand what tools they're using; that way, they can use the tools more effectively. But it is also correct to say the tools should be easy to use; after all, no-one wants a hammer they need to prepare by fiddling with 32 DIP switches.

    The problem with a lot of open-source software (and to a lesser extent, closed-source), is that not enough attention is paid to the UX; the developers work on what they're fascinated by i.e. the new shiny, but few take the time to work on what is necessary i.e. UX and documentation. So when things go wrong, it's that much harder to find a solution, because usually the documentation sucks, or the error message is cryptic.

    It's not an unfixable problem; it just needs developers to acknowledge they're shit at UX, and to get someone in who isn't shit at UX to sort it out.


  • I survived the hour long Uno hand

    @RaceProUK said:

    It is correct to say that people should take the time to understand what tools they're using

    I'm currently reading The Inmates are Running the Asylum, a book about interaction design. It pointed out something I think a lot of developers overlook: nobody wants to spend time learning tools, they're forced into it by bad interaction design. People want to achieve things. Their goals are to accomplish tasks, not to learn how computers work. Engineering types always want to know how things work, which is great when you're exploring on your own and have all the time in the world, but when you're on a deadline trying to get stuff done for work, even we engineering types tend to be in "get shit done" mode and focus entirely on accomplishing our goals rather than deconstructing the whole mental model of the software. When I use git, my goal is to get my code out to the other team members, not to understand the underlying model of distributed source control. So if I have to stop and think about the underlying model, I'm not accomplishing my goal during that time, and it's frustrating. If I have to spend 2 hours reading manuals before I can use the product, that's 2 hours less time I have to accomplish my real goals.



  • @blakeyrat said:

    because the designers of Ubuntu neglected to provide any way of authenticating after a command has started (but before it detects it need to do some sort of administrative act).

    Hmm... isn't it the other way around? Linux commands can switch execution mode, on Windows you need to restart the application with elevated permissions?



  • @accalia

    Like with any project there is a finite amount of resources, most of their users don't use Windows and most of their contributors don't either. So I am not surprised Windows bugs aren't a priority.

    And yes it does work perfectly fine in my experience, and I've never ran into a lot of the problems complained about here. The experience isn't going to be as smooth on Windows especially when it comes to what was a *nix project that been ported, that is reality, and I think that is fine.



  • @Yamikuronue said:

    nobody wants to spend time learning tools, they're forced into it by bad interaction design. People want to achieve things. Their goals are to accomplish tasks, not to learn how computers work.

    I see this argument a lot. It has some merit, but people who make it frequently overlook a point that I think is vital: as more and more IT worms its way into more and more lives, there are more and more tasks that no amount of careful interaction design is going to make any easier.

    IT involves a certain irreducible minimum of conceptual understanding to be of any use whatsoever; people who can't or won't grasp even that irreducible minimum are the ones who flounder. And as we add more and more IT to society, there are more and more people floundering.

    I don't think it's all down to bad interaction design, though undoubtedly that's a large factor. Ultimately, I think it's down to our collective inability to resist the Technological Imperative (CAN == MUST).

    Life in 2016 contains many more conveniences than it did in 1976. But I'm not convinced that the economic and technological arrangements that we (affluent Westerners) live with now make us, on balance, any happier than we used to be.



  • @cartman82 said:

    @blakeyrat said:

    because the designers of Ubuntu neglected to provide any way of authenticating after a command has started (but before it detects it need to do some sort of administrative act).

    Hmm... isn't it the other way around? Linux commands can switch execution mode, on Windows you need to restart the application with elevated permissions?

    It's exactly the same on both. Permissions apply per process, so if you want elevated permissions you need to launch an elevated process.

    Both Windows and Linux desktops contain multiple examples of user-facing programs that do exactly this.



  • Maybe you shouldn't be in Software Engineering then if that is the case, because the argument you are making is essentially I shouldn't have to know how to use the tools of the trade. It like a saying a carpenter shouldn't know how to use a chisel ... it is ridiculous.


Log in to reply