Is there a way to see when a composer package has an available update that is higher than its composer.json requirement allows?
My composer.son file has require statements like this:
"require" : {
"components/bootstrap" : "~3.3.4",
"components/jquery" : "~1.11.2",
"erusev/parsedown" : "~1.5.2",
...
},
Imagine parsedown has just had a big jump in functionality, and moved to version 2.0.0. When I run a composer update, as expected, my app will not be updated to version 2.0.0 (if one existed). Is there a way I can see that 2.0.0 is available with a composer command?
I am worried I might miss some updates, because I have locked down my required versions so much, and hope there is some command or way to see all of the available updates for my composer packages.
Is there a way to see when a composer package has an available update that is higher than its composer.json requirement allows?
Yes, there is a way. It's basically the comparison of the defined version constraint in your composer.json with the version numbers of composer show for the specific package.
composer show --self
This shows you the output of composer.json of your project.
You get the defined version constraints.
Alternatively, just open composer.json.
composer show --installed
This shows you the resolved and installed versions.
composer show package/package
This shows you all available version numbers.
Sidenote: composer show erusev/parsedown says there is no v2.0.0 release, yet.
There isn't a table display for this, yet, but it's a nice feature request, because it eases project maintenance. But assembling the infos automatically is quite resource intensive, especially when there are a lot of packages.
+----------------------------------------------------------------------------------+
| package | defined constraint | current version | available versions |
------------------------------------------------------------------------------------
| erusev/parsedown | ~1.0 | 1.5.2 | dev-master, v1.5.2, ...|
+----------------------------------------------------------------------------------+
First I'd recommend relaxing your version requirements to only have tilde-two-numbers instead of three, and see how it goes. It will allow you to not only get patch updates, but also compatible feature updates.
Composer currently has no way to signal to you the presence of incompatible versions beyond the original package being flagged "abandoned". You have to monitor the release announcement of the packages you use manually, or you could try and see what happens if you add the next major version to the requirement: "erusev/parsedown" : "~1.5.2|~2.0"
This however looks strange if you haven't even tried to update to the latest 1.x version using "erusev/parsedown" :"^1.5.2". Note that the caret is a shortcut for ~1.5,>=1.5.2 for major versions >= 1 (major versions 0.x are handled more strictly).
Related
I am trying to run AppEngine Standard Environment inside PyCharm.
The problem is when I include Google App Engine SDK as part of External Libraries, but it contains multiple version of old libraries that somehow has higher priority than the library I have in my env folder.
Specifically, it is loading jinja2-2.6 which doesn't work for Python 3, even though I have jinja2-2.11.3 in my env/lib.
Pycharm does have a bit of issues with its library system as many users have reported before. To Adjust the version of your libraries in PyCharm you must access the interpreter options relating your python interpreter for your current project, you can access this option by searching in the menu Settings/Preferences or by pressing Ctrl+Alt+S
In this dialog you can view the packages available and their current running versions. You can update the version by clicking on the ▲ symbol next to the version. if you have trouble upgrading to a specific version you may need then you can alway remove a package by clicking on the "-" on the right hand side after clicking on the package you wish to remove. After removing the package you can add a new one by clicking on the "+" button right on top of the "-" button. Here you can search for the package you need and before installing a package, you can check the specific version checkbox to search for the version you require in the dropdown menu next to it.
This link contains images for what i'm explaining here.
Remember that these packages are taken directly from the pip so if you have errors using the interface you can always try to manually edit the packages (also described in the link).
To upgrade a specific package using pip for python3 you can use the following command:
pip3 install --upgrade PackageName
I started using Conan to handle my C++ code base and I do not understand if it offers a way to automatically increment a package version after uploading a release.
I am talking about something like npm postpublish hook script that I use to execute npm version patch: so I am always sure that after a release, I am working on a new version.
I there any command that updates version field inside my conanfile.py? Is it automatically callable after a deploy?
No, there is no auto-incrementing feature for conan. The main reason is that it is not clear that a conan upload necessarily means bumping the version. For example, you might run a conan create to create a x86 binary, then upload it. After that, you create a package binary, exactly with the same recipe and version, for 64bits, x86_64, and upload it.
You don't want to bump to a different version. So bumping the version is done explicitly in the recipe version field. It can also be skipped in the recipe, and just defined in the command line: conan create . pkg/version#user/channel, but it is up to the user to define the version.
A different feature would be the package "revisions". Those will assign a new, transparent revision for each recipe change or binary rebuild. It is an ongoing work, so it might take some time until it is there.
Recently I've been running into an issue and I'm not sure how to best resolve it. We have a very modular architecture on the front end. We write individual angular components, put them in different repo's, and then include them in other apps as they are required, built with webpack & included via NPM.
Recently I've run into issues where multiple versions of a module end up in the compiled /dist folder coming from different places such as:
Directly included in the App I'm working on
2x Indirectly included through a module that I included (see chart for details).
The reason different versions could be used is that at the time CodeA is written ModuleA may be at version 1, then at a later date CodeB is written which also uses ModuleA which is now at version 2.
Then CodeA and CodeB are included in CodeC and now you have a module name collision on ModuleA.
With this setup, I believe if the multiple modules by the same name are loaded, the last one to get loaded is going to be the code behind that module name. Meaning it will be the one to be used by all modules. So there's no guarantee that the most up-to-date version is will be used. This usually results in getting an error that a method on ModuleA by name XXX does not exist.
To make sure I'm running the latest version of the module I have to go in and manually update (npm install) and build with webpack (npm run build) each library and then push them all to Github. Then I have to npm install in my root app. This isn't always an easy thing to do as the individual libraries' code may need updated to use the latest version of the module in question.
I'm looking for a solution to this issue. I'm guessing a structural/organizational change that will help us to not get into this predicament. If you have any solutions/advice/articles I need to check out please share. Thanks!
I want to start a project with Symfony3 and SonataAdmin
I was trying a lot of versions of symfony and sonataAdminBundle
But I always get errors when updating composer
What's the correct composer.json to start my project
thanks
According to packagist the current v3.3.1 of SonataAdminBundle should be compatible with Symfony ^3.0.
You can just run composer require sonata-project/admin-bundle and it will automatically look for the newest compatible version. If that fails you could try allowing development-versions as well.
composer require sonata-project/admin-bundle:dev-master
That should be your last resort though as it pulls in an unstable dependency. Feel free to add composer's error to your question and maybe I or someone else can give a more precise answer.
Just learning atk4. (4.2.4, I believe. Installed through curl -sS http://agiletoolkit.org/install | sh)
How do I modify and load shared.html in atk4? I can only edit atk4/templates/shared/shared.html?
I tried copying shared.html to the following locations and edit them:
/templates/default/shared.html
/templates/default/shared/shared.html
/templates/shared/shared.html
and none seems to be loaded at all.
It should work at least from /templates/shared/shared.html.
Please try to use latest ATK4 version from master branch from GitHub https://github.com/atk4/atk4. Current fully working version is 4.2.5.
If you start to learn ATK4 or start completely new project based on ATK4 framework, then you better look into 4.3 branch in GitHub and learn and use it. There are quite a lot of things changed in 4.3 (not yet released) version so you better use them now and you'll not need to "convert" your project from 4.2.x to 4.3 later on when 4.3 will be officially released.