Closed neko-para closed 6 months ago
Yes I'm also facing the same issue.
Sample code that I'm testing with:
import { configure, fs } from "@zenfs/core";
import { Zip } from "@zenfs/zip";
...
const res = await fetch("source_code.zip");
const data = await res.arrayBuffer();
await configure({
home: { backend: Zip, zipData: data },
});
fs.readdir("/home/", function (err, list) {
console.log(err, list);
});
@neko-para @msk4862,
I apologize for not getting back to you sooner, I did not have the correct notification settings for this repository.
Unfortunately, I have no idea where this issue was introduced. If you have any ideas as to what is happening, I would greatly appreciate them.
In the mean time, I can start debugging and see what I come up with.
@neko-para @msk4862,
The issue was with safeToString
not slicing the buffer when useUTF8
was false. This has been fixed in v0.1.4. This fixes the issue on my end.
Has your issue been fixed?
@neko-para @msk4862,
The issue was with
safeToString
not slicing the buffer whenuseUTF8
was false. This has been fixed in v0.1.4. This fixes the issue on my end.Has your issue been fixed?
I'll try later, currently I've changed to using zip.js to explicitly extract and compress zip files.
@neko-para Any updates on this?
resource.zip
After mounting this zip, readdir gave the following output
Seems that entries are flatten and not recognized properly.