Spaces:
Running
Running
File size: 2,484 Bytes
fe3f5b0 e51bb0b fe3f5b0 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 |
'''
Constants for sandbox.
'''
import os
E2B_API_KEY = os.environ.get("E2B_API_KEY")
'''
API key for the e2b API.
'''
AZURE_BLOB_STORAGE_CONNECTION_STRING = os.environ.get("AZURE_STORAGE_CONNECTION_STRING")
'''
API key for the Azure Blob Storage.
'''
AZURE_BLOB_STORAGE_CONTAINER_NAME = "softwarearenalogs"
'''
Contianer name for the Azure Blob Storage.
'''
SANDBOX_TEMPLATE_ID: str = "bxq9sha9l55ytsyfturr"
'''
Template ID for the sandbox.
'''
SANDBOX_NGINX_PORT: int = 8000
'''
Nginx port for the sandbox.
'''
SANDBOX_TIMEOUT_SECONDS: int = 5 * 60
'''
Timeout in seconds for created sandboxes to expire.
'''
CODE_RUN_TIMEOUT_SECONDS: int = 60
'''
Timeout in seconds for code execution.
'''
SANDBOX_RETRY_COUNT: int = 3
'''
Number of times to retry the sandbox creation.
'''
INSTALLED_PYPI_PACKAGES = [
"boto3",
"botocore",
"urllib3",
"setuptools",
"requests",
"certifi",
"idna",
"charset-normalizer",
"packaging",
"typing-extensions",
"python-dateutil",
"aiobotocore",
"s3transfer",
"grpcio-status",
"pyyaml",
"six",
"fsspec",
"s3fs",
"numpy",
"wheel",
"pip",
"cryptography",
"awscli",
"pydantic",
"cffi",
"attrs",
"google-api-core",
"pycparser",
"pandas",
"importlib-metadata",
"jmespath",
"click",
"zipp",
"rsa",
"pyasn1",
"markupsafe",
"pytz",
"colorama",
"protobuf",
"platformdirs",
"jinja2",
"rich",
"tomli",
"pytest",
"pydantic-core",
"pyjwt",
"pluggy",
"aiohttp",
"virtualenv",
"jsonschema",
"googleapis-common-protos",
"cachetools",
"google-auth",
"filelock",
"wrapt",
"sqlalchemy",
"docutils",
"pyasn1-modules",
"pyarrow",
"greenlet",
"iniconfig",
"pygments",
"annotated-types",
"yarl",
"requests-oauthlib",
"tzdata",
"psutil",
"multidict",
"pyparsing",
"requests-toolbelt",
"exceptiongroup",
"werkzeug",
"soupsieve",
"oauthlib",
"beautifulsoup4",
"frozenlist",
"more-itertools",
"distlib",
"tomlkit",
"pathspec",
"aiosignal",
"grpcio",
"tqdm",
"scipy",
"async-timeout",
"pillow",
"isodate",
"anyio",
"sortedcontainers",
"decorator",
"markdown-it-py",
"deprecated",
"mypy-extensions",
"sniffio",
"httpx",
"coverage",
"openpyxl",
"flask",
"rpds-py",
"et-xmlfile"
] |