Summary
On macOS, Plover 5.3.0 can initialize the Dictionaries Qt UI with the default English dictionaries even though the actual engine config/system has already switched to a plugin-defined system (Korean Modern C) with plugin-provided dictionaries.
In some runs this also triggers a Qt-side exception in dictionaries_widget:
ValueError: not enough values to unpack (expected 1, got 0)
This looks less like a Korean-only bug and more like a startup/config synchronization bug in the Qt dictionaries UI when using a non-default system with plugin-defined dictionaries.
Environment
- Plover 5.3.0 macOS app bundle
- macOS
- System:
Korean Modern C
- Dictionaries: two plugin-provided Python dictionaries
plover_korean/system/cas/dictionaries/ko_cas_numbers.py
plover_korean/system/cas/dictionaries/ko_cas_base.py
Expected behavior
After restart, the Dictionaries UI should show the dictionaries from the saved config for the active system.
Actual behavior
Observed behavior before local workaround:
- Engine startup logs showed
loading system: Korean Modern C
- Engine loaded only the two Korean dictionaries
- But the Qt dictionaries UI could still initialize from the default English dictionary set (
user.json, commands.json, main.json)
- In some runs,
dictionaries_widget then crashed with ValueError: not enough values to unpack (expected 1, got 0) while processing dictionary state changes
So the engine state and the dictionaries UI model could become temporarily inconsistent during startup.
Relevant log excerpts
From engine startup:
loading system: Korean Modern C
loading dictionary: .../ko_cas_numbers.py
loading dictionary: .../ko_cas_base.py
loaded 2 dictionaries
From a failing UI run:
ValueError: not enough values to unpack (expected 1, got 0)
The local investigation strongly suggested that the dictionaries model had initialized with the English defaults first, then later received state/config updates for the Korean dictionaries.
Suspected cause
It appears the Qt Dictionaries UI/model may be built before the loaded config has been fully applied, so it initially reflects the default English Stenotype dictionaries instead of the saved active system dictionaries.
That stale model then receives later config_changed / dictionaries_loaded / dictionary-state events for a different set of dictionaries, which can lead to the mismatch and the ValueError.
In other words, this seems like an initialization-order / synchronization bug between:
- config loading
- active system selection
- dictionaries model population in the Qt UI
- later dictionary state updates
Notes
I was able to work around this locally by monkey-patching startup so that:
- config defaults were forced to the saved plugin system before the dictionaries widget initialized
- the dictionaries UI model was resynchronized from engine config/runtime dictionaries on startup and later updates
That workaround makes me think the underlying issue is in Plover Qt startup ordering rather than in the Korean plugin alone.
Summary
On macOS, Plover 5.3.0 can initialize the
DictionariesQt UI with the default English dictionaries even though the actual engine config/system has already switched to a plugin-defined system (Korean Modern C) with plugin-provided dictionaries.In some runs this also triggers a Qt-side exception in
dictionaries_widget:This looks less like a Korean-only bug and more like a startup/config synchronization bug in the Qt dictionaries UI when using a non-default system with plugin-defined dictionaries.
Environment
Korean Modern Cplover_korean/system/cas/dictionaries/ko_cas_numbers.pyplover_korean/system/cas/dictionaries/ko_cas_base.pyExpected behavior
After restart, the
DictionariesUI should show the dictionaries from the saved config for the active system.Actual behavior
Observed behavior before local workaround:
loading system: Korean Modern Cuser.json,commands.json,main.json)dictionaries_widgetthen crashed withValueError: not enough values to unpack (expected 1, got 0)while processing dictionary state changesSo the engine state and the dictionaries UI model could become temporarily inconsistent during startup.
Relevant log excerpts
From engine startup:
From a failing UI run:
The local investigation strongly suggested that the dictionaries model had initialized with the English defaults first, then later received state/config updates for the Korean dictionaries.
Suspected cause
It appears the Qt
DictionariesUI/model may be built before the loaded config has been fully applied, so it initially reflects the defaultEnglish Stenotypedictionaries instead of the saved active system dictionaries.That stale model then receives later
config_changed/dictionaries_loaded/ dictionary-state events for a different set of dictionaries, which can lead to the mismatch and theValueError.In other words, this seems like an initialization-order / synchronization bug between:
Notes
I was able to work around this locally by monkey-patching startup so that:
That workaround makes me think the underlying issue is in Plover Qt startup ordering rather than in the Korean plugin alone.