KBNLresearch / iromlab

Loader software for automated imaging of optical media with Nimbie disc robot
Apache License 2.0
33 stars 5 forks source link

Update carrierNumber after input validation #116

Closed bitsgalore closed 2 months ago

bitsgalore commented 3 months ago

Currently the variable "carrierNumber" (which corresponds to the queue number shown in the treeview widget) is updated right at the start of the "on_submit" function:

https://github.com/KBNLresearch/iromlab/blob/master/iromlab/iromlab.pyw#L298

If the submitted data (e.g. PPN, volume number) failed validation or the user re-entered the title, the function is invoked again, and as a result the displayed queue numbers are not consecutive. This doesn't affect any of the processing, but users may find this confusing.

To avoid this, update "carrierNumber" after the job file has been written, i.e. here:

https://github.com/KBNLresearch/iromlab/blob/06ee35c68cf66c8bf711c010a2a8801e4f3d398c/iromlab/iromlab.pyw#L389

bitsgalore commented 2 months ago

Done: https://github.com/KBNLresearch/iromlab/commit/33642c4e6f3069a4472ce06ccc8a2909d48b518b