<commit_before>
                
   ERRORHANDLER  
                



VERSION ==>                   #1.5.0

ERRORHANDLER([OPTS])          #Express MIDWR error handler (to put at end) that:
                              #  - sends ERROR.stack as response
                              #     - as HTML, JSON or text/plain according to Accept [C]
                              #  - sets RES.statusCode = ERROR.status[Code]
                              #     - 3**, 2**, 1** -> 500
                              #  - performs OPTS.log(ERROR, ERROR.message, REQ, RES)
                              #     - can be true (def), i.e. console.error()
                              #     - can be false (def is NODE_ENV 'test')
                              #  - sets X-Content-Type-Options: nosniff [S]
                              #Should only be used in development:
                              #  if ( app.get( "env" ) == "development" ) {
                              #    app.use( ERRORHANDLER() )
                              #  }<commit_msg>no commit message<commit_after>
                
   ERRORHANDLER  
                



VERSION ==>                   #1.5.1

ERRORHANDLER([OPTS])          #Express MIDWR error handler (to put at end) that:
                              #  - sends ERROR.stack as response
                              #     - as HTML, JSON or text/plain according to Accept [C]
                              #  - sets RES.statusCode = ERROR.status[Code]
                              #     - 3**, 2**, 1** -> 500
                              #  - performs OPTS.log(ERROR, ERROR.message, REQ, RES)
                              #     - can be true (def), i.e. console.error()
                              #     - can be false (def is NODE_ENV 'test')
                              #  - sets X-Content-Type-Options: nosniff [S]
                              #Should only be used in development:
                              #  if ( app.get( "env" ) == "development" ) {
                              #    app.use( ERRORHANDLER() )
                              #  }
{'fraction_non_alphanumeric': 0.3099927060539752, 'fraction_numerical': 0.006564551422319475, 'mean_word_length': 1.3748917748917748, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 23, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4233082', 'n_tokens_mistral': 2485, 'n_tokens_neox': 2461, 'n_words': 150}