Comments (12)
@tanaikech
Thank you for your quick response.
I ran djcedr's sample code with my ZIP file which has problem same as first comment by v1.0.1 (v2 on GAS), seems to work good.
from unzipgs.
@tanaikech, tagging you just to make sure you get a notification - thanks!
from unzipgs.
Thank you for your comment. Unfortunately, from your comment, I cannot replicate your situation. This is due to my poor skill. I deeply apologize for this. By the way, I think that from your error message, this might be due to the library of "unzip.min.js". How about this?
Unfortunately, I cannot still replicate your issue. I apologize for my poor skill. In order to correctly understand about your situation, can you provide the detail flow and your whole script? By this, I would like to confirm it.
from unzipgs.
Sorry. I accidentally closed it.
from unzipgs.
from unzipgs.
function sample() {
var id = "1waF7qoTO_OBt2r4q4oEMJOKRi0CccYik"; // File ID of Zip file.
var pass = "password"; // Password.
var blob = DriveApp.getFileById(id).getBlob();
var res = UnzipGs.unzip(blob, { password: pass }); // or UnzipGs.unzip(blob);
res.forEach(function(e) {
Logger.log(
"filename: %s, mimeType: %s, size: %s",
e.getName(),
e.getContentType(),
e.getBytes().length
);
});
}
from unzipgs.
Thank you for replying. Unfortunately, I cannot replicate your situation. I deeply apologize for this.
By the way, as I have already said, this library uses "unzip.min.js". So I thought that your issue might be due to "unzip.min.js". Because the error occurs at https://github.com/tanaikech/UnzipGs/blob/master/UnzipGs.js#L63 How do you think about it? If my understanding is correct, I think that this might depend on the ZIP data. In this case, I cannot resolve your issue. I apologize for this.
from unzipgs.
from unzipgs.
Thank you for replying. I deeply apologize that I couldn't be useful. This is due to my poor skill. I would like to study more and more.
from unzipgs.
Hi. Sorry for my bad English.
I guess toGas
occur the InternalError.
You know, range of Blob[] values is -128 to 127.
So when taking 128 expect -128, but this code computes 128 to 128.
And, Utilities.newBlob([128])
will crash.
toGas = function(ar_) {
var a;
a = ar_.map(function(e) {
var res;
- res = e > 128 ? e - 256 : e;
+ res = e >= 128 ? e - 256 : e;
return res;
});
return Utilities.newBlob(a);
};
from unzipgs.
@takumab21 Thank you for your comment. I could confirm it. Now, I fixed it and updated to v1.0.1. Could you please confirm it? https://github.com/tanaikech/UnzipGs#update-history
from unzipgs.
@takumab21 Thank you for testing it. The issue was able to be resolved by your support. Thank you so much.
from unzipgs.
Related Issues (4)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from unzipgs.