wanderer icon indicating copy to clipboard operation
wanderer copied to clipboard

Sharing lists and trails returns 404 (/api/v1/list-share and /api/v1/trail-share)

Open eddyv321 opened this issue 3 months ago • 2 comments

What happened?

Bug: Sharing lists and trails returns 404 (/api/v1/list-share and /api/v1/trail-share)

Version

v0.17.2 (Docker latest, images built 2026-07-07)

Environment

  • Docker Compose installation
  • flomp/wanderer-web:latest
  • flomp/wanderer-db:latest
  • Firefox 153
  • PocketBase backend included in wanderer-db

Summary

Sharing an existing List or Trail with another registered user fails.

The user picker works correctly, but clicking on the selected user immediately triggers a 404 Not Found.

Steps to reproduce

  1. Create two users (eddy and camille)
  2. Login as eddy
  3. Open any existing list or trail
  4. Click Share
  5. Search for camille
  6. Click on the user

Expected behavior

The selected user should be added with the chosen permission (view or edit).

Actual behavior

The UI displays:

Uncaught (in promise) Error: Something went wrong.

The browser Network tab shows:

List sharing

PUT /api/v1/list-share
HTTP/1.1 404 Not Found

Trail sharing

PUT /api/v1/trail-share
HTTP/1.1 404 Not Found

Request origin:

Origin: http://wanderer:3010
Referer: http://wanderer:3010/trail/view/@eddy/...

Backend verification

The same endpoint also returns 404 from inside the Docker network:

wget --post-data='{}' \
  --header='Content-Type: application/json' \
  http://db:8090/api/v1/trail-share

Result:

HTTP/1.1 404 Not Found

The same happens with /api/v1/list-share.

This confirms the backend itself is missing these routes.

Database investigation

The database contains the expected sharing tables:

  • list_share
  • trail_share
  • activitypub_actors

Manually inserting records into list_share using the ActivityPub actor ID works correctly, proving that the data model is functional.

It looks like the frontend still calls the sharing API, but the backend no longer exposes these endpoints.

Impact

  • ❌ Cannot share lists with registered users
  • ❌ Cannot share trails with registered users
  • ✅ Manual SQL insertion into list_share works as a workaround

Thanks for the great project!

Image Image

Version

v0.17.2

eddyv321 avatar Aug 15 '26 16:08 eddyv321

Confirmed on v0.20.0.

I upgraded to:

  • wanderer-web v0.20.0
  • wanderer-db v0.20.0
  • Meilisearch v1.23.0

The migration completed successfully and all data was reindexed (115 trails, 12 lists).

However, the bug is still present.

Trail sharing

  1. Open any trail
  2. Click Share
  3. Select another local user

Result:

PUT /api/v1/trail-share → 404 Not Found

List sharing

The exact same issue occurs when sharing a list:

PUT /api/v1/list-share → 404 Not Found

User search works correctly; the failure happens only when the PUT request is sent.

eddyv321 avatar Aug 15 '26 16:08 eddyv321

Closing this issue.

This was not a backend bug. The recipient user had Privacy → Private enabled. In that mode, Wanderer intentionally prevents other users from sharing trails and lists with that account.

After changing the recipient profile to Public, both trail sharing and list sharing work correctly on v0.20.0.

The only minor issue is that the API returns 404 Not Found instead of a more explicit error, but the sharing restriction itself is intentional.

eddyv321 avatar Aug 16 '26 08:08 eddyv321