PratikSavla / aio-bot

This is all in one chatbot. When you start conversation it sees your face and identifies if it has previously talked to you(Not supported in latest versions). It also checks for your emotion in between conversation. This emotion data is then used to help you whenever it detects you are sad or angry. It can search anything you ask on the internet.
Creative Commons Zero v1.0 Universal
22 stars 10 forks source link

Invalid token error #5

Closed saurabhpathak94 closed 3 years ago

saurabhpathak94 commented 3 years ago

THIS IS WHAT I GET:

C:\Users\saura\Downloads\aio-bot-master\aio-bot-master>python main.py 2021-04-07 13:52:12.359183: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cudart64_110.dll'; dlerror: cudart64_110.dll not found 2021-04-07 13:52:12.359329: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine. 2021-04-07 13:52:14.621459: I tensorflow/stream_executor/platform/default/dso_loader.cc:49] Successfully opened dynamic library nvcuda.dll 2021-04-07 13:52:15.612718: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1733] Found device 0 with properties: pciBusID: 0000:01:00.0 name: GeForce GTX 1650 Ti computeCapability: 7.5 coreClock: 1.485GHz coreCount: 16 deviceMemorySize: 4.00GiB deviceMemoryBandwidth: 178.84GiB/s 2021-04-07 13:52:15.613721: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cudart64_110.dll'; dlerror: cudart64_110.dll not found 2021-04-07 13:52:15.614767: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cublas64_11.dll'; dlerror: cublas64_11.dll not found 2021-04-07 13:52:15.617446: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cublasLt64_11.dll'; dlerror: cublasLt64_11.dll not found 2021-04-07 13:52:15.618299: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cufft64_10.dll'; dlerror: cufft64_10.dll not found 2021-04-07 13:52:15.618992: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'curand64_10.dll'; dlerror: curand64_10.dll not found 2021-04-07 13:52:15.619551: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cusolver64_11.dll'; dlerror: cusolver64_11.dll not found 2021-04-07 13:52:15.620370: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cusparse64_11.dll'; dlerror: cusparse64_11.dll not found 2021-04-07 13:52:15.620953: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cudnn64_8.dll'; dlerror: cudnn64_8.dll not found 2021-04-07 13:52:15.621055: W tensorflow/core/common_runtime/gpu/gpu_device.cc:1766] Cannot dlopen some GPU libraries. Please make sure the missing libraries mentioned above are installed properly if you would like to use GPU. Follow the guide at https://www.tensorflow.org/install/gpu for how to download and setup the required libraries for your platform. Skipping registering GPU devices... 2021-04-07 13:52:15.624046: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX AVX2 To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags. 2021-04-07 13:52:15.625183: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1258] Device interconnect StreamExecutor with strength 1 edge matrix: 2021-04-07 13:52:15.626426: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1264] Traceback (most recent call last): File "C:\Users\saura\AppData\Roaming\Python\Python39\site-packages\cryptography\fernet.py", line 102, in _get_unverified_token_data data = base64.urlsafe_b64decode(token) File "C:\Program Files\Python39\lib\base64.py", line 133, in urlsafe_b64decode return b64decode(s) File "C:\Program Files\Python39\lib\base64.py", line 87, in b64decode return binascii.a2b_base64(s) binascii.Error: Incorrect padding

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Users\saura\Downloads\aio-bot-master\aio-bot-master\main.py", line 32, in chat() File "C:\Users\saura\Downloads\aio-bot-master\aio-bot-master\main.py", line 9, in chat decryp(template) File "C:\Users\saura\Downloads\aio-bot-master\aio-bot-master\utils.py", line 142, in decryp encrypted = f.decrypt(message) File "C:\Users\saura\AppData\Roaming\Python\Python39\site-packages\cryptography\fernet.py", line 75, in decrypt timestamp, data = Fernet._get_unverified_token_data(token) File "C:\Users\saura\AppData\Roaming\Python\Python39\site-packages\cryptography\fernet.py", line 104, in _get_unverified_token_data raise InvalidToken cryptography.fernet.InvalidToken

PratikSavla commented 3 years ago

This issue occurs when you are using different key to decrypt the file. You will have to change the key in the utils file at this line.