74441[BUGFIX] Remove invalid definition of method body functionality
Commit message
Review
-
Code review CR +2 Done
- Benni Mack +2
- Stefan Bürk +1
-
Verified V +2 Done
- Benni Mack +2
- Stefan Bürk +1
- core-ci +1 CI
Issues 1
Files 1
Review log 1524
-
Simon Schaufelberger uploaded patch set 1 04/26/22, 22:03
-
core-ci voted on patch set 1 V -1 04/26/22, 22:20 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/26484
-
core-ci commented on patch set 1 04/26/22, 22:25 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/26484
-
Simon Schaufelberger uploaded patch set 2 04/27/22, 01:11
-
Stefan Bürk commented on patch set 2 04/27/22, 01:17
FlexFormTools.php:702Block L696 -> L702 is the same as L687 -> L693. At least a new exception code must be used for the cloned code, which core ci is complaining about. Do you think we can came up with a code variant avoiding the duplicated code - and eventually using the same exception code for both variants ? (just saw you uploaded a change - so extending this comment): Simply increase a exception by one is not how the core handles exception codes. Exception codes are the current unix-timestamp when adding the code. You may use ``` date +%s ``` for it to retrieve one - at least on a linux/mac system. Not sure about windows. -
core-ci voted on patch set 2 V -1 04/27/22, 01:43 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/26492
-
core-ci commented on patch set 2 04/27/22, 02:29 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/26492
-
Simon Schaufelberger commented on patch set 2 04/27/22, 11:21
FlexFormTools.php:563ReplyI googled a bit and couldn't find any documentation for it. I also didn't really understand what it means but as you see in the forge issue, somebody found it ;) Honestly, I feel like to just remove this line in the docblock and call this "fixed" as it's undocumented (afaik) and you can just use the "FILE:EXT:" syntax.FlexFormTools.php:702ReplyI tried to think about a "both" solution but the substring is different for both cases. Does somebody care which date the exception code represents as long as it's unique? -
Stefan Bürk commented on patch set 2 04/27/22, 13:39
FlexFormTools.php:702ReplySure. Given block/lines do not include the $file line and thus the substrig. that must me done with a switch. ``` $file = ''; if (str_starts_with(trim($dataStructure), 'FILE:')) { $file = GeneralUtility::getFileAbsFileName(substr(trim($dataStructure), 5)); } elseif ((str_starts_with(trim($dataStructure), 'EXT:'))) { $file = GeneralUtility::getFileAbsFileName(substr(trim($dataStructure), 0)); } if (empty($file) || !@is_file($file)) { throw new \RuntimeException( 'Data structure file ' . $file . ' could not be resolved to an existing file', 1478105826 ); } $dataStructure = (string)file_get_contents($file); ``` In the end, it must be unique. However, it's practice to use the current timestamp. Side effect is, the code automaticlly states (round about) when the exception was added to the core. Not sure about a hard rule here, but in the end this is the way it has be done and I think keep that up would not be that bad. -
core-ci voted on patch set 2 V +1 04/27/22, 14:15 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/26492
-
Simon Schaufelberger uploaded patch set 3 04/28/22, 00:07
-
Simon Schaufelberger commented on patch set 2 04/28/22, 00:08
FlexFormTools.php:702ReplyDone -
core-ci voted on patch set 3 V -1 04/28/22, 00:13 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/26541
-
Simon Schaufelberger commented on patch set 3 04/28/22, 00:19
FlexFormTools.php:563Reply -
Simon Schaufelberger commented on patch set 3 04/28/22, 00:26
FlexFormTools.php:563Replyeven in the oldest available documentation https://docs.typo3.org/m/typo3/reference-tca/6.2/en-us/Reference/Columns/Flex/Index.html#ds this is documented with "FILE:EXT:" prefix so in my opinion the code should be reverted and line 563 dropped. -
Simon Schaufelberger uploaded patch set 4 04/28/22, 00:33
-
Simon Schaufelberger commented on patch set 4 04/28/22, 00:34
FlexFormTools.php:563ReplyDone -
core-ci voted on patch set 4 V +1 04/28/22, 00:45 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/26542
-
Simon Schaufelberger rebased onto patch set 5 04/30/22, 15:17
-
core-ci voted on patch set 5 V -1 04/30/22, 15:51 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/26695
-
core-ci voted on patch set 5 V +1 04/30/22, 16:56 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/26695
-
Stefan Bürk voted on patch set 5 V +1 CR +1 04/30/22, 19:30
-
Benni Mack voted on patch set 5 V +2 CR +2 05/02/22, 14:07
-
Benni Mack merged patch set 6 05/02/22, 14:07
FlexFormTools.php:563