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

CBG-3029 use matching regex replacement for go and python code #6710

Merged
merged 1 commit into from
Mar 5, 2024

Conversation

torcolvin
Copy link
Collaborator

Replace convert_to_valid_json to get_parsed_json which should match the behavior of ConvertBackQuotedStrings. At least tabs would not previously be handled correctly.

Depending on tasks are used, the input to these functions is either a string (make_curl_task) or bytes (add_file_task).

The best thing that a reviewer can do is make sure test_convert_to_valid_json is testing appropriate cases (lifted from TestConvertBackQuotedStrings).

Removed some unused functions/parameters unrelated to this, but showing that these exceptions do show in the log file of sgcollect:

  • log_json_parsing_exceptions
  • is_valid_json

@torcolvin torcolvin requested a review from bbrks March 4, 2024 19:30
@bbrks bbrks merged commit 172ac73 into master Mar 5, 2024
30 checks passed
@bbrks bbrks deleted the CBG-3029 branch March 5, 2024 12:34
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.

2 participants