Open
Description
Describe the bug
I am using this action to run a couple different metric reports and use distinct output file names. However, there is a spot in issue_metrics.py
where the file name is hardcoded to issue_metrics.md
.
https://github.com/github/issue-metrics/blob/main/issue_metrics.py#L354-L357
To Reproduce
Set the environment variable to a value other than issue_metrics.md
env:
OUTPUT_FILE: 'some_file.md'
Traceback (most recent call last):
File "/action/workspace/issue_metrics.py", line 367, in <module>
main()
~~~~^^
File "/action/workspace/issue_metrics.py", line 354, in main
if markdown_too_large_for_issue_body("issue_metrics.md", max_char_count):
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/action/workspace/markdown_helpers.py", line 16, in markdown_too_large_for_issue_body
with open(file_path, "r", encoding="utf-8") as file:
~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: 'issue_metrics.md'
Expected behavior
The script should use the output_file
variable.
Screenshots
No response
Additional context
No response
Activity