Skip to content
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

Error: ENOENT: no such file or directory, stat 'path-to-file' #77

Open
yarandoo opened this issue Feb 1, 2018 · 1 comment
Open

Error: ENOENT: no such file or directory, stat 'path-to-file' #77

yarandoo opened this issue Feb 1, 2018 · 1 comment

Comments

@yarandoo
Copy link

yarandoo commented Feb 1, 2018

Hi,

I am getting this error, running the sample from the readme:

fs.js:940
binding.stat(pathModule._makeLong(path));
^

Error: ENOENT: no such file or directory, stat 'path-to-file'
at Object.fs.statSync (fs.js:940:11)
at getSize (/Users/esteban/Desktop/feed/node_modules/rss/lib/index.js:28:15)
at /Users/esteban/Desktop/feed/node_modules/rss/lib/index.js:89:61
at Array.forEach (native)
at generateXML (/Users/esteban/Desktop/feed/node_modules/rss/lib/index.js:63:16)
at RSS.xml (/Users/esteban/Desktop/feed/node_modules/rss/lib/index.js:185:17)
at Object. (/Users/esteban/Desktop/feed/rss.js:72:16)
at Module._compile (module.js:569:30)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:503:32)

Node Version 8.0.0, "rss": "^1.2.2", OpSystem: Sierra OS.

Error line: var xml = feed.xml();

Any ideas?

Thanks,

Esteban

@amallecourt
Copy link

It's because of the line :
enclosure: {url:'...', file:'path-to-file'}, // optional enclosure
You should remove the parameter "file" to get it work (or write path to an existing file I presume).

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

No branches or pull requests

2 participants