- Issue created by @longwave
- 🇬🇧United Kingdom longwave UK
Either value are not always present in prop source arrays, in which case we need to fix
Line src/PropSource/StaticPropSource.php ------ ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 205 Offset 'value' does not exist on array{sourceType: string, expression: string, value?: mixed, sourceTypeSettings?: array{instance?: array<string, mixed>, storage?: array<string, mixed>}}. 211 Offset 'value' does not exist on array{sourceType: string, expression: string, value?: mixed, sourceTypeSettings?: array{instance?: array<string, mixed>, storage?: array<string, mixed>}}. 212 Offset 'value' does not exist on array{sourceType: string, expression: string, value?: mixed, sourceTypeSettings?: array{instance?: array<string, mixed>, storage?: array<string, mixed>}}. 216 Offset 'value' does not exist on array{sourceType: string, expression: string, value?: mixed, sourceTypeSettings?: array{instance?: array<string, mixed>, storage?: array<string, mixed>}}. 218 Offset 'value' does not exist on array{sourceType: string, expression: string, value?: mixed, sourceTypeSettings?: array{instance?: array<string, mixed>, storage?: array<string, mixed>}}. 221 Offset 'value' does not exist on array{sourceType: string, expression: string, value?: mixed, sourceTypeSettings?: array{instance?: array<string, mixed>, storage?: array<string, mixed>}}.
or they are, and we need to fix
Line src/PropSource/DynamicPropSource.php ------ ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 37 Method Drupal\experience_builder\PropSource\DynamicPropSource::toArray() should return array{sourceType: string, adapterInputs: array<string, mixed>}|array{sourceType: string, expression?: string, value: mixed, sourceTypeSettings?: array{instance?: array<string, mixed>, storage?: array<string, mixed>}} but returns array{sourceType: string, expression: string}. 💡 Array does not have offset 'adapterInputs'. 💡 Array does not have offset 'value'.
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
+1 for the principle for sure!
- 🇧🇷Brazil natnatalia
Hello,
I’ve fixed the previous errors related to the src/PropSource/StaticPropSource.php file.
Since the branch was quite outdated, I had to rebase it. After rebasing, the PR started showing the following errors:
------ --------------------------------------------------------------------------------------------------- Line src/Plugin/ExperienceBuilder/ComponentSource/GeneratedFieldExplicitInputUxComponentSourceBase.php ------ --------------------------------------------------------------------------------------------------- 178 Class Drupal\experience_builder\Plugin\ExperienceBuilder\ComponentSource\ComponentInputs not found. 💡 Learn more at https://phpstan.org/user-guide/discovering-symbols 179 Call to method getValues() on an unknown class Drupal\experience_builder\Plugin\ExperienceBuilder\ComponentSource\ComponentInputs. 💡 Learn more at https://phpstan.org/user-guide/discovering-symbols ------ --------------------------------------------------------------------------------------------------- [ERROR] Found 2 errors
To fix the first one, I believe I need to add:
use Drupal\experience_builder\Plugin\DataType\ComponentInputs;
However, I’m unsure whether this ComponentInputs class is the intended one, as the error references:
Drupal\experience_builder\Plugin\ExperienceBuilder\ComponentSource\ComponentInputs
Could someone clarify if these refer to the same class or if the correct one is missing from the patch?
I would like to continue working on this.
Thanks! - 🇪🇸Spain penyaskito Seville 💃, Spain 🇪🇸, UTC+2 🇪🇺
Apparently something went wrong during the rebase.
Cleanest+easiest way forward might be opening a new MR from a new branch up-to-date with 0.x.Check https://git.drupalcode.org/project/experience_builder/-/merge_requests/6... for the starting point that @longwave did.
- First commit to issue fork.
- 🇮🇳India omkar-pd
Created new PR from https://git.drupalcode.org/project/experience_builder/-/merge_requests/6...
- 🇮🇳India meghasharma
The PHPStan error regarding the $prop_source parameter still needs to be fixed.