mirror of
https://github.com/ditkrg/todo-to-issue-action.git
synced 2026-01-22 13:56:44 +00:00
Several related bugs that stem from a diff that contains both deletions and additions. Specifically, the line numbers aren't counted correctly, leading to - issue URL can't be inserted because it can't find the right line in the latest file - generated issue references the wrong line number - closed issue references the wrong line number See GitHub issue #236 The last item might not have any actual impact as (I think) it's just informational. But it'd still be better if it reported the correct line number of the deletion, which necessarily has to be relative to the _old_ file's line number, not the updated file's. As there is no solution in place yet for these bugs, the unittest is marked as an expected failure
16 lines
459 B
Diff
16 lines
459 B
Diff
diff --git a/example_file.py b/example_file.py
|
|
index 6b0c6cf..b37e70a 100644
|
|
@@ -1,3 +1,9 @@
|
|
+def imaginative_string():
|
|
+ return 'figment of my imagination'
|
|
+
|
|
def hello_world():
|
|
- # TODO: Come up with a more imaginative greeting
|
|
- print('Hello world')
|
|
\ No newline at end of file
|
|
+ print(f'Hello {imaginative_string()}')
|
|
+
|
|
+ # TODO: Do more stuff
|
|
+ # This function should probably do something more interesting
|
|
+ # labels: help wanted
|