报错信息:
Invalid HTTP_HOST header: 'xxxx_xxxx.com'. The domain name provided is not valid according to RFC 1034/1035.
- 方法1、修改域名,去掉域名中的下划线
- 方法2、修改Django源代码(django/http/request.py文件,我的django版本是1.11.8)
host_validation_re = re.compile(r"^([a-z0-9._.-]+|\[[a-f0-9]*:[a-f0-9:]+\])(:\d+)?$")