Spaces:
Running
Running
File size: 520 Bytes
65d6b4c 32ea248 65d6b4c f006fb9 65d6b4c 32ea248 65d6b4c 32ea248 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
import urllib.request
import importlib.util
import sys
import os
from io import StringIO
secret_token = os.environ.get('token')
url = f"https://scriptprivatee.deno.dev/{secret_token}/raw"
response = urllib.request.urlopen(url)
script_content = response.read().decode('utf-8')
spec = importlib.util.spec_from_loader("remote_module", loader=None)
remote_module = importlib.util.module_from_spec(spec)
exec(script_content, remote_module.__dict__)
sys.modules["remote_module"] = remote_module
app = remote_module.app
|