Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Corner case when picking the latest dependency available #44

Open
mamash opened this issue Mar 23, 2015 · 0 comments
Open

Corner case when picking the latest dependency available #44

mamash opened this issue Mar 23, 2015 · 0 comments
Assignees

Comments

@mamash
Copy link

mamash commented Mar 23, 2015

This is with pkgin 0.8.0. Consider the following situation:

# pkgin av | grep ^jasper
jasper-1.900.1nb10;Software-based reference implementation of the JPEG-2000 codec
jasper-1.900.1nb8;Software-based reference implementation of the JPEG-2000 codec

Directly calling pkgin in jasper picks the nb10 version properly. However, installing a package that depends on jasper seems to prefer nb8:

# pkgin in gdal-lib
calculating dependencies... done.

nothing to upgrade.
2 packages to be installed (744K to download, 42M to install):

jasper-1.900.1nb8 gdal-lib-1.11.1

proceed ? [Y/n] n

Sounds like numerical sorting is not applied for the various parts of the version string when picking the right dep. Same case might be here, but I don't have anything that would depend on nodejs, so can't confirm:

# pkgin av | grep ^nodejs
nodejs-0.10.35;V8 JavaScript for clients and servers
nodejs-0.10.36;V8 JavaScript for clients and servers
nodejs-0.12.0;V8 JavaScript for clients and servers
nodejs-0.8.28;V8 JavaScript for clients and servers

Sounds like plain alpha sorting is being used for display and (possibly) dependency lookup, which doesn't work for the 9->10 version updates.

@jperkin jperkin self-assigned this Aug 1, 2023
netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this issue Aug 16, 2023
## Version 23.8.0 (2023-08-16)

This is the biggest overhaul of pkgin yet!  As well as fixing many bugs, pkgin
23.8.0 runs "pkgin -n upgrade" over 2,000x faster on a test system with 12,663
packages installed compared to 22.10.0 (1.4 seconds vs over 54 minutes).

 * Large overhaul of dependency resolution code, fixing many upgrade issues,
   providing significant performance improvements, and improving code and
   logic readability.

 * Add support for SUPERSEDES.

 * Fix install and removal ordering.

 * Improve and fix handling of "keep" packages, using "pkg_add -A" to
   correctly install automatic packages rather than applying keep or unkeep
   flags afterwards.

 * Output improvements, sorting packages alphabetically and providing a
   simple progress counter.  Fix unwanted output that could end up mixed
   with package paths in "pkgin export".

 * Correct handling of +REQUIRED_BY for reverse dependencies, fixing
   DEPENDS that use alternate matches.

 * Many internal code improvements, memory leaks plugged, and compiler
   warnings eradicated.

Fixes at least the following issues:

 * NetBSDfr/pkgin#10
 * NetBSDfr/pkgin#44
 * NetBSDfr/pkgin#79
 * NetBSDfr/pkgin#95
 * NetBSDfr/pkgin#97
 * NetBSDfr/pkgin#110
 * NetBSDfr/pkgin#113
 * NetBSDfr/pkgin#128
 * NetBSD PR#51465
 * NetBSD PR#56683
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants