Skip to content

Commit e7a9103

Browse files
authored
replace single quotes with escaped (#88)
1 parent 416fb2a commit e7a9103

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

scripts/parse_and_validate_properties_txt.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,9 @@ def set_output_error(msg):
131131

132132
print(f"properties text: {properties_raw}") # just for debugging, should do this via logging levels
133133

134+
# replace occurrences of single quotes with two single quotes.
135+
# this is because github actions will delimit strings with single quotes, and escapes single quotes this way
136+
properties_raw = properties_raw.replace("'", "''")
134137
try:
135138
if type_ == 'library':
136139
props = validate_new_library(parse_text(properties_raw))
@@ -147,4 +150,4 @@ def set_output_error(msg):
147150
contribution.update(props)
148151

149152
print(f"properties dict: {contribution}") # just for debugging, should do this via logging levels
150-
set_output(json.dumps(contribution))
153+
set_output(contribution)

0 commit comments

Comments
 (0)