Skip to content

Commit

Permalink
update rpc errors
Browse files Browse the repository at this point in the history
  • Loading branch information
goodlyrottenapple committed Mar 25, 2024
1 parent 644cdaa commit 77729ac
Show file tree
Hide file tree
Showing 7 changed files with 148 additions and 130 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,88 +3,92 @@
"id": 1,
"error": {
"code": 2,
"data": {
"context": [
{
"tag": "App",
"name": "Lbl'-LT-'generatedTop'-GT-'",
"sorts": [],
"args": [
{
"tag": "App",
"name": "Lbl'-LT-'k'-GT-'",
"sorts": [],
"args": [
{
"tag": "App",
"name": "kseq",
"sorts": [],
"args": [
{
"tag": "App",
"name": "LblisInt",
"sorts": [],
"args": [
{
"tag": "App",
"name": "inj",
"sorts": [
{
"tag": "SortApp",
"name": "SortKItem",
"args": []
},
{
"tag": "SortApp",
"name": "SortK",
"args": []
}
],
"args": [
{
"tag": "EVar",
"name": "VarX",
"sort": {
"data": [
{
"term": {
"format": "KORE",
"version": 1,
"term": {
"tag": "App",
"name": "Lbl'-LT-'generatedTop'-GT-'",
"sorts": [],
"args": [
{
"tag": "App",
"name": "Lbl'-LT-'k'-GT-'",
"sorts": [],
"args": [
{
"tag": "App",
"name": "kseq",
"sorts": [],
"args": [
{
"tag": "App",
"name": "LblisInt",
"sorts": [],
"args": [
{
"tag": "App",
"name": "inj",
"sorts": [
{
"tag": "SortApp",
"name": "SortKItem",
"args": []
},
{
"tag": "SortApp",
"name": "SortK",
"args": []
}
}
]
}
]
},
{
"tag": "App",
"name": "dotk",
"sorts": [],
],
"args": [
{
"tag": "EVar",
"name": "VarX",
"sort": {
"tag": "SortApp",
"name": "SortKItem",
"args": []
}
}
]
}
]
},
{
"tag": "App",
"name": "dotk",
"sorts": [],
"args": []
}
]
}
]
},
{
"tag": "App",
"name": "Lbl'-LT-'generatedCounter'-GT-'",
"sorts": [],
"args": [
{
"tag": "EVar",
"name": "VarGENERATEDCOUNTER'Unds'CELL'Unds'c84b0b5f",
"sort": {
"tag": "SortApp",
"name": "SortInt",
"args": []
}
]
}
]
},
{
"tag": "App",
"name": "Lbl'-LT-'generatedCounter'-GT-'",
"sorts": [],
"args": [
{
"tag": "EVar",
"name": "VarGENERATEDCOUNTER'Unds'CELL'Unds'c84b0b5f",
"sort": {
"tag": "SortApp",
"name": "SortInt",
"args": []
}
}
]
}
]
}
],
"error": "Inconsistent pattern. Symbol 'Lbl'-LT-'generatedTop'-GT-'' expected 3 arguments but got 2"
},
]
}
]
}
},
"error": "Inconsistent pattern. Symbol 'Lbl'-LT-'generatedTop'-GT-'' expected 3 arguments but got 2"
}
],
"message": "Could not verify pattern"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,24 @@
"id": 1,
"error": {
"code": 2,
"data": {
"context": [
{
"tag": "EVar",
"name": "X",
"sort": {
"tag": "SortApp",
"name": "SortBool",
"args": []
"data": [
{
"term": {
"format": "KORE",
"version": 1,
"term": {
"tag": "EVar",
"name": "X",
"sort": {
"tag": "SortApp",
"name": "SortBool",
"args": []
}
}
}
],
"error": "Incorrect sort: expected SortInt{} but got SortBool{}"
},
},
"error": "Incorrect sort: expected SortInt{} but got SortBool{}"
}
],
"message": "Could not verify pattern"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
"error": {
"code": 8,
"data": {
"context": null,
"error": "Module UNKNOWN not found."
},
"message": "Invalid module"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
"error": {
"code": 8,
"data": {
"context": null,
"error": "Module UNKNOWN not found."
},
"message": "Invalid module"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@
"code": 2,
"data": [
{
"context": [
{
"term": {
"format": "KORE",
"version": 1,
"term": {
"tag": "App",
"name": "inj",
"sorts": [
Expand Down Expand Up @@ -55,12 +57,14 @@
}
]
}
],
},
"error": "Expected a predicate but found a term"
},
{
"context": [
{
"term": {
"format": "KORE",
"version": 1,
"term": {
"tag": "App",
"name": "Lblite",
"sorts": [
Expand Down Expand Up @@ -91,7 +95,7 @@
}
]
}
],
},
"error": "Inconsistent pattern. Symbol 'Lblite' expected 3 arguments but got 2"
}
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@
"code": 2,
"data": [
{
"context": [
{
"term": {
"format": "KORE",
"version": 1,
"term": {
"tag": "App",
"name": "inj",
"sorts": [
Expand Down Expand Up @@ -64,12 +66,14 @@
}
]
}
],
},
"error": "Expected a predicate but found a term"
},
{
"context": [
{
"term": {
"format": "KORE",
"version": 1,
"term": {
"tag": "DV",
"sort": {
"tag": "SortApp",
Expand All @@ -78,7 +82,7 @@
},
"value": "42"
}
],
},
"error": "Incorrect sort: expected SortBool{} but got SortInt{}"
}
],
Expand Down
60 changes: 32 additions & 28 deletions test/rpc-integration/test-subsorts/response-not-subsort.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,38 +3,42 @@
"id": 1,
"error": {
"code": 2,
"data": {
"context": [
{
"tag": "App",
"name": "inj",
"sorts": [
{
"tag": "SortApp",
"name": "SortKItem",
"args": []
},
{
"tag": "SortApp",
"name": "SortK",
"args": []
}
],
"args": [
{
"tag": "EVar",
"name": "VarX",
"sort": {
"data": [
{
"term": {
"format": "KORE",
"version": 1,
"term": {
"tag": "App",
"name": "inj",
"sorts": [
{
"tag": "SortApp",
"name": "SortKItem",
"args": []
},
{
"tag": "SortApp",
"name": "SortK",
"args": []
}
],
"args": [
{
"tag": "EVar",
"name": "VarX",
"sort": {
"tag": "SortApp",
"name": "SortKItem",
"args": []
}
}
}
]
}
],
"error": "SortKItem{} is not a subsort of SortK{}"
},
]
}
},
"error": "SortKItem{} is not a subsort of SortK{}"
}
],
"message": "Could not verify pattern"
}
}

0 comments on commit 77729ac

Please sign in to comment.