Closed mkoeppe closed 1 year ago
Does this occur when converting wiki together with issues?
I never tested with this option. Instead of trying to fix this, perhaps we may do the conversion in two steps: first issues and then wiki, thus avoiding the risk of unexpected complications for the current migration.
Anyway, I think I see where the bug is.
This might be the fix
diff --git a/migrate.py b/migrate.py
index d6172871ae..cdff51d92a 100755
--- a/migrate.py
+++ b/migrate.py
@@ -744,7 +744,7 @@ def trac2markdown(text, base_path, conv_help, multilines=default_multilines):
level = len(match.group(1))
heading = match.group(2).rstrip()
- if create_wiki_link_conversion_table:
+ if not isinstance(conv_help, IssuesConversionHelper) and create_wiki_link_conversion_table:
with open('wiki_path_conversion_table.txt', "a") as f:
f.write(conv_help._trac_wiki_path + '#' + heading.replace(' ', '') + ' '
+ conv_help._wiki_path + '#' + heading.replace(' ', '-'))
@kwankyu