[117414] trunk/base/src/cregistry/sql.c

Jeremy Huddleston Sequoia jeremyhu at apple.com
Wed Feb 26 09:14:10 PST 2014


On Feb 26, 2014, at 00:36, Joshua Root <jmr at macports.org> wrote:

> On 2014-2-26 19:25 , Clemens Lang wrote:
>> Hi,
>> 
>>>> What's the output of
>>>> sqlite3 /opt/local/var/macports/registry/registry.db 'SELECT value FROM
>>>> metadata WHERE key = "version";'
>>>> on your system?
>>> 
>>> 1.200
>> 
>> I don't understand that. The error shows that it's running the queries that are supposed to bring the database version to 1.100, but it already is 1.200.
>> The comparisons involved are
>> vercmp 1.200 1.100 (which must be < 0 for the update to be run) and
>> vercmp 1.200 1.200 (which must be < 0 for the update to 1.200 to be run)
> 
> Yeah, that's really confusing if that was run on the right db. But I did
> just confirm that a fresh install of 2.2.1 will have a registry version
> of 1.1 not 1.100, and that would cause jeremyhu's error.
> 
> So the comparison is now back the way it was...

Right, I'm sorry about that.  I gathered that info quickly from my phone.  It turns out that I did that check on the one system that I have that wasn't experiencing the issue.  So for completeness, here's the correct state:

(09:07:49 Wed Feb 26 2014 jeremy at nanake x86_64)
~/src/macports/base $ svn info
Path: .
Working Copy Root Path: /Volumes/Home/jeremy/src/macports/trunk
URL: https://svn.macports.org/repository/macports/trunk/base
Relative URL: ^/trunk/base
Repository Root: https://svn.macports.org/repository/macports
Repository UUID: d073be05-634f-4543-b044-5fe20cf6d1d6
Revision: 117418
Node Kind: directory
Schedule: normal
Last Changed Author: jmr at macports.org
Last Changed Rev: 117414
Last Changed Date: 2014-02-25 12:31:16 -0800 (Tue, 25 Feb 2014)


(09:07:49 Wed Feb 26 2014 jeremy at nanake x86_64)
~/src/macports/base $ sqlite3 /opt/local/var/macports/registry/registry.db 'SELECT value FROM
> metadata WHERE key = "version";'
1.1

(09:07:54 Wed Feb 26 2014 jeremy at nanake x86_64)
~/src/macports/base $ sudo port -v -s upgrade
sqlite error: duplicate column name: binary (1) while executing query: ALTER TABLE registry.files ADD COLUMN binary BOOL
    while executing
"registry::open $db_path"
    (procedure "mportinit" line 624)
    invoked from within
"mportinit ui_options global_options global_variations"
Error: /opt/local/bin/port: Failed to initialize MacPorts, sqlite error: duplicate column name: binary (1) while executing query: ALTER TABLE registry.files ADD COLUMN binary BOOL

----

I then updated to r117444 and things look good now:

~/src/macports/base $ sqlite3 /opt/local/var/macports/registry/registry.db 'SELECT value FROM
metadata WHERE key = "version";'
1.200

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4109 bytes
Desc: not available
URL: <https://lists.macosforge.org/pipermail/macports-dev/attachments/20140226/5f010190/attachment-0001.p7s>


More information about the macports-dev mailing list