Django'模块'对象不可调用

时间:2015-08-20 09:54:08

标签: python django typeerror

您好我正在处理一个我处理医疗信息的课程项目。所以我想到了使用INDIVO服务器。我正在尝试安装indivo_ui_server。我收到错误,我也安装了模式包。该软件包包含三个文件和一个 init .py。我正在尝试在 windows 中安装。

enter image description here

以下代码为from django.conf.urls import patterns from django.conf.urls.defaults import include urlpatterns = patterns('', # HARDCODED APP PATHS!! (keep in alpha order) (r'^apps/allergies/', include('apps.allergies.urls')), (r'^apps/labs/', include('apps.labs.urls')), (r'^apps/medications/', include('apps.medications.urls')), (r'^apps/problems/', include('apps.problems.urls')), (r'^', include('ui.urls')) # Everything else to indivo )

__init__.py

以下代码为def patterns(func): empty_argspec = inspect.ArgSpec(args=[], varargs=None, keywords=None, defaults=None) assert inspect.getargspec(func) == empty_argspec, 'Pattern function should not have arguments' # TODO: make it not as weird and dirty func.__globals__['Mismatch'] = Mismatch tree = get_ast(func) transform_function(tree.body[0]) return compile_func(func, tree) (来自模式包):

{{1}}

任何人都可以解释我为什么会收到此错误。

我还尝试了link 1link 2

的建议

回溯:

enter image description here

1 个答案:

答案 0 :(得分:0)

只需从urls.py

导入所有内容即可解决导入问题
<input type="text" value="" data-require-number="true" id="belop" class="className">