Jakub Klinkovský
df3a9054cb
Port the fix for #197 to the C tokenizer
4 лет назад
Jakub Klinkovský
1cf0754e73
Proposed fix for https://github.com/earwig/mwparserfromhell/issues/197
4 лет назад
Ben Kurtovic
cccbd3ef11
Version bump
3 лет назад
Ben Kurtovic
0f05dfa546
release/0.6
3 лет назад
Jakub Klinkovský
90061b6844
Fix parsing of section headings inside templates ( #233 )
Fixes #198
Co-authored-by: Ben Kurtovic <ben.kurtovic@gmail.com>
3 лет назад
Ben Kurtovic
b7b3b2e33e
Update changelog; minor tweak to file headers
3 лет назад
Ben Kurtovic
d36aa34997
Don't use f-strings; we still support Python 3.5
3 лет назад
Ben Kurtovic
1c983d3738
Assorted cleanup, linter fixes, and improvements for Python 3
3 лет назад
Ben Kurtovic
237798a17e
Update tag definitions
3 лет назад
AntiCompositeNumber
f241829d37
Make nodes.template.Template a bit more dict-like ( #252 )
* nodes: add a `default` param to Template.get
Similar to dict.get, Template.get with a default param supplied will
return that value instead of raising an exception. If default is unset,
Template.get will keep its previous behavior and raise an exception.
* nodes: Add __getitem__, __setitem__, and __delitem__ to Template
These are just aliases for existing methods, without the ability to
specifiy additional parameters. However, including them makes Template
more dict-like, so it's a good idea to have them.
* nodes: Use def instead of assignment of a lambda in Template
Per PEP8, there is no benefit to using a lambda here, and some
downsides. It's the same number of SLOC either way, so might as well
change it.
3 лет назад
Kunal Mehta
7e5297fbe6
Drop Python 2 support
Fixes #221 .
4 лет назад
Yuri Astrakhan
4065624150
updated comment/license
4 лет назад
Yuri Astrakhan
aa37425a9b
move smart_list into sub-package/multiple files
Step one of refactoring - making SmartList into its own
package, with each class having its own file. No code
changes were made.
Note that SmartList and ListProxy import each other,
so had to import SmartList as a full package name
rather than use from ... import ... construct.
4 лет назад
Yuri Astrakhan
e66a2db0ed
add missing public items to __all__
Added a few more public classes, and sorted the __all__ value.
The Attribute and Parameter classes are not included as they can
be imported from the `mwparserfromhell.nodes.extras` without
linter complaining. They could be added to this __all__ too.
4 лет назад
Ben Kurtovic
b3c98efd22
Fix a parsing bug involving deeply nested style tags ( fixes #224 )
4 лет назад
Ben Kurtovic
2a4e1f4316
Add contexts.describe() for debugging
4 лет назад
Ben Kurtovic
b6e4c59004
Switch to requests for basic API example ( closes #219 ); update links
4 лет назад
Ben Kurtovic
6136b1b205
Make Wikicode.matches() treat _ and space as equivalent ( fixes #216 )
4 лет назад
Ben Kurtovic
9965709934
Version bump; update release script; update Travis
5 лет назад
Ben Kurtovic
18646f712f
release/0.5.4
5 лет назад
Ben Kurtovic
8c5f554406
Add guard against a rare crash in the C tokenizer
5 лет назад
Ben Kurtovic
98dc30902d
Version bump
5 лет назад
Ben Kurtovic
3d116713b2
release/0.5.3
5 лет назад
Ben Kurtovic
fa98aad408
Bump copyright [skip ci]
5 лет назад
Ben Kurtovic
4775131717
Fix not memoizing bad routes after failing inside a table ( fixes #206 )
5 лет назад
Ben Kurtovic
6e61c99c90
Update API query example; clarify docstring
5 лет назад
Ben Kurtovic
708bee59e1
Minor cleanup
5 лет назад
Ben Kurtovic
83bcb902b8
Support manual construction of Node objects ( fixes #214 )
5 лет назад
Ben Kurtovic
0ae5f6d641
Fix regression in previous commit on _ListProxy transformations ( fixes #213 )
5 лет назад
Ben Kurtovic
840a88bcd6
Fix Wikicode transformation methods on empty sections ( fixes #212 )
5 лет назад
Ben Kurtovic
2c0b9e5795
Version bump, fix release script again [ci skip]
5 лет назад
Ben Kurtovic
8a88198aae
release/0.5.2
5 лет назад
Ben Kurtovic
2c206bc16b
Fix crash due to PyList_GET_SIZE being applied to a dict ( fixes #208 )
5 лет назад
Ben Kurtovic
6de7d41733
Fix signals getting stuck inside the C tokenizer ( #206 )
5 лет назад
Hugo
e457b39f32
Upgrade Python syntax with pyupgrade https://github.com/asottile/pyupgrade
5 лет назад
Hugo
59636609db
Drop support for EOL Python
5 лет назад
Kunal Mehta
e506380318
Add <wbr> to definitions.py
Added to MediaWiki in ff74113bea (T54468).
5 лет назад
Ben Kurtovic
b354c56755
Version bump; cleanup [ci skip]
6 лет назад
Ben Kurtovic
cb96b4378a
release/0.5.1
6 лет назад
Ben Kurtovic
86c805d59b
Don't get stuck in tags with unclosed quoted attributes ( fixes #190 ).
6 лет назад
Ben Kurtovic
7a30e47f76
Some improvements to whitespace recognition; unit tests ( #185 ).
6 лет назад
Ben Kurtovic
cdc97f6f29
Version bump for 0.6 [ci skip]
7 лет назад
Ben Kurtovic
3ffc13bfd4
release/0.5
7 лет назад
Ben Kurtovic
cd4f90e663
Fix a rare parsing bug involving nested broken tags.
7 лет назад
Ben Kurtovic
7308c8055e
Not perfect, but slightly better template param space guessing ( #155 )
7 лет назад
Ben Kurtovic
5a99597eb3
Another C89 fix for MSVC.
7 лет назад
Ben Kurtovic
0ef6a2ffbe
Fix declarations for C89 compatibility (forgot MSVC needed that...)
7 лет назад
Ben Kurtovic
dc0b3ae446
Enable Windows builds on Python 3.6; try to fix again.
7 лет назад
Ben Kurtovic
6ad3b9fb2a
inttypes.h doesn't exist on Windows, so try using stdint.h
7 лет назад
Ben Kurtovic
2593675651
Remove stdbool.h from avl_tree since MSVC doesn't like it.
7 лет назад