-
Notifications
You must be signed in to change notification settings - Fork 26.7k
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
Add too much assets in pubspec result to error #15486
Comments
As a workaround it's possible in flutter/packages/flutter_tools/lib/src/zip.dart (_ZipToolBuilder.createZip) instead of adding all files in single command: final Iterable<String> compressedNames = _getCompressedNames();
if (compressedNames.isNotEmpty) {
await runCheckedAsync(
<String>['zip', '-q', tmpFile.absolute.path]..addAll(compressedNames),
workingDirectory: zipBuildDir.path
);
}
final Iterable<String> storedNames = _getStoredNames();
if (storedNames.isNotEmpty) {
await runCheckedAsync(
<String>['zip', '-q', '-0', tmpFile.absolute.path]..addAll(storedNames),
workingDirectory: zipBuildDir.path
);
} add them individually (but it's reduce speed of project building): final Iterable<String> compressedNames = _getCompressedNames();
if (compressedNames.isNotEmpty) {
for (var name in compressedNames) {
await runCheckedAsync(
<String>['zip', tmpFile.absolute.path, name],
workingDirectory: zipBuildDir.path
);
}
}
final Iterable<String> storedNames = _getStoredNames();
if (storedNames.isNotEmpty) {
for (var name in storedNames) {
await runCheckedAsync(
<String>['zip', '-0', tmpFile.absolute.path, name],
workingDirectory: zipBuildDir.path
);
}
} after that it's necessary to remove snapshot of fluter_tools at flutter/bin/cache/flutter_tools.snapshot |
We no longer zip our own assets and instead use platform bundling. This issue is obsolete |
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of |
Steps to Reproduce
This error appear when we add too much assets (more than 3000 file for offline map for exemple) when running the command : /usr/bin/zip -q -0.
It would be cool to add a complete folder : #4890 (comment)
command
exception
flutter doctor
The text was updated successfully, but these errors were encountered: