Skip to content

Commit

Permalink
Debug parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
druzsan committed Feb 7, 2024
1 parent 0aa9ffa commit 4ac4275
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions main.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/env python3
import json
import os
from typing import Any

Expand Down Expand Up @@ -79,7 +78,7 @@ def assert_valid_extra(extra: Any) -> None: ...
def assert_valid_matrix(matrix: Any) -> None:
if not isinstance(matrix, dict):
raise TypeError(
f"Matrix must be an YAML object (Python dict), but Python "
f"Matrix must be a mapping (Python dict), but Python "
f"{type(matrix)} received."
)
for variable, values in matrix.items():
Expand All @@ -106,9 +105,8 @@ def parse_matrix(input_matrix: str) -> dict:

print(yaml.dump({"matrix": matrix}))

output_matrix = json.dumps(matrix)
# output_matrix = json.dumps(matrix)
output_matrix = "{'include':[]}"

# output("matrix", output_matrix)
# setenv("MATRIX", output_matrix)
output("matrix", "{'include':{}}")
setenv("MATRIX", "{}")
output("matrix", output_matrix)
setenv("MATRIX", output_matrix)

0 comments on commit 4ac4275

Please sign in to comment.