zynthian / zynthian-issue-tracking

Centralized Issue Tracking for Zynthian Project
https://github.com/orgs/zynthian/projects/1
11 stars 3 forks source link

Failure to load snapshot #1089

Closed riban-bw closed 4 months ago

riban-bw commented 5 months ago

Describe the issue

Attempt to load a snapshot fails with error.

To Reproduce

Steps to reproduce the behavior:

  1. Load the attached snapshot.

    Expected behaviour

    Snapshot loads.

    Actual behaviour

    Error and Zynthian becomes unresponsive.

    Additional context

    Snapshot provided by @gitnob. Error logged:

    Jun 14 18:23:06 zynthian-v5-64 startx[3972]: ERROR:zynthian_chain_manager.add_processor: Engine 'JV/Perfomix' not found!
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]: ERROR:zynthian_state_manager.load_snapshot: Invalid snapshot: list index out of range
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]: Traceback (most recent call last):
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:   File "/zynthian/zynthian-ui/zyngine/zynthian_state_manager.py", line 1009, in load_snapshot
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:     self.chain_manager.set_state(state['chains'], engine_config)
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:   File "/zynthian/zynthian-ui/zyngine/zynthian_chain_manager.py", line 1099, in set_state
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:     self.add_processor(chain_id, eng_code, mode, proc_id=int(proc_id), fast_refresh=False, eng_config=eng_config)
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:   File "/zynthian/zynthian-ui/zyngine/zynthian_chain_manager.py", line 789, in add_processor
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:     src_chain.rebuild_graph()
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:   File "/zynthian/zynthian-ui/zyngine/zynthian_chain.py", line 412, in rebuild_graph
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:     self.rebuild_audio_graph()
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:   File "/zynthian/zynthian-ui/zyngine/zynthian_chain.py", line 325, in rebuild_audio_graph
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:     for source in self.audio_slots[self.fader_pos - 1]:
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]:                   ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^
    Jun 14 18:23:07 zynthian-v5-64 startx[3972]: IndexError: list index out of range

Configuration

013-bypass.main.chain.prefader.fx.zss.zip

Hardware

Raspberry Pi 4 Model B Rev 1.5
Audio: V5 ADAC
Display: MIPI DSI 800x480 (inverted)
Wiring: V5
I2C: MCP23017@0x20, MCP23017@0x21
Profile: v5

System

Debian GNU/Linux 12 (bookworm)
Build Date: 2024-02-01
Memory: 18% (705M/3792M)
SD Card: 90% (25G/29G)
Temperature: 48.7ºC
Overclock: Maximum

MIDI & UI

Tuning: 440 Hz
Master Channel: 16
Preload Presets: Off
ZS3 (SubSnapShots): On
Power Save: 10 minutes
Audio Levels on Snapshots: On

Software

zyncoder: oram (e0014fe) 
zynthian-ui: oram (453726c)
zynthian-sys: oram (8602194)
zynthian-data: (HEAD detached from db0355a) (9958411)
zynthian-webconf: oram (2dba270)
gitnob commented 5 months ago

Oh shame, this snapshot contains my custom Perfomix plugin, which I am developing right now. So zynthian can't find this in the lv2 plugin repositories. This plugin is a pd patch which is compiled to an lv2 plugin. I'll send you a new snapshot tomorrow to show you the bug mentioned in https://github.com/zynthian/zynthian-issue-tracking/issues/1082 , which is related to the audio signal flow for pre-fader plugins in the main mixbus chain.

riban-bw commented 4 months ago

Okay - so the issue may relate to failing to find a plugin that is in the snapshot but not installed on Zynthian. We must catch such exceptions and handle them gracefully.

riban-bw commented 4 months ago

I can not reproduce this error. There is likely to be something to fix but without a broken workflow it is not easy to trace so I am closing this ticket. Maybe the fixes for the routing issue also resolved the trigger for this bug.