[MXS-3279] maxctrl password option -p throws error Created: 2020-11-02 Updated: 2021-08-02 Resolved: 2021-08-02 |
|
| Status: | Closed |
| Project: | MariaDB MaxScale |
| Component/s: | maxctrl |
| Affects Version/s: | 2.5 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | Richard Stracke | Assignee: | markus makela |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||||||
| Sprint: | MXS-SPRINT-119 | ||||||||||||
| Description |
|
If in 2.5 the -p option is used
Option --password has the same behaviour like |
| Comments |
| Comment by markus makela [ 2020-11-10 ] |
|
This appears to have happened due to changes in the argument parsing library yargs. If a parameter is given that expects an argument and no argument is given, the default value (in this case mariadb) was used. This made it impossible to know whether the user provided a password without explicitly passing an empty string to the -p option. This would require changes in the parser library and it's possible that the code was written with an expectation for it to work in a way that was not intended by the library developers. For starters, we'll update the command help output to mention that passing an empty string as the password will cause it to be read from the standard input. |
| Comment by markus makela [ 2020-11-17 ] |
|
The output of the --help command now explains that the option requires an argument and it must be an empty space for the password to be queried. |
| Comment by markus makela [ 2020-11-24 ] |
|
|
| Comment by markus makela [ 2021-08-02 ] |
|
Due to this being very complex to implement outside of the Yargs library, I'll close this as Won't Fix now that the documentation explicitly mentions the need to pass an empty string to the -p argument. |