Skip to content

Commit

Permalink
Possible fix for missing double quotes. (#326)
Browse files Browse the repository at this point in the history
* Fix: updated colums, added debug mode, other fixes

Changed the Google Sheet serving as the source of submissions by providers. Columns needed to change. Added a debug mode. Other minor fixes.

* fix: Changed Google sheet source

The source for the submissions has changed, switched from a Github secret to a 1Password service account path for this URL, added a git command to remove existing and uncommitted files before starting the script.

* Fix: possible fix for double quotes missing in python step
  • Loading branch information
fredericsimard authored Feb 2, 2024
1 parent 26d51ed commit 6383da3
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions scripts/process_csv_in_github_action.swift
Original file line number Diff line number Diff line change
Expand Up @@ -258,9 +258,10 @@ if CommandLine.argc == 5 {
PYTHON_SCRIPT_OUTPUT = PYTHON_SCRIPT_OUTPUT.replacingOccurrences(of: "'", with: "ʼ")

// Replace double quotes (like "") with a single quote so there is no interference with the bash script in the next step.
PYTHON_SCRIPT_OUTPUT = PYTHON_SCRIPT_OUTPUT.replacingOccurrences(of: "\"\",", with: "\",")
PYTHON_SCRIPT_OUTPUT = PYTHON_SCRIPT_OUTPUT.replacingOccurrences(of: "=\"\"", with: "=\"")
PYTHON_SCRIPT_OUTPUT = PYTHON_SCRIPT_OUTPUT.replacingOccurrences(of: "\"\")", with: "\")")

// PYTHON_SCRIPT_OUTPUT = PYTHON_SCRIPT_OUTPUT.replacingOccurrences(of: "\"\",", with: "\",")
// PYTHON_SCRIPT_OUTPUT = PYTHON_SCRIPT_OUTPUT.replacingOccurrences(of: "=\"\"", with: "=\"")
// PYTHON_SCRIPT_OUTPUT = PYTHON_SCRIPT_OUTPUT.replacingOccurrences(of: "\"\")", with: "\")")

// return final output so the action can grab it and pass it on to the Python script.
print(PYTHON_SCRIPT_OUTPUT.dropFirst())
Expand Down

0 comments on commit 6383da3

Please sign in to comment.