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

Adding mentioned users as PM recipients fails silently when the recipient does not exist #14982

Open
1 task
werner291 opened this issue Nov 17, 2024 · 2 comments
Labels
⚠️bug? This might be a bug

Comments

@werner291
Copy link

werner291 commented Nov 17, 2024

💡 Summary

Hi there!

Trying to send a PM, when adding a user based on mentions in the post, if the recipient does not exist (I mistyped the domain), the action fails silently on the front-end (with the backend log showing that the webfinger request fails with an error.)

Talking about the "Add" option here:
Image

The log on the backend:

INFO *  [db sql]        SELECT "MiUser"."id" AS "MiUser_id", "MiUser"."updatedAt" AS "MiUser_u
INFO *  [remote resolve-user]   WebFinger for [email protected]
ERR  *  [remote resolve-user]   Failed to WebFinger for [email protected]: request to https://raccoon.hollow.quest/.well-known/webfinger?resource=acct%3Amizah%40raccoon.hollow.quest failed, reason: cacheableLookup ENOTFOUND raccoon.hollow.quest
WARN *  [api]   failed to resolve remote user: Error: Failed to WebFinger for [email protected]: request to https://raccoon.hollow.quest/.well-known/webfinger?resource=acct%3Amizah%40raccoon.hollow.quest failed, reason: cacheableLookup ENOTFOUND raccoon.hollow.quest
INFO *  [db sql]        SELECT "MiUser"."id" AS "MiUser_id", "MiUser"."updatedAt" AS "MiUser_u
INFO *  [remote resolve-user]   WebFinger for [email protected]
ERR  *  [remote resolve-user]   Failed to WebFinger for [email protected]: request to https://raccoon.hollow.quest/.well-known/webfinger?resource=acct%3Amizah%40raccoon.hollow.quest failed, reason: cacheableLookup ENOTFOUND raccoon.hollow.quest
WARN *  [api]   failed to resolve remote user: Error: Failed to WebFinger for [email protected]: request to https://raccoon.hollow.quest/.well-known/webfinger?resource=acct%3Amizah%40raccoon.hollow.quest failed, reason: cacheableLookup ENOTFOUND raccoon.hollow.quest

🥰 Expected Behavior

The dialog gives some intelligible error message.

🤬 Actual Behavior

Nothing visible happens on the front-end, causing confusion to the user.

📝 Steps to Reproduce

  1. Start the server with pnpm run dev
  2. Open the frontend.
  3. Write up a PM that @ mentions a user on a non-existent instance domain
  4. Click "Add" for missing recipients.
  5. Observe nothing happening. Observe the error showing up in the log where pnpm is running.

💻 Frontend Environment

* Model and OS of the device(s): Framework 16; NixOS Unstable.
* Browser: Firefox 131.0.2
* Server URL: Temporary development evnironment.
* Misskey: a11b77a4158e07c18bcc57f77660cb08c0d950ea (GitHub)

🛰 Backend Environment (for server admin)

* Installation Method or Hosting Service:
* Misskey:
* Node:
* PostgreSQL:
* Redis:
* OS and Architecture:

Do you want to address this bug yourself?

  • Yes, I will patch the bug myself and send a pull request
@werner291 werner291 added the ⚠️bug? This might be a bug label Nov 17, 2024
@werner291
Copy link
Author

Image

Here's the response in the dev tools

@werner291
Copy link
Author

Looks like the exception is simply not handled: Uncaught (in promise)
Object { message: "Failed to resolve remote user.", code: "FAILED_TO_RESOLVE_REMOTE_USER", id: "ef7b9be4-9cba-4e6f-ab41-90ed171c7d3c", kind: "server" }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⚠️bug? This might be a bug
Projects
None yet
Development

No branches or pull requests

1 participant