-
Notifications
You must be signed in to change notification settings - Fork 773
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
.Copy & .CopySync #115
Comments
Can you produce any code to reproduce the problem? I'm unable to reproduce it. Thanks. |
I have the same issue. Reproduced with a simple directory copy on windows |
I think I have found the issue, in copy.js, line 40: if (stats.isDirectory()) {
var parts = dest.split(path.sep)
parts.pop()
dir = parts.join(path.sep)
} This code does not work on windows if dest argument uses slash instead of anti-slash (which is supported by all fs libraries) if (stats.isDirectory()) {
dir = path.resolve(dest, "..");
} Do you want me to make a pull request ? |
that's maybe not the only issue because it also fail with anti-slash pathes and when the dest directory does not exists (not passing the |
Yes, would love any help that you're willing to offer :) |
Just made a pull request for the issue I found in my previous comment. Regarding this issue, I'll try to reproduce and enquire soon.
|
@felicienfrancois are you using the latest |
I'm was using either 0.14 or 0.16.4. When I get the issue it was reproductible at 100%. But I tried to reproduce it later and I never succeed, even on the same computer, with the same setup, same version of fs-extra and same revision of my code. I no longer have the issue with 0.16.5 but I cannot tell you if the issue is fixed as I'm not able to reproduce it with older version :S. I don't know what can be the cause but parallel copy is a bit hazardous. It could creates deadlocks with file system locks or whatever problems due to doing several operation in parallel in the same place. Is there really a lot of performance difference between parralel and sequencial copy (I mean async but sequential) ? On top of that, in async mode, a timeout option would be welcome to handle any possible error (coming from fs-extra or any underlying native or not native modules). |
@jprichardson This issue is so old, shouldn't we just close it and see if anyone else reports it later? |
Hi, I'm working on this project: https://github.com/devildeveloper/BlackMeza/blob/master/index.js.
I have the following problem: .copy method does not work. The copySync method only works if I did not send the callback, otherwise generates only the structure of folders.
I'm working with Osx Yosemite
The text was updated successfully, but these errors were encountered: