Undefined name: Error() --> ValueError()

This commit is contained in:
Christian Clauss 2020-01-20 14:34:56 +01:00 committed by GitHub
parent 7edebeef0d
commit a10d9a617f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -11,7 +11,7 @@ def load_pycrypto():
class DES(object):
def __init__(self, key):
if len(key) != 8 :
raise Error('DES improper key used')
raise ValueError('DES improper key used')
self.key = key
self._des = _DES.new(key,_DES.MODE_ECB)
def desdecrypt(self, data):