Brewtarget / brewtarget

Main brewtarget source code repository.
GNU General Public License v3.0
313 stars 134 forks source link

Crash changing fermentation duration #785

Closed grahamrow closed 8 months ago

grahamrow commented 8 months ago

Hello! Enjoying running BrewTarget 3.0.10 on macOS 13.6.3 (22G436). When trying to change any of the fermentation times in the "Extras" tab of a recipe yields a crash with the following error after the SmartField contents are modified (via tab, enter, etc.):

[15:14:09.864] (1dvisj7kow) ERROR : ASSERT: "!std::holds_alternative<NonPhysicalQuantity>(*this->pimpl->m_typeInfo->fieldType)" in file ../src/widgets/SmartField.cpp, line 404 [widgets/SmartField.cpp:404]

This doesn't appear to happen with temperatures or other fields with units, only the times which appear to lack a unit specification. Happy to help debug further, and greatly appreciate your time and effort!

matty0ung commented 8 months ago

Glad you're enjoying the software. Thanks for the detailed report on the bug. I've just tried it on my local copy and get the same problem. I'll have a look at the relevant bit of the code...

dschwilk commented 8 months ago

That commit fixes this for me now on 3.0.11 build

matty0ung commented 8 months ago

Fix included in https://github.com/Brewtarget/brewtarget/releases/tag/v3.0.11.

grahamrow commented 7 months ago

Works great, thanks for the fix!