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

Kanban does not work after importing from another Vikunja install #412

Open
christiaangoossens opened this issue Feb 20, 2025 · 14 comments
Open

Comments

@christiaangoossens
Copy link

Description

Bug: Not all tasks are visible on the Kanban board after exporting a list (from one Vikunja install) and importing it into another Vikunja install. Tasks show fine on the List view every time.

Steps to reproduce

  • Create a new project
  • Fill it with tasks
  • Put the tasks in random columns on the Kanban board
  • Export all data in your Vikunja install
  • Open a new blank install
  • Import your Vikunja export from the previous install
  • Go to the same project
  • Refresh the page multiple times to see that only one column (or none) is filled with tasks and that multiple tasks are not visible, even though they all show up on the List view

Technical details

You can see the effect in the API responses too, so it's not a frontend bug, here's an example:

Image

Here, the first two columns have no tasks (null) and the Done column has tasks in it.

If you refresh, the output might look like this:

Image

Even though nothing changed, suddenly only the first column includes tasks.

Reproducibility on the test server

This cannot be reproduced on the demo server, as export/import is disabled.

Vikunja Version

0.24.6

Browser and version

No response

Can you reproduce the bug on the Vikunja demo site?

No

Screenshots

No response

@kolaente
Copy link
Member

Can you reproduce that with an unstable build? Are you using typesense?

@christiaangoossens
Copy link
Author

I will try that with unstable soon and get back to you. I am using Typesense (I was not with the previous install if that matters).

@kolaente
Copy link
Member

Does it work without typesense?

@christiaangoossens
Copy link
Author

Works perfectly fine without Typesense, so that's the culprit here. Here's some logs of loading a Kanban page that I pulled before disabling Typesense:

<time>: WARNING	▶ 1daf6 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WEB 	▶ <ip>  GET 200 /api/v1/projects/20 4.2092ms -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/projects/20/views/74/tasks?sort_by[]=position&order_by[]=asc&filter=&filter_include_nulls=false&filter_timezone=Europe%2FAmsterdam&s=&expand=subtasks&page=1 10.940063ms -<ua>
<time>: WARNING	▶ 1db0e Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db11 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db14 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db17 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db1a Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db1d Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WEB 	▶ <ip>  GET 200 /api/v1/projects/20/views/75/tasks?filter=&filter_include_nulls=false&s=&per_page=25&page=1 33.155676ms -<ua>
<time>: WEB 	▶ <ip>  POST 200 /api/v1/user/token 830.572µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/user 823.87µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/avatar/christiaangoossens?size=50&=1740158067874 1.071002ms -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/avatar/christiaangoossens?size=50&=1740158067890 735.783µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /projects/20/75 153.694µs -<ua>
<time>: WEB 	▶ <ip>  GET 304 /assets/index-i4VRmjeA.css 81.712µs -<ua>
<time>: WEB 	▶ <ip>  GET 304 /assets/index-BdIWn3Ve.js 153.031µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/info 75.445µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/user 850.669µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/avatar/christiaangoossens?size=50&=1740158068153 903.888µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/notifications?page=1 1.60407ms -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/projects?is_archived=true&page=1 13.857759ms -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/labels?page=1 19.103782ms -<ua>
<time>: WARNING	▶ 1db4e Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WEB 	▶ <ip>  GET 200 /api/v1/projects/20 3.761075ms -<ua>
<time>: WARNING	▶ 1db53 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db56 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db59 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db5c Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db5f Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WEB 	▶ <ip>  GET 200 /api/v1/projects/20/views/75/tasks?filter=&filter_include_nulls=false&s=&per_page=25&page=1 25.727235ms -<ua>
<time>: WEB 	▶ <ip>  GET 200 /workbox-v7.1.0/workbox-sw.js 160.009µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /workbox-v7.1.0/workbox-routing.prod.js 291.799µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /sw.js 1.241199ms -<ua>
<time>: WEB 	▶ <ip>  GET 200 /workbox-v7.1.0/workbox-core.prod.js 197.002µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /projects/20/75 164.693µs -<ua>
<time>: WEB 	▶ <ip>  GET 304 /assets/index-i4VRmjeA.css 52.874µs -<ua>
<time>: WEB 	▶ <ip>  GET 304 /assets/index-BdIWn3Ve.js 43.487µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/info 116.044µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/user 859.579µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/avatar/christiaangoossens?size=50&=1740158069006 1.018532ms -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/notifications?page=1 712.33µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/labels?page=1 6.764153ms -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/projects?is_archived=true&page=1 10.497447ms -<ua>
<time>: WARNING	▶ 1db8b Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WEB 	▶ <ip>  GET 200 /api/v1/projects/20 4.184145ms -<ua>
<time>: WARNING	▶ 1db91 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db94 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db97 Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db9a Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WARNING	▶ 1db9d Unable to fetch tasks from Typesense, error was 'status: 404 response: {"message": "Not found."}'. Falling back to db.
<time>: WEB 	▶ <ip>  GET 200 /api/v1/projects/20/views/75/tasks?filter=&filter_include_nulls=false&s=&per_page=25&page=1 21.963477ms -<ua>
<time>: WEB 	▶ <ip>  GET 304 /sw.js 74.096µs -<ua>
<time>: WEB 	▶ 10.42.2.254  GET 200 /api/v1/info 142.596µs - kube-probe/1.29
<time>: WEB 	▶ 10.42.2.254  GET 200 /api/v1/info 144.822µs - kube-probe/1.29
<time>: WEB 	▶ <ip>  POST 200 /api/v1/user/token 1.049351ms -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/avatar/christiaangoossens?size=50&=1740158074957 747.509µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/user 772.531µs -<ua>
<time>: WEB 	▶ <ip>  GET 200 /api/v1/avatar/christiaangoossens?size=50&=1740158074981 661.892µs -<ua>

Maybe it's not related to the import at all, but only to Typesense fallback to DB with the Kanban board?

(Also, can you check my christiaangoossens account on your Git server kolaente.dev? I logged in with Github to create an issue/PR for https://kolaente.dev/vikunja/helm-chart, but I can't see any repositories when logged in. Maybe you need to approve the account manually?)

@christiaangoossens
Copy link
Author

Additional info: Typesense has been enabled for this new instance from the start, I did not do an index because there were no tasks yet. Then, afterwards I imported the backup through the UI, so all tasks should have been indexed automatically right?

@kolaente
Copy link
Member

Maybe it's not related to the import at all, but only to Typesense fallback to DB with the Kanban board?

Does it work if you reindex? https://vikunja.io/docs/cli/#index

(Also, can you check my christiaangoossens account on your Git server kolaente.dev? I logged in with Github to create an issue/PR for https://kolaente.dev/vikunja/helm-chart, but I can't see any repositories when logged in. Maybe you need to approve the account manually?)

I've enabled your account.

@christiaangoossens
Copy link
Author

I re-enabled Typesense and the issue came back. Then first ran vikunja index -p with this output:

2025-02-21T17:40:54Z: INFO      ▶ 001 Using config file: /etc/vikunja/config.yml
2025-02-21T17:40:54Z: INFO      ▶ 003 Running migrations…
2025-02-21T17:40:54Z: INFO      ▶ 06b Ran all migrations successfully.
2025-02-21T17:40:54Z: INFO      ▶ 06c Indexing changed tasks… This may take a while.
2025-02-21T17:40:54Z: ERROR     ▶ 06f [Typesense Sync] No typesense sync stats yet, please run a full index via the CLI first
2025-02-21T17:40:54Z: INFO      ▶ 071 Done!

And then vikunja index with this output:

2025-02-21T17:41:01Z: INFO      ▶ 001 Using config file: /etc/vikunja/config.yml
2025-02-21T17:41:01Z: INFO      ▶ 003 Running migrations…
2025-02-21T17:41:01Z: INFO      ▶ 06b Ran all migrations successfully.
2025-02-21T17:41:01Z: INFO      ▶ 06c Indexing all tasks… This may take a while.
2025-02-21T17:41:02Z: INFO      ▶ 695 Done!

After that it works again. Does it not run a full index when first setting up (Typesense was enabled before I added tickets in the importer)?

@christiaangoossens
Copy link
Author

Nevermind, the Kanban view now works with Typesense, but all other views have many missing tasks. Disabling Typesense shows everything correctly again.

@kolaente
Copy link
Member

After that it works again. Does it not run a full index when first setting up (Typesense was enabled before I added tickets in the importer)?

No, because Vikunja has no way of knowing whether this was enabled previously. And it might take a long time to index everything, the current way allows doing this in the background and only "switching" afterwards.

Nevermind, the Kanban view now works with Typesense, but all other views have many missing tasks. Disabling Typesense shows everything correctly again.

Does this only happen in one specific project or in general?

@christiaangoossens
Copy link
Author

No, because Vikunja has no way of knowing whether this was enabled previously. And it might take a long time to index everything, the current way allows doing this in the background and only "switching" afterwards.

I would expect it to do an initial (empty) index upon first migrating the database (fully empty DB). Typesense has never been disabled for this install (until today). Should I have done an index on the empty db at the start manually?

Does this only happen in one specific project or in general?

All projects it seems, only since the index. Kanbans show correctly, but List, Table and Gantt are missing tasks.

@kolaente
Copy link
Member

All projects it seems, only since the index. Kanbans show correctly, but List, Table and Gantt are missing tasks.

Are they missing all tasks or only some?

@christiaangoossens
Copy link
Author

All projects it seems, only since the index. Kanbans show correctly, but List, Table and Gantt are missing tasks.

Are they missing all tasks or only some?

It seems that all list were capped to 1. Individual lists only showed 1 task, but also a filter spanning multiple lists only showed 1.

@kolaente
Copy link
Member

kolaente commented Feb 21, 2025 via email

@christiaangoossens
Copy link
Author

New projects as well?

Am 21. Februar 2025 19:51:21 MEZ schrieb Christiaan Goossens @.***>:

Non imported? It seems to be for all of them. I turned Typesense back off already to make it usable again, so I would have to test it another time.

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

No branches or pull requests

2 participants