-
Notifications
You must be signed in to change notification settings - Fork 599
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
feat(error): report the error's source chain through psql #13264
Changes from 13 commits
589d525
a474acb
148b368
0a887c0
8759113
723aa2d
e8f0365
e0d4500
39493a0
3cd7a6f
d60b7e1
2600f30
11b2834
bb0ce45
41c88a5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# User Interface Test for Error Reporting | ||
|
||
The test cases in this directory act as snapshot tests for the error reporting, to ensure that the UI does not change unexpectedly. | ||
|
||
When you find the tests in this directory failing... | ||
|
||
- First, ensure that the changes to the error messages are expected and make them look better. | ||
- Then, update the test cases by running: | ||
```bash | ||
./risedev slt './e2e_test/error_ui/**/*.slt' --override | ||
``` | ||
Please note that the minimum required version of `sqllogictest` is 0.18 or higher. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
statement error | ||
create function int_42() returns int as int_42 using link 'localhost:8815'; | ||
---- | ||
db error: ERROR: QueryError | ||
|
||
Caused by these errors (recent errors listed first): | ||
1: failed to connect to UDF service | ||
2: transport error | ||
3: error trying to connect | ||
4: invalid URL, scheme is missing | ||
|
||
|
||
statement error | ||
alter system set not_exist_key to value; | ||
---- | ||
db error: ERROR: QueryError | ||
|
||
Caused by this error: | ||
1: internal error: SystemParams error: unrecognized system param "not_exist_key" | ||
|
||
|
||
query error | ||
select v1 + v2 = v3; | ||
---- | ||
db error: ERROR: QueryError | ||
|
||
Caused by this error: | ||
1: Bind error: failed to bind expression: v1 + v2 = v3 | ||
|
||
Caused by: | ||
Item not found: Invalid column: v1 | ||
|
||
|
||
query error | ||
select 1/0; | ||
---- | ||
db error: ERROR: QueryError | ||
|
||
Caused by these errors (recent errors listed first): | ||
1: Expr error | ||
2: Division by zero |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -44,8 +44,9 @@ pub enum PsqlError { | |
#[error(transparent)] | ||
Internal(BoxedError), | ||
|
||
#[error("Panicked when processing: {0}.\n | ||
This is a bug. We would appreciate a bug report at https://github.com/risingwavelabs/risingwave/issues/new?labels=type%2Fbug&template=bug_report.yml.")] | ||
#[error("Panicked when processing: {0} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I just realized that mutli-line string already contains a There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
This is a bug. We would appreciate a bug report at: | ||
https://github.com/risingwavelabs/risingwave/issues/new?labels=type%2Fbug&template=bug_report.yml")] | ||
Panic(String), | ||
|
||
#[error("Unable to set up an ssl connection")] | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😄🤣