(07-14-2022, 04:17 AM)MGatner Wrote: That applet intentionally locks composer.json to the requested version. If you want to update it later you will need to modify composer.json and change the requirement back to an open-ended dependency (like `^4.1`)
Hi, Thank you for the feedback and help. This is what i did:
(1) Create a new CI4 "ci4tst" using "php ci4-install.php ci4tst 4.1.9" - successful but failed on this lines:
Code:
cd ci4tst; composer require -W codeigniter4/framework:4.1.9
The system cannot find the path specified.
(2) ran the commands manually - successful
(3) ran the php spark to test - successful, shows version 4.1.9
(4) Edited composer.json as:
Code:
"require": {
"php": "^7.3 || ^8.0",
"codeigniter4/framework": "^4.1"
},
(5) Delete vendor folder and ran composer install - successful
(6) Ran "composer update". Generates the following messages:
Code:
Loading composer repositories with package information
Info from https://repo.packagist.org: #StandWithUkraine
Updating dependencies
Lock file operations: 0 installs, 1 update, 0 removals
- Upgrading codeigniter4/framework (v4.1.9 => v4.2.1)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 0 installs, 1 update, 0 removals
- Upgrading codeigniter4/framework (v4.1.9 => v4.2.1): Extracting archive
Generating autoload files
27 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
(7) Ran php spark - failed with the messages:
Code:
PHP Fatal error: Uncaught TypeError: Argument 1 passed to CodeIgniter\CLI\Console::__construct() must be an instance of CodeIgniter\CodeIgniter, int given, called in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\spark on line 48 and defined in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\vendor\codeigniter4\framework\system\CLI\Console.php:29
Stack trace:
#0 C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\spark(48): CodeIgniter\CLI\Console->__construct(1)
#1 {main}
thrown in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\vendor\codeigniter4\framework\system\CLI\Console.php on
line 29
Fatal error: Uncaught TypeError: Argument 1 passed to CodeIgniter\CLI\Console::__construct() must be an instance of CodeIgniter\CodeIgniter, int given, called in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\spark on line 48 and defined in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\vendor\codeigniter4\framework\system\CLI\Console.php:29
Stack trace:
#0 C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\spark(48): CodeIgniter\CLI\Console->__construct(1)
#1 {main}
thrown in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\vendor\codeigniter4\framework\system\CLI\Console.php on
line 29
Any advise. We could always install the latest version and add the codes from the older version. But there are times when I find using the latest version, the apps produces different results or breaks and I need confirm that it is not due to the latest version. I hope you understand my needs.
(07-14-2022, 05:17 AM)murugappan Wrote: (07-14-2022, 04:17 AM)MGatner Wrote: That applet intentionally locks composer.json to the requested version. If you want to update it later you will need to modify composer.json and change the requirement back to an open-ended dependency (like `^4.1`)
Hi, Thank you for the feedback and help. This is what i did:
(1) Create a new CI4 "ci4tst" using "php ci4-install.php ci4tst 4.1.9" - successful but failed on this lines:
Code:
cd ci4tst; composer require -W codeigniter4/framework:4.1.9
The system cannot find the path specified.
(2) ran the commands manually - successful
(3) ran the php spark to test - successful, shows version 4.1.9
(4) Edited composer.json as:
Code:
"require": {
"php": "^7.3 || ^8.0",
"codeigniter4/framework": "^4.1"
},
(5) Delete vendor folder and ran composer install - successful
(6) Ran "composer update". Generates the following messages:
Code:
Loading composer repositories with package information
Info from https://repo.packagist.org: #StandWithUkraine
Updating dependencies
Lock file operations: 0 installs, 1 update, 0 removals
- Upgrading codeigniter4/framework (v4.1.9 => v4.2.1)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 0 installs, 1 update, 0 removals
- Upgrading codeigniter4/framework (v4.1.9 => v4.2.1): Extracting archive
Generating autoload files
27 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
(7) Ran php spark - failed with the messages:
Code:
PHP Fatal error: Uncaught TypeError: Argument 1 passed to CodeIgniter\CLI\Console::__construct() must be an instance of CodeIgniter\CodeIgniter, int given, called in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\spark on line 48 and defined in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\vendor\codeigniter4\framework\system\CLI\Console.php:29
Stack trace:
#0 C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\spark(48): CodeIgniter\CLI\Console->__construct(1)
#1 {main}
thrown in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\vendor\codeigniter4\framework\system\CLI\Console.php on
line 29
Fatal error: Uncaught TypeError: Argument 1 passed to CodeIgniter\CLI\Console::__construct() must be an instance of CodeIgniter\CodeIgniter, int given, called in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\spark on line 48 and defined in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\vendor\codeigniter4\framework\system\CLI\Console.php:29
Stack trace:
#0 C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\spark(48): CodeIgniter\CLI\Console->__construct(1)
#1 {main}
thrown in C:\xampp\htdocs\MyDevelop\ci4vanilla\ci4tst\vendor\codeigniter4\framework\system\CLI\Console.php on
line 29
Any advise. We could always install the latest version and add the codes from the older version. But there are times when I find using the latest version, the apps produces different results or breaks and I need confirm that it is not due to the latest version. I hope you understand my needs.
Previously we had, i think under CI3, we could run composer to install older version and they worked fine.