In the following code snippet, I get the response as -
__main__.CheckSumNotMatched: ('Kirti matches with - ', 'Kirti', ' . They are same.')
class CheckSumNotMatched(Exception):
"""Raised when the remote file's checksum doesn't match with local file checksum"""
pass
def test(name):
try:
if name=="Kirti":
error_msg = 'Kirti matches with - ', name, '. They are same. '
raise CheckSumNotMatched(error_msg)
except CheckSumNotMatched as csnm:
logger.error(csnm)
if __name__ == "__main__":
test("Kirti")
I want the response as -
__main__.CheckSumNotMatched: Kirti matches with - Kirti. They are same.
I don't want ( and ' in the response. What should be the right way to do that?