Skip to content
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

Formatting of function deprecation warning has missing argument #52515

Closed
dveeden opened this issue Apr 11, 2024 · 1 comment · Fixed by #52516
Closed

Formatting of function deprecation warning has missing argument #52515

dveeden opened this issue Apr 11, 2024 · 1 comment · Fixed by #52516
Assignees
Labels
severity/minor sig/sql-infra SIG: SQL Infra type/bug The issue is confirmed as a bug.

Comments

@dveeden
Copy link
Contributor

dveeden commented Apr 11, 2024

Bug Report

The formatting of some errors is wrong, causing a %!s(MISSING) to be added to the message

1. Minimal reproduce step (Required)

SELECT JSON_MERGE('{"a": 5}', '{"foo": "bar"}');
SELECT PASSWORD('secret');

2. What did you expect to see? (Required)

tidb> SELECT JSON_MERGE('{"a": 5}', '{"foo": "bar"}');
+------------------------------------------+
| JSON_MERGE('{"a": 5}', '{"foo": "bar"}') |
+------------------------------------------+
| {"a": 5, "foo": "bar"}                   |
+------------------------------------------+
1 row in set, 1 warning (0.00 sec)

Warning (Code 1681): JSON_MERGE is deprecated and will be removed in a future release.
tidb> SELECT PASSWORD('secret');
+-------------------------------------------+
| PASSWORD('secret')                        |
+-------------------------------------------+
| *14E65567ABDB5135D0CFD9A70B3032C179A49EE7 |
+-------------------------------------------+
1 row in set, 1 warning (0.01 sec)

Warning (Code 1681): PASSWORD is deprecated and will be removed in a future release.

3. What did you see instead (Required)

tidb> SELECT JSON_MERGE('{"a": 5}', '{"foo": "bar"}');
+------------------------------------------+
| JSON_MERGE('{"a": 5}', '{"foo": "bar"}') |
+------------------------------------------+
| {"a": 5, "foo": "bar"}                   |
+------------------------------------------+
1 row in set, 1 warning (0.00 sec)

Warning (Code 1681): JSON_MERGE is deprecated and will be removed in a future release.%!s(MISSING)
tidb> SELECT PASSWORD('secret');
+-------------------------------------------+
| PASSWORD('secret')                        |
+-------------------------------------------+
| *14E65567ABDB5135D0CFD9A70B3032C179A49EE7 |
+-------------------------------------------+
1 row in set, 1 warning (0.01 sec)

Warning (Code 1681): PASSWORD is deprecated and will be removed in a future release.%!s(MISSING)

4. What is your TiDB version? (Required)

Release Version: v8.1.0-alpha-81-g572e5c48d9
Edition: Community
Git Commit Hash: 572e5c48d98aac762fbfb3966e329cf5201bcca0
Git Branch: master
UTC Build Time: 2024-04-11 13:34:48
GoVersion: go1.21.9
Race Enabled: false
Check Table Before Drop: false
Store: unistore
@dveeden dveeden added type/bug The issue is confirmed as a bug. severity/minor labels Apr 11, 2024
@dveeden dveeden self-assigned this Apr 11, 2024
@dveeden
Copy link
Contributor Author

dveeden commented Apr 11, 2024

Looks like a regression introduced by #46759

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
severity/minor sig/sql-infra SIG: SQL Infra type/bug The issue is confirmed as a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants