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

fix: placeholder quoting #330

Closed

Conversation

michal-kralik
Copy link
Contributor

@michal-kralik michal-kralik commented Sep 9, 2022

Closes #324

  • Originally strconv.Quote() was used to escape the string
  • Quote() escaped sequences such as \t
  • This was unwanted behavior
  • Now it's replaced with adding quotes manually

- Originally strconv.Quote() was used to escape the string
- Quote() escaped sequences such as \t
- This was unwanted behavior
- Now it's replaced with adding quotes manually
@alecthomas
Copy link
Owner

It's intentional, why is it unwanted behaviour?

@michal-kralik
Copy link
Contributor Author

I assumed it's not intended since there does not seem to be a way to configure the default value to be \t
It's always escaped to \\t.

If you have an app which configures --split-character and you want to say it's a tab by default, your only option is to use \t which gets converted to \\t which is not the same.
Or a string such as tab, of course.

Feel free to reject if it's indeed intended behavior.

@alecthomas
Copy link
Owner

What is the actual content of .Default in that case? Is it an actual tab character?

@michal-kralik
Copy link
Contributor Author

.Default is \\t in this case

@FlorianLoch
Copy link
Contributor

I thing this PR is only trying to fix the symptoms of a tag's value not being properly unquoted.

#348 should fix the underlying problem, therefore it should also resolve this issue.

@alecthomas alecthomas closed this Jan 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Kong introduces extra backslashes in argument defaults
3 participants