Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem with CKAN 2.10.1 #4

Open
grzegorzb1990 opened this issue Sep 8, 2023 · 1 comment
Open

Problem with CKAN 2.10.1 #4

grzegorzb1990 opened this issue Sep 8, 2023 · 1 comment

Comments

@grzegorzb1990
Copy link

Hi, I am trying to install comments on a fresh instance of ckan. When trying to create a comment via the web the request ends with a 500 status .

error log:

2023-09-08 18:09:41,986 ERROR [ckan.views.api] 'NoneType' object has no attribute 'replace'
Traceback (most recent call last):
  File "/usr/lib/ckan/default/lib/python3.8/site-packages/ckanext/comments/logic/action.py", line 131, in comment_create
    thread_dict = tk.get_action("comments_thread_show")(context.copy(), thread_data)
  File "/usr/lib/ckan/default/src/ckan/ckan/logic/__init__.py", line 551, in wrapped
    result = _action(context, data_dict, **kw)
  File "/usr/lib/ckan/default/src/ckan/ckan/logic/__init__.py", line 652, in wrapper
    return action(context, data_dict)
  File "/usr/lib/ckan/default/lib/python3.8/site-packages/ckanext/comments/logic/action.py", line 78, in thread_show
    raise tk.ObjectNotFound("Thread not found")
ckan.logic.NotFound: Thread not found

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/ckan/default/src/ckan/ckan/config/middleware/../../views/api.py", line 283, in action
    result = function(context, request_data)
  File "/usr/lib/ckan/default/src/ckan/ckan/logic/__init__.py", line 551, in wrapped
    result = _action(context, data_dict, **kw)
  File "/usr/lib/ckan/default/src/ckan/ckan/logic/__init__.py", line 652, in wrapper
    return action(context, data_dict)
  File "/usr/lib/ckan/default/lib/python3.8/site-packages/ckanext/comments/logic/action.py", line 135, in comment_create
    thread_dict = tk.get_action("comments_thread_create")(
  File "/usr/lib/ckan/default/src/ckan/ckan/logic/__init__.py", line 551, in wrapped
    result = _action(context, data_dict, **kw)
  File "/usr/lib/ckan/default/src/ckan/ckan/logic/__init__.py", line 652, in wrapper
    return action(context, data_dict)
  File "/usr/lib/ckan/default/lib/python3.8/site-packages/ckanext/comments/logic/action.py", line 45, in thread_create
    subject = thread.get_subject()
  File "/usr/lib/ckan/default/lib/python3.8/site-packages/ckanext/comments/model/thread.py", line 52, in get_subject
    getter = import_string(
  File "/usr/lib/ckan/default/lib/python3.8/site-packages/werkzeug/utils.py", line 868, in import_string
    import_name = import_name.replace(":", ".")
AttributeError: 'NoneType' object has no attribute 'replace'

ckan details:
{"help": "http://127.0.0.1/api/3/action/help_show?name=status_show", "success": true, "result": {"site_title": "CKAN", "site_description": "", "site_url": "http://127.0.0.1", "error_emails_to": "", "locale_default": "en", "extensions": ["activity", "recline_map_view", "image_view", "text_view", "recline_grid_view", "recline_view", "resource_proxy", "geo_view", "geojson_view", "comments"], "ckan_version": "2.10.1"}}

plugin version:
pip install ckanext-commentsr/lib/ckan/default/src/ckan/ckan/templates/package$
Requirement already satisfied: ckanext-comments in /usr/lib/ckan/default/lib/python3.8/site-packages (0.3.0)

@grzegorzb1990
Copy link
Author

Downgrading to version 0.2.0 of the plugin helped

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant