spreed icon indicating copy to clipboard operation
spreed copied to clipboard

Failing to add reaction to a message

Open meldarionqeusse opened this issue 3 years ago • 2 comments

Steps to reproduce

try to add a reaction to a message and got this error image

Expected behaviour

Reaction added to message

Actual behaviour

Got an error saying Failed to add reaction

Talk app: 14.0

Custom Signaling server configured: No

Custom TURN server configured: NO

Custom STUN server configured: No

Browser

Microphone available: yes

Camera available: yes

Operating system: Windows

Browser name: Chrome

Browser version: 100

Browser log

``` Insert your browser log here, this could for example include: xhr.js:210 POST https://mydomain.com/nextcloud/ocs/v2.php/apps/spreed/api/v1/reaction/ok56zf6v/91 500 (Internal Server Error) (anonymous) @ xhr.js:210 e.exports @ xhr.js:15 e.exports @ dispatchRequest.js:56 c.request @ Axios.js:112 a.forEach.c. @ Axios.js:147 (anonymous) @ bind.js:9 (anonymous) @ messagesService.js:136 c @ runtime.js:63 (anonymous) @ runtime.js:294 (anonymous) @ runtime.js:119 ae @ guestNameStore.js:101 o @ guestNameStore.js:101 (anonymous) @ guestNameStore.js:101 (anonymous) @ guestNameStore.js:101 (anonymous) @ messagesService.js:135 (anonymous) @ messagesStore.js:1009 c @ runtime.js:63 (anonymous) @ runtime.js:294 (anonymous) @ runtime.js:119 ge @ messagesService.js:149 o @ messagesService.js:149 (anonymous) @ messagesService.js:149 (anonymous) @ messagesService.js:149 addReactionToMessage @ messagesStore.js:1001 (anonymous) @ vuex.esm.js:851 h.dispatch @ vuex.esm.js:516 dispatch @ vuex.esm.js:406 handleReactionClick @ MessageButtonsBar.vue:415 click @ MessageButtonsBar.vue?vue&type=template&id=664619c2&scoped=true&:1 qe @ vue.runtime.esm.js:1863 n @ vue.runtime.esm.js:2188 qe @ vue.runtime.esm.js:1863 n @ vue.runtime.esm.js:2184 Sa.r._wrapper @ vue.runtime.esm.js:6961 Show 4 more frames messagesStore.js:1024 Error: Request failed with status code 500 at e.exports (createError.js:16:15) at e.exports (settle.js:17:12) at XMLHttpRequest.C (xhr.js:66:7) (anonymous) @ messagesStore.js:1024 c @ runtime.js:63 (anonymous) @ runtime.js:294 (anonymous) @ runtime.js:119 ge @ messagesService.js:149 s @ messagesService.js:149 Promise.then (async) ge @ messagesService.js:149 o @ messagesService.js:149 (anonymous) @ messagesService.js:149 (anonymous) @ messagesService.js:149 addReactionToMessage @ messagesStore.js:1001 (anonymous) @ vuex.esm.js:851 h.dispatch @ vuex.esm.js:516 dispatch @ vuex.esm.js:406 handleReactionClick @ MessageButtonsBar.vue:415 click @ MessageButtonsBar.vue?vue&type=template&id=664619c2&scoped=true&:1 qe @ vue.runtime.esm.js:1863 n @ vue.runtime.esm.js:2188 qe @ vue.runtime.esm.js:1863 n @ vue.runtime.esm.js:2184 Sa.r._wrapper @ vue.runtime.esm.js:6961 ```

Server configuration

Operating system: Raspberry Pi OS 11

Web server: Apache/

Database: MySQL/Maria

PHP version: 8.0/

Nextcloud Version: 24

App List


Enabled:
  - accessibility: 1.10.0
  - activity: 2.16.0
  - bruteforcesettings: 2.4.0
  - calendar: 3.3.0
  - circles: 24.0.0
  - cloud_federation_api: 1.7.0
  - comments: 1.14.0
  - contacts: 4.1.0
  - contactsinteraction: 1.5.0
  - cookbook: 0.9.11
  - dashboard: 7.4.0
  - dav: 1.22.0
  - federatedfilesharing: 1.14.0
  - federation: 1.14.0
  - files: 1.19.0
  - files_external: 1.16.1
  - files_pdfviewer: 2.5.0
  - files_retention: 1.13.1
  - files_rightclick: 1.3.0
  - files_sharing: 1.16.2
  - files_trashbin: 1.14.0
  - files_versions: 1.17.0
  - files_videoplayer: 1.13.0
  - firstrunwizard: 2.13.0
  - logreader: 2.9.0
  - lookup_server_connector: 1.12.0
  - nextcloud_announcements: 1.13.0
  - notifications: 2.12.0
  - oauth2: 1.12.0
  - password_policy: 1.14.0
  - photos: 1.6.0
  - privacy: 1.8.0
  - provisioning_api: 1.14.0
  - quota_warning: 1.14.0
  - recommendations: 1.3.0
  - richdocuments: 6.0.0
  - richdocumentscode_arm64: 21.11.402
  - serverinfo: 1.14.0
  - settings: 1.6.0
  - sharebymail: 1.14.0
  - spreed: 14.0.0
  - support: 1.7.0
  - survey_client: 1.12.0
  - systemtags: 1.14.0
  - text: 3.5.1
  - theming: 1.15.0
  - twofactor_backupcodes: 1.13.0
  - twofactor_totp: 6.3.0
  - updatenotification: 1.14.0
  - user_status: 1.4.0
  - viewer: 1.8.0
  - weather_status: 1.4.0
  - workflowengine: 2.6.0
Disabled:
  - admin_audit
  - encryption
  - user_ldap

Nextcloud configuration:


{
    "system": {
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "mydomain.com",
            "192.168.0.xx"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "mysql",
        "version": "24.0.0.12",
        "overwrite.cli.url": "https:\/\/mydomain.com\/nextcloud",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "mysql.utf8mb4": true,
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "memcache.local": "\\OC\\Memcache\\Redis",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "filelocking.enabled": "true",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": 0,
            "timeout": 0
        },
        "maintenance": false,
        "app_install_overwrite": [
            "files_readmemd",
            "cookbook"
        ],
        "updater.secret": "***REMOVED SENSITIVE VALUE***",
        "theme": "",
        "loglevel": 2
    }
}

Server log (data/nextcloud.log)


{"reqId":"RT6RHcV3cJSvN2OpHlcT","level":2,"time":"2022-02-10T18:12:53+00:00","remoteAddr":"::1","user":"--","app":"no app in context","method":"GET","url":"/nextcloud/","message":"Host localhost was not connected to because it violates local access rules","userAgent":"Mozilla/5.0 (X11; CrOS aarch64 13597.84.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.78 Safari/537.36","version":""}
{"reqId":"RT6RHcV3cJSvN2OpHlcT","level":2,"time":"2022-02-10T18:12:53+00:00","remoteAddr":"::1","user":"--","app":"no app in context","method":"GET","url":"/nextcloud/","message":"Host localhost was not connected to because it violates local access rules","userAgent":"Mozilla/5.0 (X11; CrOS aarch64 13597.84.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.78 Safari/537.36","version":""}
{"reqId":"gh0Tk5xq4hP30isGCpdD","level":2,"time":"2022-02-10T18:15:55+00:00","remoteAddr":"::1","user":"--","app":"no app in context","method":"POST","url":"/nextcloud/index.php","message":"Host localhost was not connected to because it violates local access rules","userAgent":"Mozilla/5.0 (X11; CrOS aarch64 13597.84.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.78 Safari/537.36","version":""}
{"reqId":"gh0Tk5xq4hP30isGCpdD","level":2,"time":"2022-02-10T18:15:55+00:00","remoteAddr":"::1","user":"--","app":"no app in context","method":"POST","url":"/nextcloud/index.php","message":"Host localhost was not connected to because it violates local access rules","userAgent":"Mozilla/5.0 (X11; CrOS aarch64 13597.84.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.78 Safari/537.36","version":""}
{"reqId":"gh0Tk5xq4hP30isGCpdD","level":3,"time":"2022-02-10T18:15:55+00:00","remoteAddr":"::1","user":"--","app":"PHP","method":"POST","url":"/nextcloud/index.php","message":"mkdir(): Permission denied at /var/www/html/nextcloud/lib/private/Setup.php#308","userAgent":"Mozilla/5.0 (X11; CrOS aarch64 13597.84.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.78 Safari/537.36","version":"","exception":{"Exception":"Error","Message":"mkdir(): Permission denied at /var/www/html/nextcloud/lib/private/Setup.php#308","Code":0,"Trace":[{"function":"onError","class":"OC\\Log\\ErrorHandler","type":"::"},{"file":"/var/www/html/nextcloud/lib/private/Setup.php","line":308,"function":"mkdir"},{"file":"/var/www/html/nextcloud/core/Controller/SetupController.php","line":74,"function":"install","class":"OC\\Setup","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/nextcloud/lib/base.php","line":939,"function":"run","class":"OC\\Core\\Controller\\SetupController","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/nextcloud/index.php","line":36,"function":"handleRequest","class":"OC","type":"::"}],"File":"/var/www/html/nextcloud/lib/private/Log/ErrorHandler.php","Line":92,"CustomMessage":"--"}}
{"reqId":"eH2q0xq99XMM9BBIK7Eh","level":2,"time":"2022-02-10T18:17:09+00:00","remoteAddr":"::1","user":"--","app":"no app in context","method":"POST","url":"/nextcloud/index.php","message":"Host localhost was not connected to because it violates local access rules","userAgent":"Mozilla/5.0 (X11; CrOS aarch64 13597.84.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.78 Safari/537.36","version":""}
{"reqId":"eH2q0xq99XMM9BBIK7Eh","level":2,"time":"2022-02-10T18:17:09+00:00","remoteAddr":"::1","user":"--","app":"no app in context","method":"POST","url":"/nextcloud/index.php","message":"Host localhost was not connected to because it violates local access rules","userAgent":"Mozilla/5.0 (X11; CrOS aarch64 13597.84.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.78 Safari/537.36","version":""}
{"reqId":"lt4E3U5T9HGnHvQMlFOo","level":2,"time":"2022-02-10T18:17:42+00:00","remoteAddr":"::1","user":"--","app":"no app in context","method":"POST","url":"/nextcloud/index.php","message":"Host localhost was not connected to because it violates local access rules","userAgent":"Mozilla/5.0 (X11; CrOS aarch64 13597.84.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.78 Safari/537.36","version":""}
{"reqId":"lt4E3U5T9HGnHvQMlFOo","level":2,"time":"2022-02-10T18:17:42+00:00","remoteAddr":"::1","user":"--","app":"no app in context","method":"POST","url":"/nextcloud/index.php","message":"Host localhost was not connected to because it violates local access rules","userAgent":"Mozilla/5.0 (X11; CrOS aarch64 13597.84.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.78 Safari/537.36","version":""}

meldarionqeusse avatar May 06 '22 11:05 meldarionqeusse

In my case I notice this seems to happen when trying to react to something that a script posted. I can add reactions to general conversation so far, also to the matterbridge talk bot, but like poll messages or anything posted by a script fails.

Luticus avatar May 07 '22 22:05 Luticus

Commands might not work at the moment, that is right. The issue is that they could be restricted in visibility and then clients get notified about a reaction to a message they don't have. But this also means we should remove the option to react from such messages.

As for the initial report: Is it also a command for you? Otherwise can you say which reaction you tried? Does it happen for all or only some?

nickvergessen avatar May 09 '22 08:05 nickvergessen

I think this is solved now.

At least the option is not shown for commands anymore

nickvergessen avatar Sep 16 '22 13:09 nickvergessen

Still the same issue on Nextcloud 25

meldarionqeusse avatar Nov 18 '22 15:11 meldarionqeusse

Can you please check whether there is something in your nextcloud.log file then? We react daily hundred times on our company instance and it works totally fine

nickvergessen avatar Nov 18 '22 16:11 nickvergessen

Yes I did check the logs but I was seeing any recent entries Sorry I did not specify earlier

meldarionqeusse avatar Nov 18 '22 17:11 meldarionqeusse

In the browser log it says:

POST https://mydomain.com/nextcloud/ocs/v2.php/apps/spreed/api/v1/reaction/ok56zf6v/91 500 (Internal Server Error)

So there has to be an entry in nextcloud.log (or if that fails or is not writable or something check the error.log of apache)

nickvergessen avatar Nov 21 '22 09:11 nickvergessen

I got this in the browser log.

POST https://mydomain.com/nextcloud/ocs/v2.php/apps/spreed/api/v1/reaction/f2544j7d/114 400 (Bad request)

Do you have an idea what could be causing this? Thanks for taking time to try and help me resolve this issue.

meldarionqeusse avatar Nov 21 '22 10:11 meldarionqeusse