jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/522734 )

Change subject: [bugfix] Ignore references in harvest_template.py
......................................................................

[bugfix] Ignore references in harvest_template.py

Bug: T227954
Change-Id: I6fcdb342728fecfccd9dca24126698cd0a877d02
---
M scripts/harvest_template.py
1 file changed, 4 insertions(+), 1 deletion(-)

Approvals:
  Xqt: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/scripts/harvest_template.py b/scripts/harvest_template.py
index 94404eb..16edcd9 100755
--- a/scripts/harvest_template.py
+++ b/scripts/harvest_template.py
@@ -267,7 +267,10 @@
             # We found the template we were looking for
             for field, value in fielddict.items():
                 field = field.strip()
-                value = value.strip()
+                # todo: extend the list of tags to ignore
+                value = textlib.removeDisabledParts(
+                    # todo: eventually we may want to import the references
+                    value, tags=['ref'], site=page.site).strip()
                 if not field or not value:
                     continue


--
To view, visit https://gerrit.wikimedia.org/r/522734
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.wikimedia.org/r/settings

Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I6fcdb342728fecfccd9dca24126698cd0a877d02
Gerrit-Change-Number: 522734
Gerrit-PatchSet: 1
Gerrit-Owner: Matěj Suchánek <[email protected]>
Gerrit-Reviewer: D3r1ck01 <[email protected]>
Gerrit-Reviewer: John Vandenberg <[email protected]>
Gerrit-Reviewer: Matěj Suchánek <[email protected]>
Gerrit-Reviewer: Xqt <[email protected]>
Gerrit-Reviewer: jenkins-bot (75)
_______________________________________________
Pywikibot-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/pywikibot-commits

Reply via email to