chore: patch mysql2 package for ensuring special characters in mysql password and username when only url is provided in config #539
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
With mysql latest versions, its mandatory to have special characters in password as per security policy in mysql. But with password having '@' or some other special characters, the encoded url string is not decoded properly. This issue has been discussed in detail here too - sidorares/node-mysql2#1621
Referring to the above PR discussion and its related issues discussion, I have added a patch for the library. I am raising a PR on mysql2 library too. Until my PR is merged, this patch can work and ensure test cases pass.
PR added to mysql2 library - sidorares/node-mysql2#2277
Our CI checks are also failing due to this.
Checklist
npm test
passes on your machine