Dashboard: registering a widget without backend panel breaks the remaining widgets
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 78/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- javascript
- 領域
- frontend
調査の方向性
apps/dashboard/src/DashboardApp.vueを読み、特に415~430行付近のrerenderPanels()を確認してください。issueでは、失敗するアクセスと到達不能なエラーログが指摘されています。この関数がパネルがない場合にどう処理するか、またウィジェットをどう反復処理するかを確認してください。不明なパネルがログに記録されてスキップされ、その後のウィジェットは引き続きマウントされるようになれば、変更は完了です。
索引モデルが issue の本文から書いたものです。
説明
Bug description
rerenderPanels() reads this.panels[app].id before checking whether the panel exists:
If an app calls OCA.Dashboard.register() for an id that has no backend panel (e.g. the widget's app is disabled for the user, or the ids don't match), this throws a TypeError, which aborts the loop – so all widgets after it in the iteration are not mounted either. The intended logger.error branch for unknown panels further down is unreachable.
Steps to reproduce
Found by code reading.
- Register a dashboard widget callback via
OCA.Dashboard.register('unknown-id', …). - Other widgets registered later are not rendered, and a TypeError is logged in the console.
Expected behavior
Unknown panels are skipped (with the existing error log) without affecting other widgets.
Nextcloud version
master
- 主要言語
- PHP
- スター
- 37.7k
- フォーク
- 5.4k
- 平均マージ
- 1日 23時間
- マージ済み PR(30日)
- 585
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
nextcloud/server のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
1. to develop bug feature: tags good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
1. to develop bug feature: federation
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
1. to develop bug feature: files feature: previews and thumbnails
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
1. to develop bug feature: sharing
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
nextcloud/server の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 92/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 91/100
nhrrob/nhrrob-secure#35 ·
-
area/tests type/bug when/soon
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
メンテナーはふだん 1 日以内に返信