29845[TASK] EM: Add possibility to bypass system dependency checks
Commit message
Review
-
Code review CR +2
- Xavier Perseguers +2
- Markus Klein +1
- Zbigniew Jacko +1
-
Verified V +2
- Xavier Perseguers +2
- Zbigniew Jacko +1
Issues 1
Files 29
- typo3/sysext/extensionmanager/Classes/Controller/ActionController.php4+30 −11
- typo3/sysext/extensionmanager/Classes/Controller/DownloadController.php+25 −6
- typo3/sysext/extensionmanager/Classes/Controller/ListController.php4+32 −0
- typo3/sysext/extensionmanager/Classes/Controller/UploadExtensionFileController.php4+22 −11
- typo3/sysext/extensionmanager/Classes/Exception/MissingExtensionDependencyException.phpnew+34 −0
- typo3/sysext/extensionmanager/Classes/Exception/MissingVersionDependencyException.phpnew+34 −0
- typo3/sysext/extensionmanager/Classes/Exception/UnresolvedDependencyException.phpnew+34 −0
- typo3/sysext/extensionmanager/Classes/Exception/UnresolvedPhpDependencyException.phpnew+34 −0
- typo3/sysext/extensionmanager/Classes/Exception/UnresolvedTypo3DependencyException.phpnew+34 −0
- typo3/sysext/extensionmanager/Classes/Service/ExtensionManagementService.php3+60 −13
- typo3/sysext/extensionmanager/Classes/Utility/DependencyUtility.php11+121 −43
- typo3/sysext/extensionmanager/Classes/Utility/InstallUtility.php+2 −3
- typo3/sysext/extensionmanager/Resources/Private/Language/locallang.xlf+40 −3
- typo3/sysext/extensionmanager/Resources/Private/Partials/List/UnresolvedDependencies.html6new+22 −0
- typo3/sysext/extensionmanager/Resources/Private/Partials/List/UnresolvedDependencies.json3new+6 −0
- typo3/sysext/extensionmanager/Resources/Private/Partials/List/UnresolvedDependenciesMessage.html8new+1 −0
- typo3/sysext/extensionmanager/Resources/Private/Templates/Action/RemoveExtension.jsondeleted+0 −2
- typo3/sysext/extensionmanager/Resources/Private/Templates/Download/InstallFromTer.json+8 −1
- typo3/sysext/extensionmanager/Resources/Private/Templates/List/UnresolvedDependencies.html2new+29 −0
- typo3/sysext/extensionmanager/Resources/Private/Templates/UploadExtensionFile/Extract.jsondeleted+0 −2
Show 9 more files
- typo3/sysext/extensionmanager/Resources/Private/Templates/UploadExtensionFile/Form.html+1 −3
- typo3/sysext/extensionmanager/Resources/Public/JavaScript/main.js+6 −11
- typo3/sysext/extensionmanager/Resources/Public/JavaScript/ter.js3+13 −3
- typo3/sysext/extensionmanager/Resources/Public/JavaScript/upload.js+0 −17
- typo3/sysext/extensionmanager/Tests/Unit/Controller/UploadExtensionFileControllerTest.php+4 −1
- typo3/sysext/extensionmanager/Tests/Unit/Domain/Model/DownloadQueueTest.php2+47 −41
- typo3/sysext/extensionmanager/Tests/Unit/Service/ExtensionManagementServiceTest.php1+13 −12
- typo3/sysext/extensionmanager/Tests/Unit/Utility/DependencyUtilityTest.php2+157 −106
- typo3/sysext/extensionmanager/ext_tables.php+3 −3
Review log 81
Show 56 earlier messages
-
Anja Leichsenring commented on patch set 1 05/04/14, 11:11
my ExtJS window listing dependency violations and the warning is only 176px wide, so this looks quite strange, but this is the only thing I really found (Chromium Browser on Ubuntu Linux on not full screen mode). I tested: - download an extension with offending dependencies from TER (offending itself and dependencies with offending version dependency, too) - upload a zip extension with offending dependencies, dependencies needed to be downloaded from TER with offending version dependency. - upload zip extension, with dependencies available in the system. -
Nicole Hummel uploaded patch set 2 05/04/14, 12:47
-
Nicole Hummel commented on patch set 2 05/04/14, 12:48
Rebased with current master -
Mr. Jenkins commented on patch set 1 05/04/14, 18:44
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16280/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16276/ : SUCCESS -
Mr. Jenkins commented on patch set 2 05/04/14, 20:59
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16289/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16285/ : SUCCESS -
Nicole Hummel uploaded patch set 3 05/04/14, 22:04
-
Mr. Jenkins commented on patch set 3 05/05/14, 04:17
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16311/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16307/ : SUCCESS -
Markus Klein updated the commit message in patch set 3 05/05/14, 07:57
-
Mr. Jenkins commented on patch set 4 05/05/14, 08:15
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16315/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16311/ : SUCCESS -
Markus Klein commented on patch set 4 CR -1 05/05/14, 08:46
All in all a great change that took me nearly an hour to review. Still some issues remain. Thx for your work Nicole.ActionController.php:122Why do we statically return '' here?ListController.php:80bypass dependency checkingExtensionManagementService.php:196depended - the word does not existDependencyUtility.php:31I'd suggest to include: use TYPO3\CMS\Extensionmanager\Exception as EmException So all Exceptions are included and can be used as EmException\Unres...ptionDependencyUtility.php:161!empty() is faster according to Wouter.DependencyUtility.php:244Does not match the throw below.DependencyUtility.php:258So you convert any Unresolved*Exception to MissingVersionDep*Exception? Why that?UnresolvedDependencies.html:4Doesn't string comparison work directly now?UnresolvedDependencies.html:13ucfirst "required" ;-)UnresolvedDependencies.html:31"Depended" - word does not exist. "if they not yet exist in the system" => "if they do not exist on the system yet"UnresolvedDependencies.html:36may? If the system is unusable, manual intervention >will< be required. ;-)UnresolvedDependencies.json:1Uhm... this file has .json extension. Hence it should be/generate valid json output and not HTMLter.js:118Is this a translation key or a string to display?DownloadQueueTest.php:58call to parent function missingExtensionManagementServiceTest.php:131Don't think so. EBT is the wrong one here.DependencyUtilityTest.php:49call to parent missing -
Nicole Hummel commented on patch set 4 05/05/14, 09:08
ActionController.php:122ReplyThis is an ajax action which doesn't need to return anything at it triggers a page reload. But we do not need to start any fluid rendering.ListController.php:80ReplyWhy?ExtensionManagementService.php:196Reply"required extensions" thanDependencyUtility.php:31ReplyIs this done elsewhere in the core?DependencyUtility.php:258ReplyThe thrown exceptions can be either php, typo3 related or extension related, which means in general that the (required) extension will be missing afterwards.UnresolvedDependencies.html:4ReplyDoes it? I haven't heard of it.UnresolvedDependencies.json:1ReplyIt is an partial and turned to json in the template. HTML is need for proper styling within the confirm box. -
Markus Klein commented on patch set 4 05/05/14, 14:17
ActionController.php:122ReplyDoes an ajax action have a return value?ListController.php:80ReplyCorrect English sentence is either: The possibility to bypass the dependency check. or The possibility to bypass dependency checking.ExtensionManagementService.php:196ReplyOr: Check dependencies for an extension and its requirementsDependencyUtility.php:31ReplyYep, but I can't give you a proof atm. This was suggested to me by Oli Klee and others multiple times.DependencyUtility.php:258Replyok got it!UnresolvedDependencies.html:4ReplyAt least I used it in a 6.2 project two days ago. But we can leave it like that of course.UnresolvedDependencies.json:1ReplyOh ok. Still this looks a bit weird :-) but fine then. -
Nicole Hummel commented on patch set 4 05/05/14, 16:08
ActionController.php:122ReplySure. You can return json to the request. But here isn't any return needed, so the empty string is enough.ter.js:118ReplyIt is a stringDownloadQueueTest.php:58ReplyOwn tearDown isn't needed at all, as the unset is done with a reflection in parent class. Removed it.DependencyUtilityTest.php:49ReplyNot needed anymore. -
Nicole Hummel uploaded patch set 5 05/05/14, 16:08
-
Markus Klein commented on patch set 5 05/05/14, 16:24
ExtensionRepository.php:251Why that? ->count() should give us an integer. -
Nicole Hummel commented on patch set 5 05/05/14, 16:35
ExtensionRepository.php:251ReplyI didn't see that count(). But then we have a double count() in dependencyUtility. -
Nicole Hummel uploaded patch set 6 05/05/14, 16:39
-
Markus Klein commented on patch set 6 05/05/14, 16:47
DependencyUtility.php:360This bug also needs a fix in 6.1 (and 6.0). I'll push a patch. -
Markus Klein commented on patch set 6 05/05/14, 16:52
DependencyUtility.php:360ReplyFixed with: https://review.typo3.org/29876 -
Mr. Jenkins commented on patch set 5 05/05/14, 17:00
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16326/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16322/ : SUCCESS -
Mr. Jenkins commented on patch set 6 05/05/14, 17:44
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16328/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16324/ : SUCCESS -
Nicole Hummel uploaded patch set 7 05/06/14, 07:18
-
Nicole Hummel commented on patch set 7 05/06/14, 07:19
Rebased to current master -
Mr. Jenkins commented on patch set 7 05/06/14, 07:46
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16343/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16339/ : SUCCESS -
Markus Klein commented on patch set 7 CR +1 05/06/14, 10:06
Do we have some test extensions for this? -
Nicole Hummel commented on patch set 7 05/06/14, 10:34
You can try news, media and googlequery -
Markus Klein commented on patch set 7 05/06/14, 12:44
UnresolvedDependenciesMessage.html:1process -> proceed -
Markus Klein uploaded patch set 8 05/06/14, 12:44
-
Markus Klein voted on patch set 8 V +1 CR +1 05/06/14, 12:44
-
Mr. Jenkins commented on patch set 8 05/06/14, 12:59
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16346/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16342/ : SUCCESS -
Wouter Wolters commented on patch set 8 05/06/14, 13:03
UploadExtensionFileController.php:204IMO this is hard to read, if I'm correct we do not allow inline assigment in if-statementsDependencyUtility.php:320Wrong @throws There are also some missing hereUnresolvedDependencies.html:30not needed whitespace here -
Nicole Hummel uploaded patch set 9 05/06/14, 23:17
-
Mr. Jenkins commented on patch set 9 05/07/14, 00:46
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16368/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16364/ : SUCCESS -
Markus Klein commented on patch set 9 V +1 CR -1 05/07/14, 11:34
UnresolvedDependenciesMessage.html:1This is NOT an English sentence. Please put that into a translator and check yourself. I suggest: If you continue installing the extension, all dependency checks are turned off. -
Nicole Hummel commented on patch set 9 05/07/14, 11:46
UnresolvedDependenciesMessage.html:1ReplyIt's fine with me. I wait for other reviews to minimize patch sets -
Markus Klein commented on patch set 9 05/07/14, 13:28
UnresolvedDependenciesMessage.html:1ReplySure, no need to push an extra set just for the wording here. Forgot to mention that in my comment. -
Markus Klein uploaded patch set 10 05/11/14, 23:08
-
Markus Klein commented on patch set 10 V +1 CR +1 05/11/14, 23:09
Rebased and fixed the wording. -
Mr. Jenkins commented on patch set 10 05/12/14, 00:44
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16415/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16411/ : SUCCESS https://ci.typo3.org/job/typo3-v4-core-gerrit/16410/ : SUCCESS -
Markus Klein uploaded patch set 11 05/22/14, 22:23
-
Markus Klein commented on patch set 11 05/22/14, 22:28
RebasedUploadExtensionFileController.php:149removeExtensionAndRestoreFromBackup() was called for any Exception that might have occurred. Now we only call it for ExtensionManagerException. Is that a problem? -
Mr. Jenkins commented on patch set 11 05/22/14, 22:43
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16524/ : SUCCESS -
Xavier Perseguers commented on patch set 11 CR -1 06/10/14, 07:56
further working on it (testing, ...)UnresolvedDependenciesMessage.html:1are turned off => will be turned off Basically, why is this part not translatable?UnresolvedDependenciesMessage.html:3if they not yet exist => if they do not yet existUnresolvedDependencies.html:27This is not translatableter.js:118not translatable -
Nicole Hummel commented on patch set 11 06/10/14, 08:07
@Xavier: I haven't translated it yet as the exceptions aren't translated even. This would be a todo for a follow up patch! -
Nicole Hummel commented on patch set 11 06/10/14, 08:10
UploadExtensionFileController.php:149ReplyI think this is wrong from rebase and should be changed -
Xavier Perseguers uploaded patch set 12 06/10/14, 08:38
-
Xavier Perseguers voted on patch set 12 V +1 CR +1 06/10/14, 08:45
-
Mr. Jenkins commented on patch set 12 06/10/14, 08:52
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16607/ : SUCCESS -
Markus Klein commented on patch set 11 06/10/14, 10:28
UploadExtensionFileController.php:149ReplyThis was a conflict in the rebase so I had to make a decision. I posted the question because of this decision. What is the correct way? -
Steffen Ritter commented on patch set 12 CR +1 06/10/14, 10:42
maybe the commit message could be improved -
Lorenz Ulrich uploaded patch set 13 06/10/14, 13:48
-
Lorenz Ulrich commented on patch set 13 V +1 06/10/14, 13:50
I improved the language labels. Otherwise it seems to work. -
Xavier Perseguers commented on patch set 13 V -1 CR +1 06/10/14, 13:53
ListController.php:86There are two problems here: 1) It reads info from DB so if you are changing your own extension locally (which is sent to TER so present in DB), you are getting dependencies from latest published version, not the one present locally 2) If you got here because of unmet dependencies for a private extension (not present on TER), you get $extension == NULL and checkDependencies fatals with an invalid arguement. In both cases what we actually need is a dumb $extension variable of type Extension with the serializedDependencies attribute set to what is present in the locally available ext_emconf.php, nothing else, so we could possibly instantiate this class here, or pass an extensionKey to checkDependencies() instead of an object. -
Nicole Hummel commented on patch set 13 06/10/14, 13:58
@Xavier Can you describe your test scenario? -
Mr. Jenkins commented on patch set 13 06/10/14, 14:03
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16614/ : SUCCESS -
Nicole Hummel commented on patch set 13 06/10/14, 14:03
@lorenz: I would really prefer to have a translation follow up afterwards as all exception messages have to be translated as well!
-
Xavier Perseguers commented on patch set 13 06/10/14, 14:21
@Nicole, please see my comment. You can reproduce by having a private extension (not published = not existing on TER) having unmet dependencies such as 'typo3' => '4.5.0-4.5.99' and trying to activate/load it in EM -
Nicole Hummel uploaded patch set 14 06/10/14, 21:47
-
Nicole Hummel uploaded patch set 15 06/10/14, 21:57
-
Mr. Jenkins commented on patch set 14 06/10/14, 22:01
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16634/ : SUCCESS -
Mr. Jenkins commented on patch set 15 06/10/14, 22:11
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16635/ : SUCCESS -
Markus Klein commented on patch set 15 06/11/14, 00:34
UnresolvedDependenciesMessage.html:1Why do we have the non-English sentence here again?? see comments in patchset 9 -
Xavier Perseguers commented on patch set 15 06/11/14, 06:50
UnresolvedDependenciesMessage.html:1ReplyBecause Nicole did not get the patch from Gerrit but changed her own locally. -
Xavier Perseguers commented on patch set 15 06/11/14, 06:51
Working on it, please do not change anything :) -
Xavier Perseguers uploaded patch set 16 06/11/14, 07:15
-
Xavier Perseguers voted on patch set 16 V +1 CR +1 06/11/14, 07:16
-
Mr. Jenkins commented on patch set 16 06/11/14, 07:29
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16637/ : SUCCESS -
Markus Klein commented on patch set 16 CR +1 06/11/14, 07:41
For my knowledge, why do you remove the xml:space thing sometimes? What is this good for in general? -
Xavier Perseguers commented on patch set 16 06/11/14, 08:08
it only makes sense if you really need to ensure whitespaces are kept as this (on Pootle), not sure it is even taken into account in TYPO3 but it should as it's standard XML parser instruction: https://lists.oasis-open.org/archives/xliff/200802/msg00012.html Anyway, we don't need it in 99% of the case and when we would need it, I'd say that chance is much too high that translators won't keep the exact same whitespace structure so we should not rely on it anyway. Writing XLIFF is already described as more complex than ll-XML, let's try to make it as simple as possible by removing what is not actually mandatory :) -
Markus Klein commented on patch set 16 06/11/14, 08:14
Thanks for explaining this to me. -
Nicole Hummel commented on patch set 16 06/11/14, 08:48
@Markus: I checked the comments from patch set 9 and changed the text to Xavier's suggestion. What was wrong with that? -
Nicole Hummel commented on patch set 16 V -1 06/11/14, 08:49
Still installation messages missing after upload an extension. I'm working on that -
Steffen Ritter commented on patch set 16 06/11/14, 09:13
is that really related to this issue or can we split that into another patchset? -
Nicole Hummel commented on patch set 16 06/11/14, 09:43
@Steffen: If you mean the notifications after installation - they were there before and should be there after the patch. So this belongs into it -
Nicole Hummel uploaded patch set 17 06/11/14, 10:40
-
Mr. Jenkins commented on patch set 17 06/11/14, 10:56
Build Successful https://ci.typo3.org/job/typo3-v4-core-gerrit/16652/ : SUCCESS -
Xavier Perseguers voted on patch set 17 V +1 CR +1 06/11/14, 12:39
-
Markus Klein commented on patch set 17 CR +1 06/11/14, 13:41
@Nicole: it was about the first sentence. -
Zbigniew Jacko voted on patch set 17 V +1 CR +1 06/11/14, 14:43
-
Xavier Perseguers voted on patch set 17 V +2 CR +2 06/11/14, 14:49
-
Xavier Perseguers merged patch set 18 06/11/14, 14:49