ckan / ckan

CKAN is an open-source DMS (data management system) for powering data hubs and data portals. CKAN makes it easy to publish, share and use data. It powers catalog.data.gov, open.canada.ca/data, data.humdata.org among many other sites.

Home Page:https://ckan.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Can't create a sysadmin because of permission_labels column and data column in activity table

Ombenitango opened this issue · comments

CKAN VERSION IS 2.11.0a0

I managed to install ckan by follwing this steps Here

Everything is working fine until here ckan -c /etc/ckan/default/ckan.ini db init i also get this message Initialising DB: SUCCESS suggesting that everything is fine.

But now when i run ckan -c /etc/ckan/default/ckan.ini sysadmin add admin email=admin@ckanadmin.com name=admin

I got this [SQL: INSERT INTO activity (id, timestamp, user_id, object_id, revision_id, activity_type, data, permission_labels) VALUES (%(id)s, %(timestamp)s, %(user_id)s, %(object_id)s, %(revision_id)s, %(activity_type)s, %(data)s, %(permission_labels)s)] [parameters: {'id': '64314f70-053e-4eb6-b6bd-30ae71088a47', 'timestamp': datetime.datetime(2023, 12, 17, 7, 52, 19, 215902), 'user_id': 'd84ec396-2be7-40fd-858a-6d215fb9133e', 'object_id': 'd84ec396-2be7-40fd-858a-6d215fb9133e', 'revision_id': None, 'activity_type': 'new user', 'data': None, 'permission_labels': None}] (Background on this error at: https://sqlalche.me/e/14/f405) Can anyone help me please?

I search everywhere online but i cann't find anyhelp

Try running

ckan db upgrade -p activity
# or 
ckan db pending-migrations --apply

Recently, we added a DB migration to the activity plugin. It has to be applied separately if you are using activity plugin. We are going to apply such migrations automatically, whenever you run db init, but for now you may need to do it manually