Catch missing imports
This commit is contained in:
parent
35223a70b0
commit
5aa80c6fc9
10
download.py
10
download.py
@ -1,5 +1,11 @@
|
|||||||
import yt_dlp as yt
|
try:
|
||||||
from plyer import notification
|
import yt_dlp as yt
|
||||||
|
from plyer import notification
|
||||||
|
except:
|
||||||
|
import os
|
||||||
|
script_dir = os.path.dirname(os.path.realpath(__file__))
|
||||||
|
print("Please install dependances.\n" +
|
||||||
|
"This can be done with the command 'pip3 install -r " + script_dir + "/requierments.txt'")
|
||||||
|
|
||||||
def get(yt_url):
|
def get(yt_url):
|
||||||
ytdl_options = {
|
ytdl_options = {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user