I tried installing laravel/passport by running composer require laravel/passport and it gives me error saying :
Your requirements could not be resolved to an installable set of packages.
Problem 1
- lcobucci/jwt 4.2.x-dev requires ext-sodium * -> the requested PHP extension sodium is missing from your system.
- lcobucci/jwt 4.1.x-dev requires ext-sodium * -> the requested PHP extension sodium is missing from your system.
- lcobucci/jwt 4.1.0 requires ext-sodium * -> the requested PHP extension sodium is missing from your system.
- Conclusion: don't install laravel/passport v10.1.0
- Conclusion: remove lcobucci/jwt 3.3.3
- Installation request for laravel/passport ^10.1 -> satisfiable by laravel/passport[10.x-dev, v10.1.0].
- Conclusion: don't install lcobucci/jwt 3.3.3
- laravel/passport 10.x-dev requires lcobucci/jwt ^3.4|^4.0 -> satisfiable by lcobucci/jwt[3.4.0, 3.4.1, 3.4.2, 3.4.3, 3.4.x-dev, 4.0.0, 4.0.0-alpha1, 4.0.0-alpha2, 4.0.0-alpha3, 4.0.0-beta1, 4.0.1, 4.0.x-dev, 4.1.0, 4.1.x-dev, 4.2.x-dev].
- Can only install one of: lcobucci/jwt[3.4.0, 3.3.3].
- Can only install one of: lcobucci/jwt[3.4.1, 3.3.3].
- Can only install one of: lcobucci/jwt[3.4.2, 3.3.3].
- Can only install one of: lcobucci/jwt[3.4.3, 3.3.3].
- Can only install one of: lcobucci/jwt[3.4.x-dev, 3.3.3].
- Can only install one of: lcobucci/jwt[4.0.0, 3.3.3].
- Can only install one of: lcobucci/jwt[4.0.0-alpha1, 3.3.3].
- Can only install one of: lcobucci/jwt[4.0.0-alpha2, 3.3.3].
- Can only install one of: lcobucci/jwt[4.0.0-alpha3, 3.3.3].
- Can only install one of: lcobucci/jwt[4.0.0-beta1, 3.3.3].
- Can only install one of: lcobucci/jwt[4.0.1, 3.3.3].
- Can only install one of: lcobucci/jwt[4.0.x-dev, 3.3.3].
- Installation request for lcobucci/jwt (locked at 3.3.3) -> satisfiable by lcobucci/jwt[3.3.3].
To enable extensions, verify that they are enabled in your .ini files:
- C:\xampp\php\php.ini
You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
Installation failed, reverting ./composer.json to its original content.
I saw some solution in SO saying adding some version to the laravel/passport like so : composer require laravel/passport:7.5.1, but I'm not confident if this works with laravel 8
I had the same problem while deploying a Laravel app into EC2 AMI2 as OS. I was I just installed ext-sodium using:
sudo yum install php-sodium
Just Delete the composer.lock file and run composer install command
again. Don't forget to thanks me :)
Most of Cases, Issue generate by composer lock file so delete it before setup the project
you can uncomment the "sodium" extension in the php.ini file
Related
I was having trouble using Sharp (npm i sharp) in two different computers, a Mac and a Linux.
I was getting the following error:
Error:
Something went wrong installing the "sharp" module
Cannot find module '../build/Release/sharp-darwin-x64.node'
Possible solutions:
- Install with verbose logging and look for errors: "npm install --ignore-scripts=false --foreground-scripts --verbose sharp"
- Install for the current darwin-x64 runtime: "npm install --platform=darwin --arch=x64 sharp"
- Consult the installation documentation: https://sharp.pixelplumbing.com/install
at Object.<anonymous>
The cross platform topic in the official documentation (https://sharp.pixelplumbing.com/install#cross-platform) didn't help. Tried to follow what they suggested, but kept getting the same error.
What did I do to solve it?
The Sharp package was originally installed in the Linux computer.
So, to add support to MacOS:
In the MacOS computer, ran npm remove sharp
In the MacOS computer, ran npm i sharp
That left me with 10 changed files: 5 of them removing Linux support, 5 of them adding MacOS support. I then discarded the removal of the 5 Linux files, and kept the addition of the 5 MacOS files, as the following image:
This way, I ended with support in the two platforms.
Hope this helps someone who needs it.
This question may looks dumb, but like two weeks ago, I had no problems with installing it.
Now it looks like that:
ng add #ngx-formly/schematics --ui-theme=material
I tried install it after/before material and cdk modules, but the result is the same.
I also tried to install all separate formly modules( on the base of projects that I created previously) and I get this error:
The package that you are trying to add does not support schematics. You can try using a different version of the package or contact the package author to add ng-add support.
I also tried to delete node modules and yarn.lock and init it again, but still it doesn't works.
And also when I create form it just doesn't show.
I also tried to install it with yarn add ...
or -ui-theme=bootstrap, but the result is the same.
Also tried to ng serve, before installing it(read it somewhere on stack), but it also doesn't work.
I have heard that there are some problems with node v.15.6.0, but I'm not sure if it's that.
Here's also my versions:
and yarn version is 1.22.5
Update:
I tried to upgrade all the packages with yarn upgrade --latest, then install formly again.
And after:
ng add #ngx-formly/schematics --ui-theme=material
I get that:
An unhandled exception occurred: Cannot find module '#schematics/angular/utility/config'
Require stack:
- /home/wiktor/angular-material-template/node_modules/#ngx-formly/schematics/utils/ast.js
- /home/wiktor/angular-material-template/node_modules/#ngx-formly/schematics/src/ng-add/index.js
- /home/wiktor/angular-material-template/node_modules/#angular-devkit/schematics/tools/export-ref.js
- /home/wiktor/angular-material-template/node_modules/#angular-devkit/schematics/tools/index.js
- /home/wiktor/angular-material-template/node_modules/#angular/cli/utilities/json-schema.js
- /home/wiktor/angular-material-template/node_modules/#angular/cli/models/command-runner.js
- /home/wiktor/angular-material-template/node_modules/#angular/cli/lib/cli/index.js
- /usr/lib/node_modules/#angular/cli/lib/init.js
- /usr/lib/node_modules/#angular/cli/bin/ng
See "/tmp/ng-rRKl9j/angular-errors.log" for further details.
Ok, I found the solution. I had to downgrade angular schematics to previous version( for safety I downgrade two versions):
npm uninstall #schematics/angular
npm install #schematics/angular#9.1.0
So formly schematics is not compatible with angular 11 schematics.
In ASP.NET Zero 5.x, npm run create-bundles fails.
I am building a licensed project on the ASP.NET Zero's ASP.NET Core MVC + jQuery base solution, based on ASP.NET Boilerplate framework. This is not a new/mint project, but an existing project that has been built and ran successfully in the past.
I have followed the Getting started guide to ensure that I install the following:
nodejs (v10.15.3) + npm (v6.4.1)
gulp - ensured I installed it globally (cli version 2.0.1 local version 3.9.1)
yarn (v1.13.0)
bundler & minifier Visual Studio extension (latest)
I then ran yarn (twice - the first time around I received an error message), as per the guide.
Trying to run npm run create-bundles gives me the following error message:
It seems that none of my minified JavaScript files are generate
What can I do for npm run create-bundles to run successfully?
nodejs (v10.15.3) ...
gulp ... 3.9.1
It is an issue with gulp.js 3.9.1 on Node.js 10.14.2+. 1
These are your options, in order of recommendation:
Upgrade gulp: npm install gulp#^4 1 — for ASP.NET Zero, upgrade to ASP.NET Zero 6.3.1+.
Install a specific version of natives: npm install natives#1.1.6 2
Downgrade to Node.js 10.14.1 3
References
https://github.com/nodejs/node/issues/24985#issuecomment-447241752
https://github.com/gulpjs/gulp/issues/2246#issuecomment-435646661
https://github.com/nodejs/node/issues/24985#issuecomment-449124867
Just Update gulp version into 3.9.1 and this version support Node.js lastest version.
npm install gulp#3.9.1
On windows 64 bit platform, upgrade from Node6.x to Node8.x gave the following
Error: Missing binding C:\bisbor1\src\main\webapp\node_modules\node-sass\vendor\win32-x64-57\binding.node
Node Sass could not find a binding for your current environment: Windows 64-bit with Node.js 8.x
It also asks to build the node-saas library for which it is mandatory to install Python. For a front end developer, it seems a bit bizarre to install Python to run a simple "Hello Angular" app. And funnily, i don't even need node-saas. Its not a direct dependency for my application.
After breaking my head over installing Python to reinstalling "node_modules" several times (never mind the "download" of the internet that 'npm install' demands), I finally found peace with the following solution.
"Downloaded the appropriate platform specific binding file (note the version of binding in the error thrown) from the git repository
https://github.com/sass/node-sass/releases
And updated the node-sass binding in my npm cache which is located at C:\Users\bisbor1\AppData\Roaming\npm\node_modules\ng-packagr\node_modules\node-sass\vendor\win32-x64-57"
The Primary step is to ensure that you are having Python 2.7 installed, because node-gyp only supports python2, as of writing the post.
To do so:
check whether Python Version is 2.7 or lower using python --version
downgrade using sudo apt-get install python
then rebuild node-sass using npm rebuild-node-sass
If everything else is correct, then a npm start would launch your App.
Running command node -v gives the following value: v0.10.33. I know that Node.js currently is at version 0.12. Nevertheless, when running a choco update nodejs, the prompt says "Nothing to update". The same occurs with npm after a "choco update npm".
I have installed Node.js from the install package on their website nodejs.org.
A time after that I have also installed Chocolatey and have come to use the tool every now and then for package installations.
Is it possible to have Chocolatey recognize the existing Node.js installation and pick a choco update from there?
I would like to also be able to pick up the npm update from Chocolatey the same way as well.
I do not have the latest Chocolatey.
> choco list --local-only nodejs
Opción desconocida: '--local-only'
nodejs.commandline 0.12.2
npm 1.4.9.20150213
EthanBrown.DevTools.Web 0.3.1
ghost 0.5.5.1
io.js 1.7.1
livestreamer-twitch-gui 0.7.1
nodejs 0.12.2
nodejs.install 0.12.2
node-webkit-0.9.2 0.9.2
node-webkit 0.6.2
Brackets.Theseus 0.2.8
Yeoman 1.1.2
After upgrading Chocolatey to v0.9.9.4
> choco list --local-only
Chocolatey v0.9.9.4 [nl] 0 packages installed.
I updated Node.js using npm.
> node -v
v0.12.2
However, after reinstalling Node.js at version 0.10.33,
> choco install nodejs -version 0.10.33
I cannot use npm:
Cannot find file at 'npm.cmd' (C:\ProgramData\chocolatey\lib\npm\tools\npm.cmd). This usually indicates a missing or moved file.
I'll leave it for now until I troubleshoot.
Another option, assuming that you already have Node.js installed via the MSI would be to run:
choco install nodejs -version 0.12.2 -y -n
The -n parameter, as documented here:
https://github.com/chocolatey/choco/wiki/CommandsInstall#options-and-switches
Skips the PowerShell script associated with the Chocolatey package. This essentially adds the package version into the Chocolatey repository, but it doesn't run the associated installation script.
This is what I "think" you are after.
NOTE: Not all packages have chocolateyinstall.ps1 files, and instead rely on the default installation behaviour of Chocolatey, i.e. creating shims for contained EXE files, etc. The skippowershell flag will not, to the best of my knowledge, stop this from happening.
Chocolatey cannot currently detect and incorporate already installed applications into its own library. Now, if you installed the Node.js MSI manually and then used Chocolatey to install the same or newer version, things might just work. The MSI system, while arcane, is pretty robust and most newer MSIs will subsume older ones.
Can you run the Chocolatey command to show us exactly which Node.js you have installed?
PS> choco list --local-only nodejs
Chocolatey v0.9.9.2
nodejs 0.10.33
nodejs.install 0.10.33
2 packages installed.
I have the same version installed. I just ran an update. I snipped the logs, but you can see that it updates.
PS> choco upgrade nodejs
Chocolatey v0.9.9.2
nodejs.install v0.12.2
nodejs v0.12.2
Chocolatey upgraded 2/2 package(s). 0 package(s) failed.
And Node.js is up-to-date.
PS> node -v
v0.12.2
And the application in the Programs and Features applet of the Control Panel is also updated. So, the Node.js MSI does the right thing here.
I think we need to see some more literal command output from your system to be sure you have all the right versions installed.