[MacPorts] #31056: Locking somewhat broken in MacPorts 2
MacPorts
noreply at macports.org
Wed Aug 31 18:57:02 PDT 2011
#31056: Locking somewhat broken in MacPorts 2
-------------------------------------+--------------------------------------
Reporter: ryandesign@… | Owner: macports-tickets@…
Type: defect | Status: new
Priority: Normal | Milestone:
Component: base | Version: 2.0.1
Keywords: | Port:
-------------------------------------+--------------------------------------
There is something broken about locking ever since MacPorts 2.0.0.
Example 1: I tell MacPorts to uninstall a port, while some other port is
installing; it tells me it's locked, but then silently doesn't complete
the operation when the lock disappears. Retrying while MacPorts is not
busy with other tasks works fine.
{{{
fossil $ sudo port uninstall
Waiting for lock on /opt/local/var/macports/registry/.registry.lock
fossil $ port installed fossil
The following ports are currently installed:
fossil @20110523151112_1+universal (active)
fossil $ sudo port uninstall
Password:
---> Deactivating fossil @20110523151112_1+universal
---> Uninstalling fossil @20110523151112_1+universal
fossil $
}}}
Example 2: I tell MacPorts to upgrade a port, while some other port is
busy; after the lock disappears, it tells me the port I asked to upgrade
is not installed, but of course it is installed, and retrying the upgrade
works fine.
{{{
$ sudo port -ud upgrade py26-docutils
Waiting for lock on /opt/local/var/macports/registry/.registry.lock
Error: py26-docutils is not installed
To report a bug, see <http://guide.macports.org/#project.tickets>
$ sudo port -ud upgrade py26-docutils
Password:
DEBUG: epoch: in tree: 0 installed: 0
DEBUG: py26-docutils 0.8.1_0 exists in the ports tree
DEBUG: py26-docutils 0.8_0 is the latest installed
DEBUG: py26-docutils 0.8_0 is active
[snip successful upgrade]
$
}}}
It does not seem to matter what ports are involved, or what MacPorts
commands are being run; if an operation is being delayed via the lockfile,
then it doesn't always run properly once the lock is removed.
The issue is intermittent so I think it's a race condition.
--
Ticket URL: <https://trac.macports.org/ticket/31056>
MacPorts <http://www.macports.org/>
Ports system for Mac OS
More information about the macports-tickets
mailing list