CodeIgniter v4.3.8 and v4.4.0 Released! |
I have CRITICAL
PHP Code: CRITICAL - 2023-08-26 12:35:07 --> CodeIgniter\Router\RouteCollection::__construct(): Argument #3 ($routing) must be of type Config\Routing, null given, called in /home/xvcoagjb/abc.com/vendor/codeigniter4/framework/system/Config/Services.php on line 617 Learning CI4 from my works, from errors and how to fix bugs in the community Love CI & Thanks CI Teams
Thank you CodeIgniter Development Team Great Job!
What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
Quote:Now preferApp works only when you request a classname without a namespace. See https://codeigniter4.github.io/CodeIgnit...#factories Your case is the same thing. Previously, classes were searched by short classname alone, but starting with 4.4.0, classes with namespaces are now searched only for that specified class.
After update I've got a little problem:
Call to undefined method Myth\Auth\Entities\User::getAvatar() Im just trying to echo it in controller App\Controllers\Page PHP Code: echo user()->getAvatar() Thanks in advance for any help. App\Entities\User PHP Code: <?php namespace App\Entities;
Hi, after upgrade to 4.4.0 I have the following CRITICAL error:
CRITICAL - 2023-08-28 17:49:27 --> assert($currentURI instanceof SiteURI) in SYSTEMPATH\Helpers\url_helper.php on line 34. 1 SYSTEMPATH\Helpers\url_helper.php(34): assert(false, 'assert($currentURI instanceof SiteURI)') 2 SYSTEMPATH\Helpers\url_helper.php(151): site_url('/battle/view/7', null, Object(Config\App)) 3 APPPATH\Models\BattleModel.php(865): anchor('/battle/view/7', 'here')stdClass This piece of code creates it: PHP Code: $characterevent_model->add(1, 'towncrier', "App.event_battleexecuted;". $this->battle['id'] ."," . Any clue? Thanks
@chaos Did you customize Services for URI or Request?
Since v4.4.0, Services::request()->getUri() must return the SiteURI instance. https://codeigniter4.github.io/CodeIgnit...ri-changes
I upgraded my system to the latest version; I hadn't experienced any issues with any version until today when I updated to version v4.4.0. Now, I'm encountering an error as if it can't find the ENVIRONMENT in the Codeigniter.php file:
Fatal error: Uncaught Error: Undefined constant "CodeIgniter\ENVIRONMENT" in /mysite.com/vendor/codeigniter4/framework/system/CodeIgniter.php:581 When opening the file, I do see the definition of the ENVIRONMENT variable. protected function detectEnvironment() { // Make sure ENVIRONMENT isn't already set by other means. if (! defined('ENVIRONMENT')) { define('ENVIRONMENT', env('CI_ENVIRONMENT', 'production')); } } /** * Load any custom boot files based upon the current environment. * * If no boot file exists, we shouldn't continue because something * is wrong. At the very least, they should have error reporting setup. */ protected function bootstrapEnvironment() { if (is_file(APPPATH . 'Config/Boot/' . ENVIRONMENT . '.php')) { require_once APPPATH . 'Config/Boot/' . ENVIRONMENT . '.php'; } else { // @codeCoverageIgnoreStart header('HTTP/1.1 503 Service Unavailable.', true, 503); echo 'The application environment is not set correctly.'; exit(EXIT_ERROR); // EXIT_ERROR // @codeCoverageIgnoreEnd } }
@emacdev
There are some breaking changes in v4.4.0, so please upgrade with caution. Please read ChangeLog and Upgrading Guide very carefully: - https://codeigniter4.github.io/CodeIgnit...4.4.0.html - https://codeigniter4.github.io/CodeIgnit...e_440.html |
Welcome Guest, Not a member yet? Register Sign In |