![]() |
Can't create a working CI4 project after 4.3.8 and 4.4 - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30) +--- Thread: Can't create a working CI4 project after 4.3.8 and 4.4 (/showthread.php?tid=88351) |
Can't create a working CI4 project after 4.3.8 and 4.4 - gosocial2 - 08-26-2023 Hello guys, Thrilled with the announcement of CodeIgniter 4.3.8 and 4.4.0, I went ahead and tried to experiment with it. To be safe, I opted in to create a new project based on 4.3.8 rather than trying to update my existing ones. What I did: I fired up a Terminal and typed in Code: composer create-project codeigniter4/appstarter:4.3.8 ci438 At first, I didn't pay much attention what exact version Composer spitted out, as in most cases things go as expected given my PHP and Composer versions are right. But I repeated this step in the end as you will see towards the bottom of this post. Then Code: php spark serve The class in question (i.e. CodeIgniter.php) has: PHP Code: /** It turns out that my extra arguments to enforce pulling 4.3.8 did not work, or the composer repositories holds a messed up "CodeIgniter 4.3.8 version mixed with 4.4.0 files". I also tried: Code: composer create-project codeigniter4/appstarter ci438alt "4.3.8" The above does not produce a different result when I execute "php spark serve". To be sure I ultimately ran the below. Code: % php -v RE: Can't create a working CI4 project after 4.3.8 and 4.4 - captain-sensible - 08-26-2023 what does the file composer.json show is it : Code: "codeigniter4/framework": "^4.0" if you want specifically 4.3.8 then try deleting any composer.json lock file . edit to : Code: "codeigniter4/framework": "4.3.8" then from memory change directory of terminal to your web root and run : Code: composer install --no-dev RE: Can't create a working CI4 project after 4.3.8 and 4.4 - ozornick - 08-26-2023 I may be wrong, but appstarter always uses the latest version. You are trying to install a version of the framework, but choose appstarter RE: Can't create a working CI4 project after 4.3.8 and 4.4 - kenjis - 08-26-2023 Yes, appstarter always installs the latest version of the framework. See https://github.com/codeigniter4/appstarter/blob/81e89ce6e7f807cdd5e2285c899ce5dc777acdf7/composer.json#L14 There is no official way to install past version with appstarter. But you can do it with the following script: https://github.com/kenjis/ci4-composer-installer RE: Can't create a working CI4 project after 4.3.8 and 4.4 - gosocial2 - 08-26-2023 Captain-sensible's recommendation worked: Code: composer require codeigniter4/framework:4.3.8 But I will also be trying kenjis's ci4-composer-installer next time. RE: Can't create a working CI4 project after 4.3.8 and 4.4 - Muzikant - 09-01-2023 I had the same problem.
|