eclipse-theia/theia

Preference change does not fire an onPreferencedChanged event

Open

#7,685 创建于 2020年4月28日

在 GitHub 查看
 (3 评论) (0 反应) (0 负责人)TypeScript (18,676 star) (2,478 fork)batch import
bughelp wantedpreferences

描述

Bug Description:

While working on the new preferences-ui we came across a bug related to the preference-service that has been causing some strange and unpredictable behavior on the Electron version (and also appears on master with the original preferences UI). When setting a preference value for some items, most noticeably Application Confirm Exit in User scope, the preference service does not properly register an onPreferenceChanged event, and thus does not update the value in the UI. This has sometimes occurred for other preference items in folder scopes as well, but is consistently an issue for Application Confirm Exit Please see the attached screen recording with console output:

Steps to Reproduce:

  1. Set up a log for the preferenceService.onPreferenceChanged event (in e.g. packages/preferences/src/browser/preferences-decorator.ts around line 36)
  2. Build for Electron
  3. Run in Electron
  4. Open Preferences in User scope
  5. Modify preferences using tree view and save the JSON
  6. Every modify + save cycle should fire an onPreferenceChanged event.
  7. Modify 'Application: Confirm Exit' and save
  8. Observe that no event fires

screenrecord

Additional Information

  • Operating System: Linux (RHEL7 & Ubuntu tested)
  • Theia Version: Electron 1.0.0

贡献者指南

Preference change does not fire an onPreferencedChanged event · eclipse-theia/theia#7685 | Good First Issue