unisonweb / unison

A friendly programming language from the future
https://unison-lang.org
Other
5.69k stars 265 forks source link

SQLITE crash #3288

Open ChrisPenner opened 1 year ago

ChrisPenner commented 1 year ago

UCM from hash 72a903d046715a4e951fa95cf16e73f18774131a (current trunk at time of writing)

Managed to get a SQLITE crash :'(

I haven't yet had time to try to reproduce, likely caused by either the squash or the undo

.share.file.latest> copy.namespace .cloudstuff.lib.base lib.base

  Done.

.share.file.latest> ls

  1. README (Doc)
  2. bytes/ (6 definitions)
  3. lib/   (3760 definitions)
  4. text/  (6 definitions)

.share.file.latest> cd ..
.share.file> cd main
.share.file.main> undo

.share.file.main> squash .cloudstuff.lib.base lib.base
  Here's what's changed in lib.base after the merge:

  Added definitions:

    1.    structural ability abilities.Abort (+2 metadata)
    2.    unique type Pretty.Annotated w txt
    3.    builtin type Any
    4.    unique type math.ArithmeticException (+2 metadata)
    5.    structural type data.Array a (+2 metadata)
    6.    structural type mutable.Array g a (+2 metadata)
    7.    unique type ArrayFailure
    8.    structural ability abilities.Ask a (+2 metadata)
    9.    unique type metadata.Author
    10.   structural type data.Bag a (+3 metadata)
    11.   builtin type Boolean
    12.   unique type io.BufferMode
    13.   structural type data.ByteArray (+2 metadata)
    14.   structural type mutable.ByteArray g (+2 metadata)
    15.   builtin type Bytes
    16.   builtin type Char
    17.   builtin type io.Tls.Cipher
    18.   builtin type io.Tls.ClientConfig
    19.   builtin type reflection.Code
    20.   unique type system.ANSI.Color
    21.   unique type system.ConsoleText
    22.   unique type metadata.CopyrightHolder
    23.   unique type Doc.Deprecated
    24.   ┌ unique type metadata.License.Deprecated (+1 metadata)
    25.   └ unique type metadata.License (+1 metadata)
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 14932
    }
aryairani commented 7 months ago

@ChrisPenner Should we close this?