XX-net/XX-Net · critical
download xxnet zip fail:
Error message
download xxnet zip fail:
What it means
After successfully fetching README and resolving the version, downloading the XX-Net zip release file failed; the code does `raise "download xxnet zip fail:" + download_path` (a string raise — TypeError on Python 3). The download URL points to the GitHub release archive for the resolved version.
Source
Thrown at code/default/launcher/setup.py:79
if m:
version = m.group(1) + "." + m.group(2) + "." + m.group(3)
return m.group(0), version
except Exception as e:
xlog.exception("get version fail:%s", e)
raise "get_version_fail:" % readme_file
readme_url = "https://raw.githubusercontent.com/XX-net/XX-Net/master/README.md"
readme_targe = os.path.join(download_path, "README.md")
if not os.path.isdir(download_path):
os.mkdir(download_path)
if not download_file(readme_url, readme_targe):
raise "get README fail:" + readme_url
xxnet_url, xxnet_version = get_xxnet_url_version(readme_targe)
xxnet_unzip_path = os.path.join(download_path, "XX-Net-%s" % xxnet_version)
xxnet_zip_file = os.path.join(download_path, "XX-Net-%s.zip" % xxnet_version)
if not download_file(xxnet_url, xxnet_zip_file):
raise "download xxnet zip fail:" + download_path
with zipfile.ZipFile(xxnet_zip_file, "r") as dz:
dz.extractall(download_path)
dz.close()
def install_xxnet_files():
def sha1_file(filename):
import hashlib
BLOCKSIZE = 65536
hasher = hashlib.sha1()
try:
with open(filename, 'rb') as afile:
buf = afile.read(BLOCKSIZE)
while len(buf) > 0:
hasher.update(buf)
buf = afile.read(BLOCKSIZE)View on GitHub (pinned to cfa5bc17b6)
Solutions
- Verify the parsed xxnet_version and that https://github.com/XX-net/XX-Net/releases/download/.../<version> zip actually exists
- Manually download the zip into download_path and re-run setup
- Fix network/proxy access to github.com release assets
- Use a real exception and log the failing URL for diagnosability
Example fix
# before
if not download_file(xxnet_url, xxnet_zip_file):
raise "download xxnet zip fail:" + download_path
# after
if not download_file(xxnet_url, xxnet_zip_file):
raise RuntimeError("download xxnet zip fail:" + xxnet_url) Defensive patterns
Strategy: retry
Validate before calling
import urllib.request urllib.request.urlopen(HEAD-request-to-release-url) status == 200 # verify zip URL exists
Try / catch
for attempt in range(3):
if download_file(xxnet_url, xxnet_zip_file):
break
time.sleep(2 ** attempt)
else:
raise RuntimeError('download xxnet zip fail:' + xxnet_url) Prevention
- Validate the resolved version/URL before downloading
- Ensure disk space and write perms on download_path
- Pre-place the zip manually in restricted environments
When it happens
Trigger: download_file returns False for the XX-Net-<version>.zip URL — network blocked to github release assets, release asset missing for the parsed version, or disk/path issues in download_path.
Common situations: GitHub release downloads blocked or throttled, version parsed incorrectly (regex matched a stale link so the zip URL 404s), insufficient disk space or unwritable download_path.
Related errors
- time out
- get README fail:
- time out
- download size:%d, need size:%d, download fail.
- download %s to %s fail:%r
AI-assisted analysis of XX-net/XX-Net@cfa5bc17b6 (2026-08-27).
Data as JSON: /api/errors/aea6aa49aac01530.
Report an issue: GitHub.