目前我面临一个问题。好的,让我分享一下。
我已经将这个项目部署到服务器(apache2)
中,它工作正常,所有操作都成功。但是突然它在登录时基本上得到了内部服务器错误
。当我下载日志时,它会显示RuntimeError:empty_like方法已经有一个docstring
。当我再次重新启动我的服务器时,它再次顺利工作。但我认为这需要一个永久的解决方案。我也喜欢分享日志的完整跟踪。
Internal Server Error: /
Traceback (most recent call last):
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/django/core/handlers/exception.py", line 35, in inner
response = get_response(request)
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/django/core/handlers/base.py", line 113, in _get_response
resolver_match = resolver.resolve(request.path_info)
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/django/urls/resolvers.py", line 498, in resolve
for pattern in self.url_patterns:
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/django/utils/functional.py", line 36, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/django/urls/resolvers.py", line 540, in url_patterns
patterns = getattr(self.urlconf_module, "urlpatterns", self.urlconf_module)
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/django/utils/functional.py", line 36, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/django/urls/resolvers.py", line 533, in urlconf_module
return import_module(self.urlconf_name)
File "/opt/python/ai_rest_env/lib/python3.5/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 986, in _gcd_import
File "<frozen importlib._bootstrap>", line 969, in _find_and_load
File "<frozen importlib._bootstrap>", line 958, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 673, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 665, in exec_module
File "<frozen importlib._bootstrap>", line 222, in _call_with_frames_removed
File "/opt/python/my_project/my_project/urls.py", line 19, in <module>
from apps.app_1 import urls as app_1_urls
File "/opt/python/my_project/apps/app_1/urls.py", line 19, in <module>
from .controller import main_controller
File "/opt/python/my_project/apps/app_1/controller/main_controller.py", line 11, in <module>
from .icebreaking_controller import IceBreakingController
File "/opt/python/my_project/apps/app_1/controller/icebreaking_controller.py", line 1, in <module>
from .base_controller import BaseController
File "/opt/python/my_project/apps/app_1/controller/base_controller.py", line 4, in <module>
from ..ai_model_handler.answer_validator import AnswerValidator
File "/opt/python/my_project/apps/app_1/ai_model_handler/answer_validator.py", line 6, in <module>
from ..ai_models.multiclass_cnn.multiclass_cnn_request import MultiClassCNNRequest
File "/opt/python/my_project/apps/app_1/ai_models/multiclass_cnn/multiclass_cnn_request.py", line 11, in <module>
import tensorflow as tf
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/tensorflow/__init__.py", line 22, in <module>
from tensorflow.python import pywrap_tensorflow # pylint: disable=unused-import
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/tensorflow/python/__init__.py", line 47, in <module>
import numpy as np
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/numpy/__init__.py", line 142, in <module>
from . import core
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/numpy/core/__init__.py", line 16, in <module>
from . import multiarray
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/numpy/core/multiarray.py", line 70, in <module>
def empty_like(prototype, dtype=None, order=None, subok=None):
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/numpy/core/overrides.py", line 240, in decorator
docs_from_dispatcher=docs_from_dispatcher)(implementation)
File "/opt/python/ai_rest_env/lib/python3.5/site-packages/numpy/core/overrides.py", line 204, in decorator
add_docstring(implementation, dispatcher.__doc__)
RuntimeError: empty_like method already has a docstring
技术:python3.6
我做了一些R
从文件中。
WSGIApplicationGroup指令可用于指定WSGI应用程序或WSGI应用程序集所属的应用程序组。同一应用程序组中的所有WSGI应用程序将在处理请求的进程的同一Python子解释器的上下文中执行。
在我看来,这似乎与单解释器=true有关。
并通过添加此行来配置mod_wsgi
WSGIApplicationGroup %{GLOBAL}
我观察了上一个月使用此配置的服务器日志。服务器运行时没有出现上述错误。
问题内容: 我正在尝试执行此AJAX帖子,但是由于某些原因,我遇到了服务器500错误。我可以看到它在控制器中达到了断点。因此问题似乎出在回调上。任何人? 这是应该返回的字符串: 问题答案: 我怀疑服务器方法在通过断点后会引发异常。使用Firefox / Firebug或IE8开发人员工具查看您从服务器获得的实际响应。如果有异常,您将获得YSOD html,这应有助于您确定要查找的位置。 还有一件事
在将Netbeans项目部署到Glassfish服务器时,我目前遇到了一个构建失败的错误。我从日志中得到以下错误: 异常描述:实体类[class entity.InstrumentExtref]中带注释的元素[field instrument]上的@JoinColumns不完整。当源实体类使用复合主键时,必须使用@JoinColumns为每个联接列指定@JoinColumn。name和refere
我在尝试进行返回JSON的ajax POST调用时出现内部错误。ajax调用来自JS页面: 这是我的Spring MVC调用方法: 问题是,我在这个类中只设置了几个字段(30个字段中有17个)。这是一个具有简单setter-getter的bean类。如果我设置了所有30个字段,效果很好。你能建议如何设置JSON响应,以便我可以纠正这个问题吗。
当我尝试在Hibernate中运行指定的select语句时,我遇到了一个内部服务器错误(没有写入Tomcat日志,只有500个错误)。运行传统的简单<code>select<code>语句时,我没有问题。 我正在将hibernate查询记录到我的控制台。工作正常的hibernate查询只是一个传统的select语句(): 运行< code>select x.property时的hibernate查
我在我的本地主机上开发了一个laravel应用程序,运行非常好。我正试图使用Ubuntu 20.04上的nginx将其部署到AWS Lightsail实例上。我已经上传了我的laravel应用程序,并将nginx根目录更改为laravelapp/public。 主索引页(着陆页)工作正常,但我的路线都不工作(即 /login, /about等)。当我试图访问任何路线时,我得到一个404未找到错误。
在使用包含非ASCII字符的cookie响应任何请求时,ColdFusion 11似乎会崩溃。IIS 8.5返回HTTP 500内部服务器错误(空白白页)。 复制的步骤: > 在Javascript控制台中运行以下命令,并尝试加载任何CFML页面: