Skip to content
This repository has been archived by the owner on Oct 26, 2023. It is now read-only.

Update failed and self-deleted #44

Closed
shatner opened this issue Jun 8, 2017 · 4 comments
Closed

Update failed and self-deleted #44

shatner opened this issue Jun 8, 2017 · 4 comments

Comments

@shatner
Copy link

shatner commented Jun 8, 2017

Description

This script has been running well for me but today I noticed that an update was available, so I followed instructions but the update failed. I updated npm and tried again but I'm getting the same result. Sadly, some part of the update has removed the original script so now I am without the functionality.

Expected Behavior

From my understanding, npm install -g slack-history-export should install or update the tool.

Current Behavior

Whenever I run this command, I get the following errors:
npm ERR! path /usr/local/lib/node_modules/slack-history-export/bin/slack-history-export.js
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall chmod
npm ERR! enoent ENOENT: no such file or directory, chmod '/usr/local/lib/node_modules/slack-history-export/bin/slack-history-export.js'
npm ERR! enoent This is related to npm not being able to find a file.

If I manually create the file, I still get the error and I can watch the installer/updater delete the entire directory (which would certainly explain why the file is missing). Attachment is a screen recording showing this behavior.

slack-history-export.mov.zip

It's unclear whether this is an issue with npm, the installer, or something I'm doing wrong, but I'd appreciate any advice.

@eliaskosunen
Copy link

I am experiencing this same behavior. I am unable to install the module through npm. It fails with and without -g and sudo, telling me that node_modules/slack-history-export/bin/slack-history-export.js is missing. When browsing to node_modules, there's no directory named slack-history-export.

@mariuszniemiec
Copy link

mariuszniemiec commented Jun 9, 2017

I have the same - I think it's still a problem with package.json file. I tried locally install by changing package on my local computer and I think I made it work. I will try to propose PR as soon as possible.

EDIT
Sems I can't push my branch - should I fork and try from there? contribution DOC is not detailing that :(

@hisabimbola
Copy link
Owner

Hello, I am sorry for the error, this was because of the files field in the package.json. The files field act as a whitelist flag. So I was whitelisting the wrong file. Released a new patch and that should fix it.

@mariuszniemiec
Copy link

Works as expected

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants