Skip to content

Commit

Permalink
Merge pull request #593 from zaucker/RT59213_RPC_Error_Handling
Browse files Browse the repository at this point in the history
Fix RPC error handling
  • Loading branch information
zaucker authored Dec 5, 2024
2 parents 405f0cd + 2c5577e commit 9a5e339
Show file tree
Hide file tree
Showing 9 changed files with 83 additions and 69 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
- 6.4.2, 2024-12-04, [email protected]
- Fix RPC error handling (RT 59213)

- 6.4.1, 2024-11-22, [email protected]
- New Self Service for account creation and password reset

Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.4.1
6.4.2
46 changes: 23 additions & 23 deletions frontend/compile.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,28 +53,28 @@
"class": "agrammon.Application",
"theme": "qx.theme.Indigo",
"bootPath": "source/boot"
},
{
"class": "qxl.testtapper.Application",
"name": "testtapper",
"theme": "qx.theme.Indigo",
"title": "Qooxdoo TestTAPper",
"environment": {
"qx.icontheme": "Tango",
// "qx.test.delay.scale" : 1000,
"testtapper.testNameSpace": "agrammon.test"
},
"include": [
"agrammon.test.*",
"qx.*",
"iconfont.fontawesome5.Load",
"iconfont.material.Load"
],
"exclude": [
"qx.test.*",
"qx.module.Blocker",
"qx.module.Placement"
]
}
}
// {
// "class": "qxl.testtapper.Application",
// "name": "testtapper",
// "theme": "qx.theme.Indigo",
// "title": "Qooxdoo TestTAPper",
// "environment": {
// "qx.icontheme": "Tango",
//// "qx.test.delay.scale" : 1000,
// "testtapper.testNameSpace": "agrammon.test"
// },
// "include": [
// "agrammon.test.*",
// "qx.*",
// "iconfont.fontawesome5.Load",
// "iconfont.material.Load"
// ],
// "exclude": [
// "qx.test.*",
// "qx.module.Blocker",
// "qx.module.Placement"
// ]
// }
]
}
35 changes: 23 additions & 12 deletions frontend/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion frontend/source/class/agrammon/io/remote/Rpc.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ qx.Class.define('agrammon.io.remote.Rpc', {
let response = req.getResponse();
let status = req.getStatus();
let statusText = req.getStatusText();
console.log('Rpc.callAsync('+methodName+'): status=', status, ':', statusText, ', response=', response);
// console.error('Rpc.callAsync('+methodName+'): status=', status, ':', statusText, ', response=', response, ', error=', response.error);
let username = agrammon.Info.getInstance().getUserName();
if (response && response.error) {
let params = [
Expand All @@ -104,6 +104,7 @@ qx.Class.define('agrammon.io.remote.Rpc', {
qx.event.message.Bus.dispatchByName('agrammon.Output.invalidate');
}
qx.event.message.Bus.dispatchByName('error', params);
return;
}
else {
let retry = true;
Expand Down
20 changes: 10 additions & 10 deletions frontend/source/translation/de.po
Original file line number Diff line number Diff line change
Expand Up @@ -958,43 +958,43 @@ msgstr "%1: Sitzung abgelaufen, bitte neu anmelden"
msgid "No valid lines found in uploaded file."
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Validation error"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "The following validation errors must be resolved before approval:"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "instance"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "is mandatory"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Warning"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Some inputs must have changed while you tried to finish the module."
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Please reload the module and try again."
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "storeInput error"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "failed"
msgstr "fehlgeschlagen"

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Error in communication with server"
msgstr "Fehler in der Kommunikation mit dem Server"

Expand Down
22 changes: 11 additions & 11 deletions frontend/source/translation/en.po
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ msgstr ""
msgid "Returning from %1 to %2"
msgstr ""

#: agrammon/io/remote/Rpc.js
#: agrammon/Application.js
msgid "Please authenticate yourself"
msgstr ""

Expand Down Expand Up @@ -970,43 +970,43 @@ msgstr ""
msgid "No valid lines found in uploaded file."
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Validation error"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "The following validation errors must be resolved before approval:"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "instance"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "is mandatory"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Warning"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Some inputs must have changed while you tried to finish the module."
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Please reload the module and try again."
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "storeInput error"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "failed"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Error in communication with server"
msgstr ""

Expand Down
20 changes: 10 additions & 10 deletions frontend/source/translation/fr.po
Original file line number Diff line number Diff line change
Expand Up @@ -975,43 +975,43 @@ msgstr ""
msgid "No valid lines found in uploaded file."
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Validation error"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "The following validation errors must be resolved before approval:"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "instance"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "is mandatory"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Warning"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Some inputs must have changed while you tried to finish the module."
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Please reload the module and try again."
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "storeInput error"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "failed"
msgstr ""

#: agrammon/io/remote/Rest.js
#. NO LONGER USED
msgid "Error in communication with server"
msgstr ""

Expand Down
1 change: 0 additions & 1 deletion lib/Agrammon/Web/Routes.rakumod
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,6 @@ sub dataset-routes(Agrammon::Web::Service $ws) {
my $data = $ws.send-datasets($user, @datasets, $recipient, $language);
content 'application/json', $data;
CATCH {
.note;
when X::Agrammon::DB::User::UnknownUser {
conflict 'application/json', %( error => .message );
}
Expand Down

0 comments on commit 9a5e339

Please sign in to comment.