Changeset 1176
- Timestamp:
- Sep 26, 2022, 1:58:33 AM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
ValBot/Python/check_intrawiki_section_links.py
r1173 r1176 69 69 if not '#' in link_text: 70 70 #pywikibot.stdout('Link doesn\'t have a section anchor in it. Skipping.') 71 continue 72 73 # If this link has an interwiki prefix, it can be ignored 74 is_interwiki = False 75 if found_iw_match == False: 76 for prefix in interwiki_prefixes: 77 if prefix + ":" in link_text: 78 #pywikibot.stdout('Skipping link {} because it is an interwiki link.'.format(link_text)) 79 is_interwiki = True 80 break 81 if is_interwiki: 71 82 continue 72 83 … … 130 141 break 131 142 132 # If we didn't match the prefix against any intrawiki prefixes, see if it matches133 # against an interwiki prefix; if so, this link can be ignored134 is_interwiki = False135 if found_iw_match == False:136 for prefix in interwiki_prefixes:137 if prefix + ":" in link_text:138 #pywikibot.stdout('Skipping link {} because it is an interwiki link.'.format(link_text))139 is_interwiki = True140 break141 if is_interwiki:142 continue143 144 143 # If we still haven't turned this match into a URL, something's gone wrong 145 144 if (found_iw_match == False) or (iw_url == ""):
Note:
See TracChangeset
for help on using the changeset viewer.