Buildbots no longer upload any binary packages (cleanup failure)

Ryan Schmidt ryandesign at macports.org
Fri Mar 20 16:07:40 PDT 2015


On Mar 20, 2015, at 4:21 PM, Blair Zajac wrote:
> 
> On Mar 18, 2015, at 6:43 PM, Ryan Schmidt wrote:
> 
>> I'll write a more detailed explanation shortly.
> 
> Do you know what happened here?

The protobuf3-cpp port was created in r134007 with the unusual version value "0.0.0.1 # remove this version leaving the above one". Clearly "# remove this version leaving the above one" was intended to be a comment, but in Tcl, a "#" only begins a comment if it occurs where a command is expected. I doubt previous MacPorts base programmers expected the version of a port to contain spaces, nor tested such a situation, and it appears that several parts of MacPorts don't handle it well. For example, installing the port fails:

$ sudo port install protobuf3-cpp
--->  Computing dependencies for protobuf3-cpp
--->  Fetching distfiles for protobuf3-cpp
--->  Verifying checksums for protobuf3-cpp
--->  Extracting protobuf3-cpp
--->  Configuring protobuf3-cpp
--->  Building protobuf3-cpp
--->  Staging protobuf3-cpp into destroot
--->  Installing protobuf3-cpp @0.0.0.1 # remove this version leaving the above one_0+universal
Error: Failed to activate protobuf3-cpp: Image error: Can't find image file /opt/local/var/macports/software/protobuf3-cpp/protobuf3-cpp-0.0.0.1 # remove this version leaving the above one_0+universal.darwin_14.i386-x86_64.tbz2
Error: See /opt/local/var/macports/logs/_Users_rschmidt_macports_dports_devel_protobuf3-cpp/protobuf3-cpp/main.log for details.
Error: Follow http://guide.macports.org/#project.tickets to report a bug.
Error: Processing of port protobuf3-cpp failed
elapsed: 00:02:12
$ ls -l /opt/local/var/macports/software/protobuf3-cpp
total 52416
-rw-r--r--  1 root  wheel  26836509 Mar 20 18:00 protobuf3-cpp-0.0.0.1
$ port installed protobuf3-cpp
The following ports are currently installed:
  protobuf3-cpp @0.0.0.1 # remove this version leaving the above one_0+universal
$ 

The part that creates the archive filename doesn't seem to quote it, since the filename should have been "protobuf3-cpp-0.0.0.1 # remove this version leaving the above one_0+universal.darwin_14.i386-x86_64.tbz2" but was actually "protobuf3-cpp-0.0.0.1". The part that uninstalls the archive seems to be different, since the file does not get removed on uninstall. We should probably quote the name when creating the file.

And the buildbot script that uninstalls installed ports after every build seems not to have anticipated spaces in the version either. It probably just runs "sudo port uninstall" for each line of "port installed", i.e.:

$ sudo port uninstall protobuf3-cpp @0.0.0.1 # remove this version leaving the above one_0+universal
Error: port uninstall failed: Registry error: protobuf3-cpp @0.0.0.1 not registered as installed

We should probably change the script to quote the version, since that would work:

$ sudo port uninstall protobuf3-cpp @'0.0.0.1 # remove this version leaving the above one_0+universal'
--->  Uninstalling protobuf3-cpp @0.0.0.1 # remove this version leaving the above one_0+universal
$ 




More information about the macports-dev mailing list