Open ehooo opened 3 years ago
flake8 monstersdb/web_parsers/dandwiki.py
monstersdb/web_parsers/dandwiki.py:5:1: F401 'pathlib.Path' imported but unused
monstersdb/web_parsers/dandwiki.py:87:5: E303 too many blank lines (2)
monstersdb/web_parsers/dandwiki.py:140:13: E303 too many blank lines (2)
monstersdb/web_parsers/dandwiki.py:178:13: E303 too many blank lines (2)
monstersdb/web_parsers/dandwiki.py:182:17: E265 block comment should start with '# '
monstersdb/web_parsers/dandwiki.py:194:25: E117 over-indented
monstersdb/web_parsers/dandwiki.py:265:5: E303 too many blank lines (2)
monstersdb/web_parsers/dandwiki.py:267:9: E265 block comment should start with '# '
monstersdb/web_parsers/dandwiki.py:311:1: E302 expected 2 blank lines, found 1
monstersdb/web_parsers/dandwiki.py:646:5: E303 too many blank lines (2)
monstersdb/web_parsers/dandwiki.py:646:34: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:647:25: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:649:39: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:650:52: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:651:27: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:653:39: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:654:40: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:655:41: E116 unexpected indentation (comment)
monstersdb/web_parsers/dandwiki.py:657:60: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:658:61: E116 unexpected indentation (comment)
monstersdb/web_parsers/dandwiki.py:659:61: E116 unexpected indentation (comment)
monstersdb/web_parsers/dandwiki.py:671:1: E302 expected 2 blank lines, found 1
monstersdb/web_parsers/dandwiki.py:673:30: W605 invalid escape sequence '\*'
monstersdb/web_parsers/dandwiki.py:707:1: E302 expected 2 blank lines, found 1
monstersdb/web_parsers/dandwiki.py:713:13: E117 over-indented
monstersdb/web_parsers/dandwiki.py:748:63: W605 invalid escape sequence '\E'
monstersdb/web_parsers/dandwiki.py:791:58: E202 whitespace before ')'
monstersdb/web_parsers/dandwiki.py:793:10: E111 indentation is not a multiple of four
monstersdb/web_parsers/dandwiki.py:793:10: E117 over-indented
monstersdb/web_parsers/dandwiki.py:836:25: E117 over-indented
monstersdb/web_parsers/dandwiki.py:879:5: E265 block comment should start with '# '
monstersdb/web_parsers/dandwiki.py:880:33: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:881:37: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:882:36: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:883:35: E261 at least two spaces before inline comment
monstersdb/web_parsers/dandwiki.py:883:121: E501 line too long (142 > 120 characters)
monstersdb/web_parsers/dandwiki.py:885:5: E265 block comment should start with '# '
monstersdb/web_parsers/dandwiki.py:913:1: W293 blank line contains whitespace
Ejemplo de clase "clean", eres libre de cambiar los nombre de funciones, tipos de datos retornados, ...
class SRD35_JsonClean(object):
def __init__(self, json_file: str):
self.json_file: str = json_file
with open(self.json_file) as f:
self.initial_data: dict = json.load(f)
self.final_data: dict = {}
def excluyendo_ficheros(self) -> bool:
pass # TODO
def insertando_titulos(self) -> None:
pass
def organizando_tipos(self) -> None:
pass # TODO
def checking_files(self) -> None:
pass # TODO
Tareas pendientes:
--donwload
para descargar todos los HTML--to_json
para convertir todos los HTML a un JSON básico (solo usando los parser)--clean
para leer todos los JSON básicos y limpiarlosNotas de implementación:
/
o\
) son distintos englob.glob('{}/*.html'.format(folder))
usarglob.glob(os.path.join(folder, '*.html'))
clean
que solo lea un JSON y tenga como funciones de clase cada uno de los pasos