aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbashonly <88596187+bashonly@users.noreply.github.com>2024-05-20 18:01:17 -0500
committerGitHub <noreply@github.com>2024-05-20 23:01:17 +0000
commit6e36d17f404556f0e3a43f441c477a71a91877d9 (patch)
tree348a941ffa82ff1dd3870a5595975a9abea3a576
parentc36513f1be2ef3d3cec864accbffda1afaa06ffd (diff)
[build] Exclude `requests` from `py2exe` (#9982)
Authored by: bashonly
-rw-r--r--README.md2
-rwxr-xr-xbundle/py2exe.py6
2 files changed, 4 insertions, 4 deletions
diff --git a/README.md b/README.md
index cdd57b024..ad98af7c4 100644
--- a/README.md
+++ b/README.md
@@ -263,7 +263,7 @@ You can also run `make yt-dlp` instead to compile only the binary without updati
### Standalone Py2Exe Builds (Windows)
-While we provide the option to build with [py2exe](https://www.py2exe.org), it is recommended to build [using PyInstaller](#standalone-pyinstaller-builds) instead since the py2exe builds **cannot contain `pycryptodomex`/`certifi` and needs VC++14** on the target computer to run.
+While we provide the option to build with [py2exe](https://www.py2exe.org), it is recommended to build [using PyInstaller](#standalone-pyinstaller-builds) instead since the py2exe builds **cannot contain `pycryptodomex`/`certifi`/`requests` and need VC++14** on the target computer to run.
If you wish to build it anyway, install Python (if it is not already installed) and you can run the following commands:
diff --git a/bundle/py2exe.py b/bundle/py2exe.py
index 281167492..403de0024 100755
--- a/bundle/py2exe.py
+++ b/bundle/py2exe.py
@@ -42,9 +42,9 @@ def main():
# py2exe cannot import Crypto
'Crypto',
'Cryptodome',
- # py2exe appears to confuse this with our socks library.
- # We don't use pysocks and urllib3.contrib.socks would fail to import if tried.
- 'urllib3.contrib.socks'
+ # py2exe builds fail to run with requests >=2.32.0
+ 'requests',
+ 'urllib3'
],
'dll_excludes': ['w9xpopen.exe', 'crypt32.dll'],
# Modules that are only imported dynamically must be added here