p12n_extract.py - complete rewrite

Code has been cleaned up (shortened lines to 80 characters).

From a functional point of view: instead of generating a static .html
file with errors, I’m creating a separate errors.json file that can be
used to create filterable views in PHP.