<commit_before># -*- coding: utf-8 -*-
from __future__ import absolute_import, division, print_function


class PolyaxonException(Exception):
    def __init__(self, message=None):
        Exception.__init__(self, message)
        self.message = message


class PolyaxonShouldExitError(PolyaxonException):
    pass


class PolyaxonHTTPError(PolyaxonException):
    def __init__(self, endpoint, response, message=None, status_code=None):
        super().__init__()
        self.endpoint = endpoint
        self.response = response
        self.message = getattr(self, 'message', message)
        self.status_code = getattr(self, 'status_code', status_code)

    def __str__(self):
        return '{status_code} on {endpoint}.'.format(status_code=self.status_code,
                                                     endpoint=self.endpoint)


class BadRequestError(PolyaxonHTTPError):
    status_code = 400
    message = "One or more request parameters is incorrect"


class AuthenticationError(PolyaxonHTTPError):
    staticmethod = 401
    message = "Authentication failed. Retry by invoking Polyaxon login."


class AuthorizationError(PolyaxonHTTPError):<commit_msg>Fix issue with exception inheritance<commit_after># -*- coding: utf-8 -*-
from __future__ import absolute_import, division, print_function


class PolyaxonException(Exception):
    def __init__(self, message=None):
        Exception.__init__(self, message)
        self.message = message


class PolyaxonShouldExitError(PolyaxonException):
    pass


class PolyaxonHTTPError(PolyaxonException):
    def __init__(self, endpoint, response, message=None, status_code=None):
        super(PolyaxonHTTPError, self).__init__()
        self.endpoint = endpoint
        self.response = response
        self.message = getattr(self, 'message', message)
        self.status_code = getattr(self, 'status_code', status_code)

    def __str__(self):
        return '{status_code} on {endpoint}.'.format(status_code=self.status_code,
                                                     endpoint=self.endpoint)


class BadRequestError(PolyaxonHTTPError):
    status_code = 400
    message = "One or more request parameters is incorrect"


class AuthenticationError(PolyaxonHTTPError):
    staticmethod = 401
    message = "Authentication failed. Retry by invoking Polyaxon login."


class AuthorizationError(PolyaxonHTTPError):
{'fraction_non_alphanumeric': 0.08865546218487395, 'fraction_numerical': 0.0058823529411764705, 'mean_word_length': 3.4421641791044775, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3803710', 'n_tokens_mistral': 656, 'n_tokens_neox': 625, 'n_words': 154}