Skip to content

Commit

Permalink
Use pathlib.Path.stem to extract file name.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jake Adams authored and Jake Adams committed Feb 28, 2025
1 parent b6f41ce commit efe551a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion issue_metrics.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"""

import shutil
from pathlib import Path
from typing import List, Union

import github3
Expand Down Expand Up @@ -350,7 +351,7 @@ def main(): # pragma: no cover
output_file=output_file,
)

file_name_without_extension = output_file.split(".")[0]
file_name_without_extension = Path(output_file).stem
max_char_count = 65535
if markdown_too_large_for_issue_body(output_file, max_char_count):
split_markdown_file(output_file, max_char_count)
Expand Down

0 comments on commit efe551a

Please sign in to comment.