[Bug] This breaks Talk flow #430

Open
opened 2025-05-03 18:47:40 +02:00 by tty-13 · 9 comments

Environment

  • Custom menu version: 5.1.0
  • Nextcloud version: 32.0.4
  • PHP version: 8.2
  • Web server ): Apache 2.4.62
  • Web browser and version (Firefox 80, Google Chrome 74, etc): any (Tried firefox and chromium)

Configuration

{
  "add-logo-link": true,
  "always-displayed": false,
  "apps-categories-custom": {
    "spreed": "cat7464021878247947",
    "external_index2": "cat7464021878247947",
    "contacts": "cat7464021878247947",
    "calendar": "cat8651135521261637",
    "external_index4": "cat8651135521261637",
    "external_index5": "cat8651135521261637",
    "files": "cat6011755786056361",
    "sharereview": "security",
    "external_index1": "cat8987155921181871",
    "ocs_api_viewer": null,
    "forms": null
  },
  "apps-order": [
    "app_api_flow_flow",
    "files",
    "activity",
    "spreed",
    "external_index2",
    "mail_roundcube",
    "contacts",
    "calendar",
    "external_index4",
    "deck",
    "sharereview",
    "external_index1",
    "collectives",
    "forms",
    "external_index5",
    "ocs_api_viewer"
  ],
  "background-color": "#FFBF00",
  "background-color-opacity": 100,
  "background-color-to": "#FFC200",
  "big-menu": false,
  "big-menu-hidden-apps": [
    "0",
    "activity",
    "deck",
    "mail_roundcube",
    "collectives"
  ],
  "categories-custom": [
    {
      "id": "cat6011755786056361",
      "en": "Share",
      "fr": "Partage"
    },
    {
      "id": "cat8651135521261637",
      "en": "Organisation",
      "fr": "Orga"
    },
    {
      "id": "cat7464021878247947",
      "en": "Communication",
      "fr": "Communication"
    },
    {
      "id": "cat8987155921181871",
      "en": "┈┈┈┈┈┈┈┈┈┈┈┈",
      "fr": "┈┈┈┈┈┈┈┈┈┈┈┈"
    }
  ],
  "categories-order": [
    "cat7464021878247947",
    "cat8651135521261637",
    "cat6011755786056361",
    "security",
    "cat8987155921181871",
    "organization"
  ],
  "categories-order-type": "custom",
  "current-app-background-color": "#cc9a02",
  "dark-mode-background-color": "#FFC700",
  "dark-mode-background-color-opacity": 100,
  "dark-mode-background-color-to": "#FFC100",
  "dark-mode-current-app-background-color": "#b38702",
  "dark-mode-icon-invert-filter": 0,
  "dark-mode-icon-opacity": 100,
  "dark-mode-loader-color": "#ffcd35",
  "dark-mode-opener": "side-menu-opener-hamburger",
  "dark-mode-text-color": "#000000",
  "default-enabled": true,
  "display-logo": true,
  "external-sites-in-top-menu": false,
  "force": true,
  "force-light-icon": false,
  "icon-invert-filter": 0,
  "icon-opacity": 100,
  "loader-color": "#ffcd35",
  "loader-enabled": true,
  "opener": "side-menu-opener-hamburger",
  "opener-hover": false,
  "opener-only": false,
  "opener-position": "before",
  "show-settings": true,
  "side-with-categories": true,
  "size-icon": "big",
  "size-text": "big",
  "target-blank-apps": [
    "0"
  ],
  "text-color": "#000000",
  "top-menu-apps": [],
  "top-menu-mouse-over-hidden-label": 0,
  "top-side-menu-apps": [],
  "use-avatar": false
}

Steps to reproduce

  • Install side_menu
  • Does not need to be enabled in user preferences, only installed and enabled on the server.
  • Go to user-defined flow.
  • Try to add a new "Write to conversation" flow

Observed Results

When side_menu is installed, the fields and drop-downs in the "Write to conversation" talk flow are absent.

Expected Results

"Write to conversation" flow should work as expected, this app should not interfere with it.

More informations

No response

### Environment * Custom menu version: 5.1.0 * Nextcloud version: 32.0.4 * PHP version: 8.2 * Web server ): Apache 2.4.62 * Web browser and version (Firefox 80, Google Chrome 74, etc): any (Tried firefox and chromium) ### Configuration ``` { "add-logo-link": true, "always-displayed": false, "apps-categories-custom": { "spreed": "cat7464021878247947", "external_index2": "cat7464021878247947", "contacts": "cat7464021878247947", "calendar": "cat8651135521261637", "external_index4": "cat8651135521261637", "external_index5": "cat8651135521261637", "files": "cat6011755786056361", "sharereview": "security", "external_index1": "cat8987155921181871", "ocs_api_viewer": null, "forms": null }, "apps-order": [ "app_api_flow_flow", "files", "activity", "spreed", "external_index2", "mail_roundcube", "contacts", "calendar", "external_index4", "deck", "sharereview", "external_index1", "collectives", "forms", "external_index5", "ocs_api_viewer" ], "background-color": "#FFBF00", "background-color-opacity": 100, "background-color-to": "#FFC200", "big-menu": false, "big-menu-hidden-apps": [ "0", "activity", "deck", "mail_roundcube", "collectives" ], "categories-custom": [ { "id": "cat6011755786056361", "en": "Share", "fr": "Partage" }, { "id": "cat8651135521261637", "en": "Organisation", "fr": "Orga" }, { "id": "cat7464021878247947", "en": "Communication", "fr": "Communication" }, { "id": "cat8987155921181871", "en": "┈┈┈┈┈┈┈┈┈┈┈┈", "fr": "┈┈┈┈┈┈┈┈┈┈┈┈" } ], "categories-order": [ "cat7464021878247947", "cat8651135521261637", "cat6011755786056361", "security", "cat8987155921181871", "organization" ], "categories-order-type": "custom", "current-app-background-color": "#cc9a02", "dark-mode-background-color": "#FFC700", "dark-mode-background-color-opacity": 100, "dark-mode-background-color-to": "#FFC100", "dark-mode-current-app-background-color": "#b38702", "dark-mode-icon-invert-filter": 0, "dark-mode-icon-opacity": 100, "dark-mode-loader-color": "#ffcd35", "dark-mode-opener": "side-menu-opener-hamburger", "dark-mode-text-color": "#000000", "default-enabled": true, "display-logo": true, "external-sites-in-top-menu": false, "force": true, "force-light-icon": false, "icon-invert-filter": 0, "icon-opacity": 100, "loader-color": "#ffcd35", "loader-enabled": true, "opener": "side-menu-opener-hamburger", "opener-hover": false, "opener-only": false, "opener-position": "before", "show-settings": true, "side-with-categories": true, "size-icon": "big", "size-text": "big", "target-blank-apps": [ "0" ], "text-color": "#000000", "top-menu-apps": [], "top-menu-mouse-over-hidden-label": 0, "top-side-menu-apps": [], "use-avatar": false } ``` ### Steps to reproduce - Install side_menu - Does not need to be enabled in user preferences, only installed and enabled on the server. - Go to user-defined flow. - Try to add a new "Write to conversation" flow ### Observed Results When side_menu is installed, the fields and drop-downs in the "Write to conversation" talk flow are absent. ### Expected Results "Write to conversation" flow should work as expected, this app should not interfere with it. ### More informations _No response_
Owner

Hello!

I can't reproduce or I don't understand your issue. These screenshots are taken with admin access and user access.

Hello! I can't reproduce or I don't understand your issue. These screenshots are taken with admin access and user access.
Author

Hello :)

You did reproduce it. I wasn't very clear on which dropdowns were missing, sorry.
There should be a drop down menu in this screen, allowing you to choose a conversation.
Disabling this app solves the problem. Seems to have something to do with vue

image

Hello :) You did reproduce it. I wasn't very clear on which dropdowns were missing, sorry. There should be a drop down menu in this screen, allowing you to choose a conversation. Disabling this app solves the problem. Seems to have something to do with vue ![image](/attachments/989a386a-56be-47d8-819c-25de5a82a25d)
Author

Part of the log from developper tools on a browser might help :

side_menu-menu.js?v=5f60a36b-28:2 [ERROR] @nextcloud/vue: The `@nextcloud/vue` library was used without setting / replacing the `appName`. {uid: 'REDACTED', app: '@nextcloud/vue', level: 2}
log @ side_menu-menu.js?v=5f60a36b-28:2
error @ side_menu-menu.js?v=5f60a36b-28:2
(anonymous) @ side_menu-menu.js?v=5f60a36b-28:2
(anonymous) @ side_menu-menu.js?v=5f60a36b-28:2
(anonymous) @ side_menu-menu.js?v=5f60a36b-28:2
flow.js:20 Uncaught TypeError: Cannot read properties of undefined (reading 'registerOperator')
    at flow.js:20:27
    at talk-flow.js?v=5f60a36b-28:5421:5259
    at talk-flow.js?v=5f60a36b-28:5421:5263
    at talk-flow.js?v=5f60a36b-28:5421:5268

I did try to investigate further but I really am not that experienced, sorry.

Part of the log from developper tools on a browser might help : ``` side_menu-menu.js?v=5f60a36b-28:2 [ERROR] @nextcloud/vue: The `@nextcloud/vue` library was used without setting / replacing the `appName`. {uid: 'REDACTED', app: '@nextcloud/vue', level: 2} log @ side_menu-menu.js?v=5f60a36b-28:2 error @ side_menu-menu.js?v=5f60a36b-28:2 (anonymous) @ side_menu-menu.js?v=5f60a36b-28:2 (anonymous) @ side_menu-menu.js?v=5f60a36b-28:2 (anonymous) @ side_menu-menu.js?v=5f60a36b-28:2 flow.js:20 Uncaught TypeError: Cannot read properties of undefined (reading 'registerOperator') at flow.js:20:27 at talk-flow.js?v=5f60a36b-28:5421:5259 at talk-flow.js?v=5f60a36b-28:5421:5263 at talk-flow.js?v=5f60a36b-28:5421:5268 ``` I did try to investigate further but I really am not that experienced, sorry.
tty-13 changed title from [Bug] This breaks to [Bug] This breaks Talk flow 2025-05-03 20:15:03 +02:00
Owner

The error with appName is fixed (not released yet) but it's not the problem.

The error with `appName` is fixed (not released yet) but it's not the problem.
Owner

![](https://upload.deblan.org/u/2025-05/681797e3.png)
Owner

Flow uses the deprecated Vue 2.

/**
 * SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors
 * SPDX-License-Identifier: AGPL-3.0-or-later
 */

import wrap from '@vue/web-component-wrapper'
import Vue from 'vue'

import FlowPostToConversation from './views/FlowPostToConversation.vue'

const FlowPostToConversationComponent = wrap(Vue, FlowPostToConversation)
const customElementId = 'oca-spreed-flow_post_to_conversation'
window.customElements.define(customElementId, FlowPostToConversationComponent)

// In Vue 2, wrap doesn't support disabling shadow :(
// Disable with a hack
Object.defineProperty(FlowPostToConversationComponent.prototype, 'attachShadow', { value() { return this } })
Object.defineProperty(FlowPostToConversationComponent.prototype, 'shadowRoot', { get() { return this } })

window.OCA.WorkflowEngine.registerOperator({ <--------------------------------------- here the problem
	id: 'OCA\\Talk\\Flow\\Operation',
	color: '#0082c9',
	operation: '',
	element: customElementId,
	options: FlowPostToConversation // backward "compatibility"
})

Flow uses the deprecated Vue 2. ```js /** * SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors * SPDX-License-Identifier: AGPL-3.0-or-later */ import wrap from '@vue/web-component-wrapper' import Vue from 'vue' import FlowPostToConversation from './views/FlowPostToConversation.vue' const FlowPostToConversationComponent = wrap(Vue, FlowPostToConversation) const customElementId = 'oca-spreed-flow_post_to_conversation' window.customElements.define(customElementId, FlowPostToConversationComponent) // In Vue 2, wrap doesn't support disabling shadow :( // Disable with a hack Object.defineProperty(FlowPostToConversationComponent.prototype, 'attachShadow', { value() { return this } }) Object.defineProperty(FlowPostToConversationComponent.prototype, 'shadowRoot', { get() { return this } }) window.OCA.WorkflowEngine.registerOperator({ <--------------------------------------- here the problem id: 'OCA\\Talk\\Flow\\Operation', color: '#0082c9', operation: '', element: customElementId, options: FlowPostToConversation // backward "compatibility" }) ```
Owner
https://github.com/nextcloud/server/blob/f06835099833f3dd3b47f3820039f445cfb5d4b1/apps/workflowengine/src/workflowengine.js#L64
Owner

Disabling custom menu from the user side does not load the app at all but the bug is still here. Disabling custom menu from the admin and flow works.

Disabling custom menu from the user side does not load the app at all but the bug is still here. Disabling custom menu from the admin and flow works.
Owner

I don't have a solution yet.

I don't have a solution yet.
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
deblan/side_menu#430
No description provided.