A Python parser for MediaWiki wikicode https://mwparserfromhell.readthedocs.io/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

преди 11 години
преди 11 години
преди 11 години
преди 11 години
преди 11 години
преди 11 години
преди 11 години
преди 11 години
преди 11 години
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. v0.3 (unreleased):
  2. - Added complete support for HTML Tags, including forms like <ref>foo</ref>,
  3. <ref name="bar"/>, and wiki-markup tags like bold ('''), italics (''), and
  4. lists (*, #, ; and :).
  5. - Added support for ExternalLinks (http://example.com/ and
  6. [http://example.com/ Example]).
  7. - Wikicode's filter methods are now passed 'recursive=True' by default instead
  8. of False. This is a breaking change if you rely on any filter() methods being
  9. non-recursive by default.
  10. - Added a matches() method to Wikicode for page/template name comparisons.
  11. - The 'obj' param of Wikicode.insert_before(), insert_after(), replace(), and
  12. remove() now accepts other Wikicode objects and strings representing parts of
  13. wikitext, instead of just nodes. These methods also make all possible
  14. substitutions instead of just one.
  15. - Renamed Template.has_param() to has() for consistency with Template's other
  16. methods; has_param() is now an alias.
  17. - The C tokenizer extension now works on Python 3 in addition to Python 2.7.
  18. - Various fixes and cleanup.
  19. v0.2 (released June 20, 2013):
  20. - The parser now fully supports Python 3 in addition to Python 2.7.
  21. - Added a C tokenizer extension that is significantly faster than its Python
  22. equivalent. It is enabled by default (if available) and can be toggled by
  23. setting `mwparserfromhell.parser.use_c` to a boolean value.
  24. - Added a complete set of unit tests covering parsing and wikicode
  25. manipulation.
  26. - Renamed Wikicode.filter_links() to filter_wikilinks() (applies to ifilter as
  27. well).
  28. - Added filter methods for Arguments, Comments, Headings, and HTMLEntities.
  29. - Added 'before' param to Template.add(); renamed 'force_nonconformity' to
  30. 'preserve_spacing'.
  31. - Added 'include_lead' param to Wikicode.get_sections().
  32. - Removed 'flat' param from Wikicode.get_sections().
  33. - Removed 'force_no_field' param from Template.remove().
  34. - Added support for Travis CI.
  35. - Added note about Windows build issue in the README.
  36. - The tokenizer will limit itself to a realistic recursion depth to prevent
  37. errors and unreasonably long parse times.
  38. - Fixed how some nodes' attribute setters handle input.
  39. - Fixed multiple bugs in the tokenizer's handling of invalid markup.
  40. - Fixed bugs in the implementation of SmartList and StringMixIn.
  41. - Fixed some broken example code in the README; other copyedits.
  42. - Other bugfixes and code cleanup.
  43. v0.1.1 (released September 21, 2012):
  44. - Added support for Comments (<!-- foo -->) and Wikilinks ([[foo]]).
  45. - Added corresponding ifilter_links() and filter_links() methods to Wikicode.
  46. - Fixed a bug when parsing incomplete templates.
  47. - Fixed strip_code() to affect the contents of headings.
  48. - Various copyedits in documentation and comments.
  49. v0.1 (released August 23, 2012):
  50. - Initial release.