![我是否升级了软件包,为什么显示的版本不匹配?](https://linux22.com/image/170709/%E6%88%91%E6%98%AF%E5%90%A6%E5%8D%87%E7%BA%A7%E4%BA%86%E8%BD%AF%E4%BB%B6%E5%8C%85%EF%BC%8C%E4%B8%BA%E4%BB%80%E4%B9%88%E6%98%BE%E7%A4%BA%E7%9A%84%E7%89%88%E6%9C%AC%E4%B8%8D%E5%8C%B9%E9%85%8D%EF%BC%9F.png)
起初
$ xpra --version
xpra v3.0.7-r25627
然后我升级了xpra
$ sudo apt install xpra
[sudo] password for t:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
xpra
1 upgraded, 0 newly installed, 0 to remove and 54 not upgraded.
2 not fully installed or removed.
Need to get 314 kB of archives.
After this operation, 1,024 B of additional disk space will be used.
Get:1 https://xpra.org bionic/main amd64 xpra amd64 3.0.8-r25889-1 [314 kB]
Fetched 314 kB in 1s (267 kB/s)
(Reading database ... 485411 files and directories currently installed.)
Preparing to unpack .../xpra_3.0.8-r25889-1_amd64.deb ...
Unpacking xpra (3.0.8-r25889-1) over (3.0.7-r25627-1) ...
Setting up xpra (3.0.8-r25889-1) ...
但是之后
$ xpra --version
xpra v3.0.7-r25627
和
$ dpkg -l | grep -i xpra
ii python2-xpra 3.0.7-r25627-1 amd64 tool to detach/reattach running X programs
ii python3-xpra 3.0.7-r25627-1 amd64 tool to detach/reattach running X programs
ii xpra 3.0.8-r25889-1 amd64 tool to detach/reattach running X programs
ii xpra-html5 3.0.7-r25627-1 amd64 html5 xpra client
和
$ sudo apt install xpra
[sudo] password for t:
Reading package lists... Done
Building dependency tree
Reading state information... Done
xpra is already the newest version (3.0.8-r25889-1).
为什么显示xpra版本不匹配?
是由于 xpra 包还是 apt 或 dpkg 造成的?
谢谢。
答案1
您已经升级了软件包,但尚未升级软件包,这决定了您真正使用的 Xpra 版本。
正如伊普尔所说,上游 Xpra 包将其内容分为xpra
包含启动器脚本(和配置等)的小包和包含实现的 Python 包。
要升级 Xpra,您需要升级所有与 Xpra 相关的软件包:
sudo apt install xpra xpra-html5 python3-xpra
套餐xpra
可以声明对其他 Xpra 软件包的严格版本依赖,这将导致它们全部使用sudo apt install xpra
;进行升级。但事实并非如此,这就是为什么用户需要确保它们全部保持同步。 (我想上游打包商假设用户一直升级他们的所有软件包。)
您可以删除 Python 2 包,不再需要它:
sudo apt purge python2-xpra