mirror of
https://github.com/DictXiong/dotfiles.git
synced 2024-11-24 06:46:59 +08:00
degrade log 403 to warning (#17)
This commit is contained in:
parent
83695d48fb
commit
9778c69d78
|
@ -63,11 +63,11 @@ if __name__ == "__main__":
|
|||
logging.info("200 ok")
|
||||
exit(0)
|
||||
elif resp.status_code == 403:
|
||||
logging.error("403 forbidden")
|
||||
logging.warning("403 forbidden")
|
||||
logging.info("you may need to register your hostname and uuid")
|
||||
logging.info(f"hostname: {hostname}, uuid: {uuid}")
|
||||
exit(0)
|
||||
else:
|
||||
logging.critical("unknown error ")
|
||||
logging.critical("unknown error")
|
||||
logging.error(f"{resp.status_code}: {resp.text}")
|
||||
exit(1)
|
||||
|
|
Loading…
Reference in New Issue
Block a user