简体   繁体   English

ckan.plugins.core.PluginNotFoundException: 页面

[英]ckan.plugins.core.PluginNotFoundException: pages

I'm using CKAN as my open data portal.我正在使用 CKAN 作为我的开放数据门户。 It's written in Python using Pylons framework.它是在 Python 中使用 Pylons 框架编写的。 I just want to add a new page similar to about page to display the terms and conditions to the users.我只想添加一个类似于关于页面的新页面来向用户显示条款和条件。 About page comes built in.关于页面是内置的。

So I installed ckanext-pages using pip command.所以我使用 pip 命令安装了ckanext-pages What I did was below我所做的在下面

1. # Activate your CKAN virtual environment
. /usr/lib/ckan/default/bin/activate

2. # Install the pages extension.
pip install -e 'git+https://github.com/ckan/ckanext-pages.git#egg=ckanext-pages'

But now I end up with below error which is given when a requested plugin cannot be found.但是现在我遇到了以下错误,这是在找不到请求的插件时给出的。

ckan.plugins.core.PluginNotFoundException: pages ckan.plugins.core.PluginNotFoundException: 页面

Plugin resides on below path插件位于以下路径

/usr/lib/ckan/default/src

Please let me know how to fix this?请让我知道如何解决这个问题?

With your virtualenv activated, run python setup.py develop in the ckanext-pages folder. 在激活virtualenv的情况下,在ckanext-pages文件夹中运行python setup.py develop This will register the plugin so CKAN can find it. 这将注册插件,以便CKAN可以找到它。

had similar issue. 有类似的问题。 Double-check which paster you are using by command: 通过命令仔细检查您正在使用哪个paster

which paster

it must show you paster from your current virtualenv , which was /usr/lib/ckan/default in your case 它必须表现出你paster从当前virtualenv ,这是/usr/lib/ckan/default在您的情况

if you are trying @amercader answer, and getting error13 permission denied, with your venv activated:如果您正在尝试@amercader 回答,并在您的 venv 激活的情况下获得 error13 权限被拒绝:

  • which python , this will get the path to python in your venv, grap that which python ,这将在您的 venv 中获取到 python 的路径,抓住它
  • run sudo the_path_you_just_grapped setup.py develop运行sudo the_path_you_just_grapped setup.py develop

then run the database initialization as in here然后像 这里一样运行数据库初始化

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM