I am able to run my program in a console but it does not work when i set up a task
Traceback (most recent call last):
File "/home/Z3R0C1PH3R2/youtube/main.py", line 56, in <module>
resp = upload.upload_video(f"{data['title']} #shorts", f"{date} APOD update-\n{text}\n\nImage- {data['hdurl'] if 'hdurl' in data else data['url']}\nVoice using Aws Polly\n\nUploaded Automatically by a program, an experiment by Z3R0C1PH3R", vidn)
File "/home/Z3R0C1PH3R2/youtube/upload.py", line 11, in upload_video
service = Create_Service(CLIENT_SECRET_FILE, API_NAME, API_VERSION, SCOPES)
File "/home/Z3R0C1PH3R2/youtube/Google.py", line 31, in Create_Service
cred = flow.run_local_server()
File "/home/Z3R0C1PH3R2/.local/lib/python3.8/site-packages/google_auth_oauthlib/flow.py", line 457, in run_local_server
local_server = wsgiref.simple_server.make_server(
File "/usr/lib/python3.8/wsgiref/simple_server.py", line 154, in make_server
server = server_class((host, port), handler_class)
File "/usr/lib/python3.8/socketserver.py", line 452, in __init__
self.server_bind()
File "/usr/lib/python3.8/wsgiref/simple_server.py", line 50, in server_bind
HTTPServer.server_bind(self)
File "/usr/lib/python3.8/http/server.py", line 137, in server_bind
socketserver.TCPServer.server_bind(self)
File "/usr/lib/python3.8/socketserver.py", line 466, in server_bind
self.socket.bind(self.server_address)
OSError: [Errno 98] Address already in use
2022-01-21 08:11:50 -- Completed task, took 43.28 seconds, return code was 1.