terminusdb / terminusdb

TerminusDB is a distributed database with a collaboration model
https://terminusdb.com
Apache License 2.0
2.73k stars 103 forks source link

Failed to pull from recently shared database. #203

Closed GavinMendelGleason closed 3 years ago

GavinMendelGleason commented 3 years ago

Describe the bug Can't pull for newly created database shared to hub.

To Reproduce Create a database. Share to hub. Create a commit (for instance by changing schema). Pull from remote.

Expected behavior No error

Screenshots

Failed to pull updates from origin main to local main (0.899 seconds)
Error: divergent_history("mqw31zl9b55u6qfi2s6ooi6espji9nr",["czy9sc1vnsr1s9bcs4tubkohisns3em"],[]) [36] throw(error(divergent_history("mqw31zl9b55u6qfi2s6ooi6espji9nr",...,[]),_13892)) [35] '<meta-call>'(db_fast_forward:(...,...)) <foreign> [34] database:with_transaction_(query_context{all_witnesses:false,authorization:'terminusdb:///system/data/admin',bindings:[],default_collection:repository_descriptor{database_descriptor: ...,repository_name:"local"},files:[],filter:type_filter{types: ...},prefixes:_14054{api:'http://terminusdb.com/schema/api#',doc:'terminusdb:///commits/data/',layer:'http://terminusdb.com/schema/layer#',owl:'http://www.w3.org/2002/07/owl#',rdf:'http://www.w3.org/1999/02/22-rdf-syntax-ns#',rdfs:'http://www.w3.org/2000/01/rdf-schema#',ref:'http://terminusdb.com/schema/ref#',repo:'http://terminusdb.com/schema/repository#',system:'http://terminusdb.com/schema/system#',terminus:'http://terminusdb.com/schema/system#',vio:'http://terminusdb.com/schema/vio#',woql:'http://terminusdb.com/schema/woql#',xdd:'http://terminusdb.com/schema/xdd#',xsd:'http://www.w3.org/2001/XMLSchema#'},selected:[],system:system_descriptor{},transaction_objects:[...],update_guard:true,write_graph:commit_graph{database_name:"some_kinda_database",name:"main",organization_name:"admin",repository_name:"local",type:instance}},db_fast_forward:(...,...),_13986) at /tmp/.mount_.org.cx6j7ga/usr/share/terminusdb/src/core/transaction/database.pl:213 [33] setup_call_catcher_cleanup(database:true,database:with_transaction_(...,...,_14220),_14198,database:(...,...)) at /tmp/.mount_.org.cx6j7ga/usr/lib/swi-prolog/boot/init.pl:614 [29] '<meta-call>'('<garbage_collected>') <foreign> [28] catch(db_pull:(...,...),error(divergent_history("mqw31zl9b55u6qfi2s6ooi6espji9nr",...,[]),context(_14330,_14332)),db_pull:(...,...)) at /tmp/.mount_.org.cx6j7ga/usr/lib/swi-prolog/boot/init.pl:532 [27] catch_with_backtrace(db_pull:(...,...),error(divergent_history("mqw31zl9b55u6qfi2s6ooi6espji9nr",...,[]),context(_14408,_14410)),db_pull:(...,...)) at /tmp/.mount_.org.cx6j7ga/usr/lib/swi-prolog/boot/init.pl:582 Note: some frames are missing due to last-call optimization. Re-run your program in debug mode (:- debug.) to get more detail.less
{
  "data": {
    "api:message": "Error: divergent_history(\"mqw31zl9b55u6qfi2s6ooi6espji9nr\",[\"czy9sc1vnsr1s9bcs4tubkohisns3em\"],[])\n  [36] throw(error(divergent_history(\"mqw31zl9b55u6qfi2s6ooi6espji9nr\",...,[]),_13892))\n  [35] '<meta-call>'(db_fast_forward:(...,...)) <foreign>\n  [34] database:with_transaction_(query_context{all_witnesses:false,authorization:'terminusdb:///system/data/admin',bindings:[],default_collection:repository_descriptor{database_descriptor: ...,repository_name:\"local\"},files:[],filter:type_filter{types: ...},prefixes:_14054{api:'http://terminusdb.com/schema/api#',doc:'terminusdb:///commits/data/',layer:'http://terminusdb.com/schema/layer#',owl:'http://www.w3.org/2002/07/owl#',rdf:'http://www.w3.org/1999/02/22-rdf-syntax-ns#',rdfs:'http://www.w3.org/2000/01/rdf-schema#',ref:'http://terminusdb.com/schema/ref#',repo:'http://terminusdb.com/schema/repository#',system:'http://terminusdb.com/schema/system#',terminus:'http://terminusdb.com/schema/system#',vio:'http://terminusdb.com/schema/vio#',woql:'http://terminusdb.com/schema/woql#',xdd:'http://terminusdb.com/schema/xdd#',xsd:'http://www.w3.org/2001/XMLSchema#'},selected:[],system:system_descriptor{},transaction_objects:[...],update_guard:true,write_graph:commit_graph{database_name:\"some_kinda_database\",name:\"main\",organization_name:\"admin\",repository_name:\"local\",type:instance}},db_fast_forward:(...,...),_13986) at /tmp/.mount_.org.cx6j7ga/usr/share/terminusdb/src/core/transaction/database.pl:213\n  [33] setup_call_catcher_cleanup(database:true,database:with_transaction_(...,...,_14220),_14198,database:(...,...)) at /tmp/.mount_.org.cx6j7ga/usr/lib/swi-prolog/boot/init.pl:614\n  [29] '<meta-call>'('<garbage_collected>') <foreign>\n  [28] catch(db_pull:(...,...),error(divergent_history(\"mqw31zl9b55u6qfi2s6ooi6espji9nr\",...,[]),context(_14330,_14332)),db_pull:(...,...)) at /tmp/.mount_.org.cx6j7ga/usr/lib/swi-prolog/boot/init.pl:532\n  [27] catch_with_backtrace(db_pull:(...,...),error(divergent_history(\"mqw31zl9b55u6qfi2s6ooi6espji9nr\",...,[]),context(_14408,_14410)),db_pull:(...,...)) at /tmp/.mount_.org.cx6j7ga/usr/lib/swi-prolog/boot/init.pl:582\n\nNote: some frames are missing due to last-call optimization.\nRe-run your program in debug mode (:- debug.) to get more detail.\n\n",
    "api:status": "api:server_error",
    "end": "2021-02-05T15:04:21.170Z",
    "start": "2021-02-05T15:04:21.170Z",
    "duration": "2021-02-05T15:04:21.170Z"
  }
}

Info (please complete the following information):

GavinMendelGleason commented 3 years ago

Fixed in 822b7f9