Closed mrothauer closed 10 months ago
Do u want to make a PR removing all those property usage? Or just adding the missing property?
The alternative I would prefer right now is to set the attribute for it.
#[AllowDynamicProperties]
This has less changes and thus less possible negative side effects for now.
Do u want to make a PR removing all those property usage? Or just adding the missing property?
This time, I prefer not to be involved in fixing my issue. If that's ok for you.
I started https://github.com/dereuromark/cakephp-queue/pull/389 I will see what can be done regarding the loadModel() calls. Adding the property doesnt work and creates errors. So either we refactor fully or we need to silence the deprecations if attribute is there
https://github.com/dereuromark/cakephp-queue/releases/tag/6.8.0 should already help a bit with deprecations
Thanks. I updated my app but I still get the same deprecation message.
Well, the main issue wont go away unless we ship https://github.com/cakephp/cakephp/pull/17383 and you use PHP 8.2+
The alternative would be to completely refactor away from properties and use fetchTable() everywhere, similar to what already done in 5.x version I assume.
Well, the main issue wont go away unless we ship cakephp/cakephp#17383 and you use PHP 8.2+
Ok, thank you for the clarification. I'll wait for that.
I am not sure it is gonna happen You could backport similar changes as https://github.com/dereuromark/cakephp-queue/compare/7.0.0-RC...7.0.0 to Cake4 branch. Then we can release a patch here.
If its fixed when I switch to CakePHP 5, thats fine for me. So I won't backport the changings.
the command
bin/cake queue worker end server
triggers a deprecation messageCakePHP 4.5.0 Queue-Version: 6.7.2
4.5.0 - Dynamic properties will be removed in PHP 8.2. Add
public $QueueProcesses = null;
to your class definition. /my-app/vendor/cakephp/cakephp/src/Command/Command.php, line: 56 You can disable all deprecation warnings by settingError.errorLevel
toE_ALL & ~E_USER_DEPRECATED
. Addingvendor/cakephp/cakephp/src/Command/Command.php
toError.ignoredDeprecationPaths
in yourconfig/app.php
config will mute deprecations from that file only. Trace: /my-app/vendor/cakephp/cakephp/src/Core/functions.php /my-app/vendor/cakephp/cakephp/src/Core/functions.php, line 300 /my-app/vendor/cakephp/cakephp/src/Datasource/ModelAwareTrait.php /my-app/vendor/cakephp/cakephp/src/Datasource/ModelAwareTrait.php, line 122 Cake\Command\Command->loadModel() /my-app/vendor/cakephp/cakephp/src/Command/Command.php, line 56 Cake\Command\Command->__construct() /my-app/vendor/cakephp/cakephp/src/Console/CommandFactory.php, line 51 Cake\Console\CommandFactory->create() /my-app/vendor/cakephp/cakephp/src/Console/CommandRunner.php, line 375 Cake\Console\CommandRunner->createCommand() /my-app/vendor/cakephp/cakephp/src/Console/CommandRunner.php, line 248 Cake\Console\CommandRunner->getCommand() /my-app/vendor/cakephp/cakephp/src/Console/CommandRunner.php, line 167 Cake\Console\CommandRunner->run() /my-app/bin/cake.php, line 12