Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Empty language pack ZIP #168

Closed
florianbrinkmann opened this issue Feb 29, 2020 · 2 comments · Fixed by #169
Closed

Empty language pack ZIP #168

florianbrinkmann opened this issue Feb 29, 2020 · 2 comments · Fixed by #169
Labels
[Type] Bug Bugs and regressions in existing functionality
Milestone

Comments

@florianbrinkmann
Copy link
Contributor

Issue Overview
After already playing around with Traduttore some time ago, I gave it a try again today and had a problem with empty language pack ZIPs. After some debugging I found out that the issue was the .tmp ending of the temporary ZIP file with the ZipArchive::CREATE.

https://github.com/wearerequired/traduttore/blob/3.0.0/inc/ZipProvider.php#L150-L152

It worked when I either created a $temp_zip_file with .zip ending or changed the CREATE to OVERWRITE.

My first try with Traduttore was on the same server, and it worked back then, so it is a little bit strange.

To Reproduce
Steps to reproduce the behavior:
In my case: run the wp traduttore language-pack build WP CLI command and the generated ZIP is empty.

Versions

  • PHP: 7.3.11
  • WP-CLI: 2.4.0
  • GlotPress: 2.3.1
  • WordPress: 5.3.2
@ocean90
Copy link
Member

ocean90 commented Mar 3, 2020

Thanks for the report! Can you check what error code $zip->open() is returning?

@florianbrinkmann
Copy link
Contributor Author

Yes, it returns the Code 19. Reading the comments on the php.net site, that is Not a zip archive.

@ocean90 ocean90 added the [Type] Bug Bugs and regressions in existing functionality label Mar 3, 2020
@ocean90 ocean90 added this to the 3.1.0 milestone Mar 3, 2020
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
[Type] Bug Bugs and regressions in existing functionality
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants