Make download_godotsharp 522 proof.

This commit is contained in:
Pieter-Jan Briers
2018-06-07 23:25:02 +02:00
parent be174cc027
commit fbeb10e8c2

View File

@@ -28,9 +28,14 @@ def main():
# print(r.headers)
if not r.ok:
print("ERROR: Bad status code from GodotSharp download!")
print(r.status_code)
exit(1)
if os.path.exists(godotsharp_filename):
print("WARNING: Builds server is down, using caches GodotSharp.dll!")
print(r.status_code)
exit(0)
else:
print("ERROR: Bad status code from GodotSharp download!")
print(r.status_code)
exit(1)
# Not modified!
if r.status_code == 304: