New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ungit throws error at startup and quits #1130

Closed
guillaumedavidphd opened this Issue Aug 21, 2018 · 25 comments

Comments

Projects
None yet
8 participants
@guillaumedavidphd
Copy link

guillaumedavidphd commented Aug 21, 2018

I haven't been able to run ungit since the last update. I get the following error:

internal/modules/cjs/loader.js:596

throw err;
^

Error: Cannot find module 'editions'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:594:15)
    at Function.Module._load (internal/modules/cjs/loader.js:520:25)
    at Module.require (internal/modules/cjs/loader.js:650:17)
    at require (internal/modules/cjs/helpers.js:20:18)
    at Object.<anonymous> (C:\Users\<username>\AppData\Roaming\npm\node_modules\ungit\node_modules\getmac\index.js:4:18)
    at Module._compile (internal/modules/cjs/loader.js:702:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:713:10)
    at Module.load (internal/modules/cjs/loader.js:612:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:551:12)
    at Function.Module._load (internal/modules/cjs/loader.js:543:3)

The module editions is installed globally, and so is ungit.

@SDohle

This comment has been minimized.

Copy link

SDohle commented Aug 23, 2018

I get the same error (ungit@1.4.32)

@ylecuyer

This comment has been minimized.

Copy link
Contributor

ylecuyer commented Aug 23, 2018

Which version of node/npm are you using?

Please refer to https://github.com/FredrikNoren/ungit/blob/master/CONTRIBUTING.md

Posting issues
Just common sense; do a quick search before posting, someone might already have created an issue (or resolved the problem!). If you're posting a bug; try to include as much relevant information as possible (ungit version, node and npm version, os, any git errors displayed, the output from CLI console and output from the browser console).

@guillaumedavidphd

This comment has been minimized.

Copy link

guillaumedavidphd commented Aug 23, 2018

ungit@1.4.32
node@10.3.0
npm@6.4.0
os: Win10

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 23, 2018

getmac and editions are my packages. Could the author please try updating getmac to 1.4.4 as the debugging info users have provided is for getmac 1.4.1

@guillaumedavidphd

This comment has been minimized.

Copy link

guillaumedavidphd commented Aug 23, 2018

I've updated getmac to 1.4.4. Probem is still here.

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 23, 2018

Mind if I remote in and debug it with you? Not sure the issue is on my side, but happy to look into it as it is my package after all.

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 23, 2018

Ok. I think I miss configured something with editions. Let me push up a fix. One moment. Strange errors are now only coming in, as the version is a few weeks old.

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 23, 2018

v1.4.5 of getmac will be published as soon as https://travis-ci.org/bevry/getmac/builds/419868038 passes - let me know if that resolves the issue

edit, now published

@tony90018

This comment has been minimized.

Copy link

tony90018 commented Aug 24, 2018

I've updated getmac to 1.4.5. But the problem still exists.

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 24, 2018

I will need to remote into your machine to debug, as I am unable to reproduce. Grab a time on https://balupton.com/meet and we’ll work it out

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 24, 2018

Also interesting that all reports are for windows. Is anyone encountering this not on windows?

Will try and get a windows VM going. Perhaps it is an issue with using colon in directory names, affecting the node resolution system or the npm bundles.

@ylecuyer

This comment has been minimized.

Copy link
Contributor

ylecuyer commented Aug 24, 2018

I tried on ubuntu 18.04 with the exact same versions and I didn't had problems

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 26, 2018

So turns out it is because Windows doesn't support : in filenames, it seems however npm is still able to install the packages on Windows as it converts : on those platforms to which shows as a dot character.

I can work around this issue by not using : in filenames, however it seems that the node module resolution system should have a workaround for what npm has done.

capture

@balupton

This comment has been minimized.

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 26, 2018

I'll see what they say. Regardless, I'll push up a workaround (using underscores instead of colons) tomorrow. Sorry for the stuff up everyone.

@jung-kim

This comment has been minimized.

Copy link
Collaborator

jung-kim commented Aug 26, 2018

Thanks for diving into this issue in details, and this seems like a tricky issue.

Considering getmac@1.4.5 is still having some issue I will not cut the new version with this yet.

Once again, thanks for the prompt response!

@jung-kim

This comment has been minimized.

Copy link
Collaborator

jung-kim commented Aug 26, 2018

(and sorry I've been unresponsive as this is a very busy week for my company... :( )

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 27, 2018

Came off my motorbike today and got a bit scraped up. So will get to this in a day or two. Sorry for the delay.

In the meantime, you can pin getmac to an earlier version, perhaps 1.4.4 or 1.4.3

@balupton

This comment has been minimized.

Copy link

balupton commented Aug 29, 2018

Hand got infected and had to return to Australia for treatment. Will be another day or so. I'm really sorry for the delays.

@mastermind3043

This comment has been minimized.

Copy link

mastermind3043 commented Aug 30, 2018

+1 facing the same issue

@per2mn

This comment has been minimized.

Copy link

per2mn commented Sep 2, 2018

Also facing the same issue since many days (weeks?).
Seems that npm plugin 'editions' is not Windows compatible because of a ':' in the plugin name or dir???

@balupton

This comment has been minimized.

Copy link

balupton commented Sep 2, 2018

Correct. I will get to it when I can, so far I have been too injured. Things are finally getting better though.

For the meantime, pin getmac to an earlier version.

@jung-kim

This comment has been minimized.

Copy link
Collaborator

jung-kim commented Sep 2, 2018

@balupton Will downgrading to getmac@1.4.3 and locking it to that version work?

@balupton

This comment has been minimized.

Copy link

balupton commented Sep 3, 2018

getmac 1.4.6 is incoming which will resolve this issue

if you experience it again, clear your npm cache and try again

@guillaumedavidphd

This comment has been minimized.

Copy link

guillaumedavidphd commented Sep 4, 2018

Looks like ungit is fixed for me thanks to @balupton. Please reopen if someone is still affected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment