Log message #4210069

# At Username Text
# Oct 22nd 2019, 20:09 daniel.upshaw I've been really struggling with this as you might be able to tell, haha
# Oct 22nd 2019, 20:08 daniel.upshaw Your Bash script can just `source .env` and it can, say for example, utilize the Slack API key to send alerts..... really handy!
# Oct 22nd 2019, 20:07 daniel.upshaw So once I got used to being able to conveniently access the config from Docker, Vagrant, Ansible, Bash, other apps, and it's all tidy in there... and scalable to stuff like Hashicorp Vault etc.... finding out people's issues with it, has become a real roadblock to putting it in practice
# Oct 22nd 2019, 20:04 daniel.upshaw It's really puzzling to me because I found that aspect of them to be really appealing
# Oct 22nd 2019, 20:04 daniel.upshaw If you have two applications that need to be able to pull some common config.... then it's right there, and DRY, all in one place
# Oct 22nd 2019, 20:03 daniel.upshaw Well there are so many other benefits... e.g., Bash can natively read .env
# Oct 22nd 2019, 20:02 admad no, just don't use env vars
# Oct 22nd 2019, 20:01 daniel.upshaw This would scope it to the application... more secure, yes?
# Oct 22nd 2019, 20:01 daniel.upshaw True.... although then it puts them global to the whole environment
# Oct 22nd 2019, 20:01 admad or unless you are going to deploy on cloud providers which use env vars don't use .env files at all :slightly_smiling_face:
# Oct 22nd 2019, 19:58 daniel.upshaw Interesting concept here: https://github.com/jchook/dotenv-to-php
# Oct 22nd 2019, 18:44 luizcmarin yes. bootstrap.php
# Oct 22nd 2019, 18:42 admad @luizcmarin update "use" statement in you app's `config/bootstrap.php`
# Oct 22nd 2019, 18:41 ndm 99.9% chance it's in bootstrap.php
# Oct 22nd 2019, 18:40 luizcmarin ah, ok.
# Oct 22nd 2019, 18:40 ricksaccous you need to find it in your app code
# Oct 22nd 2019, 18:40 ricksaccous you don't want to touch that
# Oct 22nd 2019, 18:40 ricksaccous that's the core code
# Oct 22nd 2019, 18:39 luizcmarin ... and now?
# Oct 22nd 2019, 18:39 luizcmarin <?php declare(strict_types=1); class_alias( 'Cake\Error\ConsoleErrorHandler', 'Cake\Console\ConsoleErrorHandler' ); deprecationWarning( 'Use Cake\Error\ConsoleErrorHandler instead of Cake\Console\ConsoleErrorHandler.' );
# Oct 22nd 2019, 18:39 luizcmarin ok. localized
# Oct 22nd 2019, 18:38 daniel.upshaw Thank you :slightly_smiling_face:
# Oct 22nd 2019, 18:38 daniel.upshaw I did not see this before
# Oct 22nd 2019, 18:38 daniel.upshaw Oh! This is awesome
# Oct 22nd 2019, 18:38 daniel.upshaw https://github.com/CakeDC/users-example/tree/develop-extend-plugin
# Oct 22nd 2019, 18:37 daniel.upshaw Yes, I followed the instructions there
# Oct 22nd 2019, 18:33 ricksaccous that's the wrong place to look, just do a grep for Cake\Console\ConsoleErrorHandler
# Oct 22nd 2019, 18:31 luizcmarin @ricksaccous do what in this line?
# Oct 22nd 2019, 18:30 slackebot1 <luizcmarin>
# Oct 22nd 2019, 18:28 ricksaccous to*
# Oct 22nd 2019, 18:28 ricksaccous just update that thing it's telling you too ;)
# Oct 22nd 2019, 18:25 luizcmarin I just updated cake4 and got this message. Everything is OK?
# Oct 22nd 2019, 18:24 slackebot1 <luizcmarin>
# Oct 22nd 2019, 17:45 coreus Oh right. I just figured. Thank you!
# Oct 22nd 2019, 17:45 admad just blitz your cache :slightly_smiling_face:
# Oct 22nd 2019, 17:43 slackebot1 Cake\Http\Runner::handle() - CORE\src\Http\Runner.php, line 73 Cake\Http\Middleware\CsrfProtectionMiddleware::process() - CORE\src\Http\Middleware\CsrfProtectionMiddleware.php, line 123 Cake\Http\Runner::handle() - CORE\src\Http\Runner.php, line 73 ``` What's that all about?
# Oct 22nd 2019, 17:43 slackebot1 Cake\Http\ControllerFactory::create() - CORE\src\Http\ControllerFactory.php, line 50 Cake\Http\ActionDispatcher::dispatch() - CORE\src\Http\ActionDispatcher.php, line 61 Cake\Http\BaseApplication::handle() - CORE\src\Http\BaseApplication.php, line 206 Cake\Http\Runner::handle() - CORE\src\Http\Runner.php, line 77 Cake\Routing\Middleware\RoutingMiddleware::process() - CORE\src\Routing\Middleware\RoutingMiddleware.php, line 156
# Oct 22nd 2019, 17:43 slackebot1 Cake\ORM\Query::_all() - CORE\src\Datasource\QueryTrait.php, line 289 Cake\ORM\Query::all() - CORE\src\ORM\Query.php, line 1046 Cake\ORM\Query::first() - CORE\src\Datasource\QueryTrait.php, line 443 App\Controller\AppController::initialize() - APP/Controller\AppController.php, line 106 Cake\Controller\Controller::__construct() - CORE\src\Controller\Controller.php, line 212 ReflectionClass::newInstance() - [internal], line ??
# Oct 22nd 2019, 17:43 coreus Hmm, the FileEngine cacher is complaining with a notice after going from 4.0.0-beta3 to 4.0.0-beta4: ``` Notice (8): unserialize(): Error at offset 24 of 1206 bytes [CORE\src\Cache\Engine\FileEngine.php, line 201] Code Context unserialize - [internal], line ?? Cake\Cache\Engine\FileEngine::get() - CORE\src\Cache\Engine\FileEngine.php, line 201 Cake\Datasource\QueryCacher::fetch() - CORE\src\Datasource\QueryCacher.php, line 78
# Oct 22nd 2019, 17:40 johizzle @javier.villanueva try $user = $this->get($user_id, ['contain' => ['Groups']]); if that doesn't work, you can try creating the field in the form as groups._ids, it should work straight forward from there
# Oct 22nd 2019, 16:42 noel Must be routing I guess