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

Migrating from old codebase versions is broken #3369

Open
ChrisPenner opened this issue Aug 29, 2022 · 5 comments
Open

Migrating from old codebase versions is broken #3369

ChrisPenner opened this issue Aug 29, 2022 · 5 comments
Labels

Comments

@ChrisPenner
Copy link
Contributor

ChrisPenner commented Aug 29, 2022

I got a sqlite error when attempting this migration:

.blarg> pull-request.load git(https://github.com/unisonweb/base:v3):.trunk git(https://github.com/tarik-ozkanli/allmyunisoncode)
🔨 Migrating codebase to version 2...
Starting codebase migration. This may take a while, it's a good time to make some tea ☕️
Updating Namespace Root...
 🏗  55717 / ~55717 entities migrated. 🚧
Finished migrating, initiating cleanup.
Updating Namespace Root...
Rewriting old object IDs...
Garbage collecting orphaned objects...
Garbage collecting orphaned watches...
Updating Schema Version...
🔨 Migrating codebase to version 3...
🔨 Migrating codebase to version 4...
🏗  37305 / ~37305 entities migrated. 🚧
Finished.
🛠  Cleaning up unreachable branches and causals...
🔨 Migrating codebase to version 5...
🕵️  Checking codebase integrity...
Checking Namespace Integrity...
Checking Causal Integrity...
Cleaning up...
🏁 Migration complete 🏁
  Importing downloaded files into local codebase...
🔨 Migrating codebase to version 3...
🔨 Migrating codebase to version 4...
🏗  14933 / ~14933 entities migrated. 🚧
Finished.
🛠  Cleaning up unreachable branches and causals...
🔨 Migrating codebase to version 5...
🕵️  Checking codebase integrity...
Checking Namespace Integrity...
Checking Causal Integrity...
Cleaning up...
🏁 Migration complete 🏁
  Importing downloaded files into local codebase...

  I checked out git(https://github.com/unisonweb/base) to base.
  I checked out git(https://github.com/tarik-ozkanli/allmyunisoncode) to head.

  The merged result is in merged.
  The (squashed) merged result is in squashed.
  Use `diff.namespace base merged` or `diff.namespace base squashed` to see what's been updated.
  Use `todo merged.patch merged` to see what work is remaining for the merge.
  Use `push git(https://github.com/unisonweb/base) merged` or
  `push git(https://github.com/unisonweb/base) squashed` to push the changes.

Encountered exception:
SqliteQueryException
    { sql = "SELECT object.id
            FROM object
            JOIN hash ON object.primary_hash_id = hash.id
            WHERE hash.base32 = ? COLLATE NOCASE"
    , params = ""3e3rc9d77fh8mnjgtn5cvck814p5hc1u9vrkqq5bmkp7v61q2rg2hrloob5kai0hoh990pqt1p7k83vb3f1tcp24lim09f3fn1ttud0""
    , exception = ExpectedExactlyOneRowException
        { rows = "[]" }
    , callStack = []
    , connection = Connection
        { name = "main"
        , file = "/Users/cpenner/.unison/v2/unison.sqlite3"
        }
    , threadId = ThreadId 351
    }

I copied the codebase which fails to migrate here:

ChrisPenner/unison-codebase@3e8c408

@aryairani
Copy link
Contributor

@ChrisPenner should we close this? 🙈

@ChrisPenner
Copy link
Contributor Author

@aryairani I don't think it's fixed is it?

We can close it if we delete these migrations I suppose; #5093

@aryairani
Copy link
Contributor

@ChrisPenner Right, okay. I meant because git support was out, I wasn't sure if we could reproduce it.

@ChrisPenner
Copy link
Contributor Author

I think we could still curl the old codebase down from git if we wanted to reproduce, I think git is just where the borked codebase is, I don't think the git part is part of the error itself.

@aryairani
Copy link
Contributor

aryairani commented Jun 18, 2024

Okay cool. thanks.

@aryairani aryairani added the misc label Sep 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants