Maybe you can help me. I have composer working in my MAMP environment. I successfully added a package and it is executing in my php code. I then copied the code folder, including the .json and .lock file into a new folder (the folder is at the same directory level as the original code folder). When I execute the new code folder, I get an error on one package that the class is not found.
Exception has occurred.
Error: Class 'BenMorel\GsmCharsetConverter\Converter' not found
Why would the exception occur on code in one folder but not the other? What is getting lost on the copy?
Ok, I solved my own problem, but not sure why what I did was necessary. So maybe you could educate me.
I ran php composer.phar update on the new directory and that corrected the problem. Why would one package require phar update be run, when the package ran on the folder it came from?
Any help would be greatly appreciated.
Also, I should have mentioned that there are not hardcoded directory paths in the app. All paths are relative.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Mr. DeChamp,
Maybe you can help me. I have composer working in my MAMP environment. I successfully added a package and it is executing in my php code. I then copied the code folder, including the .json and .lock file into a new folder (the folder is at the same directory level as the original code folder). When I execute the new code folder, I get an error on one package that the class is not found.
Exception has occurred.
Error: Class 'BenMorel\GsmCharsetConverter\Converter' not found
Why would the exception occur on code in one folder but not the other? What is getting lost on the copy?
Ok, I solved my own problem, but not sure why what I did was necessary. So maybe you could educate me.
I ran php composer.phar update on the new directory and that corrected the problem. Why would one package require phar update be run, when the package ran on the folder it came from?
Any help would be greatly appreciated.
Also, I should have mentioned that there are not hardcoded directory paths in the app. All paths are relative.