Happy Monday,
There are strange people who make such links (kindof urlencoded?):
[[Második világháború#Partrasz.C3.A1ll.C3.A1s Szic.C3.ADli.C3.A1ban
.28Huskey hadm.C5.B1velet.29|Huskey hadműveletben]]
So the section title must have been copied from the URL.
Do we have a ready tool to fix these?
--
Bináris
Hello all
>From one of my assignments as a bot operator I have some code which
does template parsing and general text parsing (e.g. Image/File tags).
It is not using regex and thus able to correctly parse nested
templates and other such nasty things. I have written those as library
classes and written tests for them which cover almost all of the code.
I would now really like to contribute that code back to the community.
Would you be interested in adding this code to the pywikibot
framework? If yes, can I send the code to someone for code review or
how do you usually operate?
Greetings
Hannes
PS: wiki userpage is http://en.wikipedia.org/wiki/User:Hannes_R%C3%B6st
Hi all,
after a short discussion about the line length in the pywikibot-core
repo I made a little analysis (or more like 'gathered' the data).
Currently the maximum allowed line length is 256 characters. Flake8
counts multi-bytes characters as one character (and afaik doesn't
count the newline). The question is how easy it is to lower that to a
value between 80 and 100 (when I submit code I try to have at most 80
characters sometimes it's 81).
Maybe to 200 is short term feasible with only a 16 exceeding those.
With a maximum of 150 characters at least 47 lines need to be edited.
I used 'tox -e flake8' with the maximum line length set to 80 and then
only used E501 entries. Some lines were garbled on the output like
“./pywikibot/1: E501 line too long (82 > 80 characters)”. I tried to
repair those lines if there was at least some kind of file name and
line number (e.g. “ase.py:365”) but I deleted the rest. So those
statistics only show the lowest number but I don't expect to much
missing data.
The data is gathered from ad6920135ef015855724ac660fa0dcfb1459cfda.
And is available sorted line number first (so they could be fixed in
reversed order) or sorted with line length first (so super long lines
can be fixed primarily). There is a gist which contains both lists and
a list of the quantity of all line lengths [1] and a Google
Spreadsheet containing just the quantity numbers [2] to determine
easily how many would need to be solved when enforcing a specific
limit.
Fabian
[1]: https://gist.github.com/xZise/3d15a742a9a4f472b3b2
[2]: https://docs.google.com/spreadsheets/d/1lbCDURzpTm1uViUJ3Awa2C4J-TGzi1DfJWz…