Page 1 of 1

Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Tue Aug 27, 2024 5:39 am
by bnreddy1989

Hi, I am getting this error while generating files,

Error: Command failed: composer update -n --ansi
    at genericNodeError (node:internal/errors:984:15)
    at wrappedFn (node:internal/errors:538:14)
    at checkExecSyncError (node:child_process:891:11)
    at execSync (node:child_process:963:15)
    at global.Exec (C:\Users\User\AppData\Roaming\PHPMaker2024\node_modules\@phpmaker\core\phpmaker.js:8:316156)
    at global.RunComposerUpdate (C:\Users\User\AppData\Roaming\PHPMaker2024\node_modules\@phpmaker\core\phpmaker.js:8:325094)
    at C:\Users\User\AppData\Roaming\PHPMaker2024\node_modules\@phpmaker\core\phpmaker.js:8:335186
    at <anonymous>
    at async main (C:\Users\User\AppData\Roaming\PHPMaker2024\node_modules\@phpmaker\core\phpmaker.js:8:334887) {
  status: 2,
  signal: null,
  output: [ null, null, null ],
  pid: 9636,
  stdout: null,
  stderr: null
}
Node.js v20.17.0
Error: Generation completed with error(s), please scroll up (if necessary) to check error(s).

and when i run code, iam getting this error

Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory in C:\xampp\htdocs\aca\index.php on line 24

Fatal error: Uncaught Error: Failed opening required 'vendor/autoload.php' (include_path='C:\xampp\php\PEAR') in C:\xampp\htdocs\aca\index.php:24 Stack trace: #0 {main} thrown in C:\xampp\htdocs\aca\index.php on line 24

Please help me on this


Re: Vendoe autoload php eerror

Posted: Tue Aug 27, 2024 10:30 am
by mobhar

Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Tue Aug 27, 2024 11:28 am
by arbei

Read Composer. Make sure you have done composer update successfully.


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Tue Aug 27, 2024 8:04 pm
by bnreddy1989

How to do this "Open a command prompt at the project folder and run: composer update."?
Please explain me clearly.


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Tue Aug 27, 2024 8:34 pm
by arbei

If you don't know how, you may simply delete "vendor" folder (if exists) in your project folder and generate all files again. The "composer update" will be run automatically, watch the messages shown in the progress form, you should see the progress of composer update, do not ignore any errors. You can also easily google "php composer update" to find a lot of info.


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Wed Aug 28, 2024 7:54 pm
by bnreddy1989

I have latest version composer, but still i am getting this error. why?


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Thu Aug 29, 2024 8:38 am
by mobhar

arbei wrote:

If you don't know how, you may simply delete "vendor" folder (if exists) in your project folder and generate all files again.

Have you already done that? The "vendor" folder is located under the root folder of your generated web application.


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Fri Aug 30, 2024 5:36 am
by bnreddy1989

I don't have any vendor folder, i tried once again to generate all files and same error getting at 99%


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Mon Sep 02, 2024 9:46 am
by arbei

arbei wrote:

Make sure you have done composer update successfully.

The "composer update" will be run automatically, watch the messages shown in the progress form, you should see the progress of composer update, do not ignore any errors.

  1. Make sure you select a writable project folder, e.g. D:\MyProjectFolder, avoid C:\xxx, remote folder, OneDrive, GoogleDrive which you mau not have write permission.
  2. Enable Composer Update when you generate, and generate all files. Do not ignore errors, post the errors you see.
  3. Read Composer again, follow the instructions and test your PC, make sure you have installed Composer and and it is working properly.

Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Tue Sep 03, 2024 7:30 am
by bnreddy1989

Hi,
I did as i understood but no result.


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Wed Sep 04, 2024 5:24 am
by ries

What worked for me was enabling the zip extension in php.ini.
[;extension=zip] -> [extension=zip] so delete point comma.


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Wed Sep 04, 2024 11:25 am
by mobhar

If you are a registered user, you may send your .pmp and .sql files to Support and another more info for checking.


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Sat Sep 07, 2024 1:57 pm
by bnreddy1989

I am not registered user,How to solve this?


Re: Warning: require_once(vendor/autoload.php): Failed to open stream: No such file or directory

Posted: Sat Sep 07, 2024 3:12 pm
by mobhar

To be a registered user of PHPMaker, then you need to purchase PHPMaker.