-
Type:
Bug
-
Resolution: Won't Fix
-
None
-
Affects Version/s: None
-
Component/s: Import/Export
-
Emptyshow more show less
problem
Import with a given ZIP file files with the message:
Der übergebene ProofReadFolder /home/tlauria/www/itl_icorrect/application/../data/editorImportedTasks/96e2a685-d429-4ac0-b9db-01db832d2798/_tempImport/proofread existiert nicht oder ist leer.
reason
After investigation the problem was found in the ZIP file itself. The file was created under windows in way that the backslash directory seperator was keeped. A "unzip -l" under linux returned:
Length Date Time Name
--------- ---------- ----- ----
448371 2018-08-16 07:07 proofread\090_de_Cover.idml.sdlxliff
296176 2018-08-16 07:07 proofread\099_de_MS.idml.sdlxliff
1042938 2018-08-16 07:07 proofread\100_de_4PM.idml.sdlxliff
43301 2018-08-16 07:07 proofread\graphic_texts.xlsx.sdlxliff
765176 2018-08-16 07:07 reference\8022431_ES_Preview_arial.pdf
On using unzip to extract the files, the following warning occurred:
tlauria@tenforward /tmp/foo $ unzip ../import.zip Archive: ../import.zip warning: ../import.zip appears to use backslashes as path separators inflating: proofread/090_de_Cover.idml.sdlxliff inflating: proofread/099_de_MS.idml.sdlxliff inflating: proofread/100_de_4PM.idml.sdlxliff inflating: proofread/graphic_texts.xlsx.sdlxliff inflating: reference/8022431_ES_Preview_arial.pdf
conclusion
The conclusion is to set the issue to "Won't fix" since this problem never appeared in the last years processing ZIP files created under windows, obviously using slash as path separator too.
The solution here is to change the way how the ZIP files are created, since using backslash as path separator for ZIPs is just no default behaviour.
Also there is no easy solution on our side by using a "flag" in PHPs ZipArchive since there is no such a flag.
trace
ZfExtended_Log on icorrect-itl.localdev: Exception: exception 'Zend_Exception' with message 'Der übergebene ProofReadFolder /home/tlauria/www/itl_icorrect/application/../data/editorImportedTasks/96e2a685-d429-4ac0-b9db-01db832d2798/_tempImport/proofread existiert nicht oder ist leer.' in /home/tlauria/www/itl_icorrect/application/modules/editor/Models/Import/Configuration.php:243 Stack trace: #0 /home/tlauria/www/itl_icorrect/application/modules/editor/Models/Import/Configuration.php(155): editor_Models_Import_Configuration->validateImportFolders() #1 /home/tlauria/www/itl_icorrect/application/modules/editor/Models/Import.php(89): editor_Models_Import_Configuration->isValid(' {96e2a685-d429-...') #2 /home/tlauria/www/itl_icorrect/application/modules/editor/Controllers/TaskController.php(364): editor_Models_Import->import(Object(editor_Models_Import_DataProvider_Zip)) #3 /home/tlauria/www/itl_icorrect/application/modules/editor/Controllers/TaskController.php(320): editor_TaskController->processUploadedFile() #4 /home/tlauria/libaries/ZendFramework-1.12.20-minimal/library/Zend/Controller/Action.php(516): editor_TaskController->postAction() #5 /home/tlauria/www/itl_icorrect/library/ZfExtended/Controllers/AAARestController.php(275): Zend_Controller_Action->dispatch('postAction') #6 /home/tlauria/libaries/ZendFramework-1.12.20-minimal/library/Zend/Controller/Dispatcher/Standard.php(308): ZfExtended_RestController->dispatch('postAction') #7 /home/tlauria/libaries/ZendFramework-1.12.20-minimal/library/Zend/Controller/Front.php(954): Zend_Controller_Dispatcher_Standard->dispatch(Object(REST_Controller_Request_Http), Object(Zend_Controller_Response_Http)) #8 /home/tlauria/libaries/ZendFramework-1.12.20-minimal/library/Zend/Application/Bootstrap/Bootstrap.php(105): Zend_Controller_Front->dispatch() #9 /home/tlauria/libaries/ZendFramework-1.12.20-minimal/library/Zend/Application.php(384): Zend_Application_Bootstrap_Bootstrap->run() #10 /home/tlauria/www/itl_icorrect/library/ZfExtended/BaseIndex.php(167): Zend_Application->run() #11 /home/tlauria/www/itl_icorrect/public/index.php(25): ZfExtended_BaseIndex->startApplication() #12 \{main}