Make usr_mug backward compatible with mfix-25.3

Hi,

usr_mug = .T. is supposed to be backward compatible (check_data/check_gas_phase.f) but the GUI is unhappy and cannot load a *.dat or *.mfx file when it is present. It is OK to select instead MU_G_MODEL = .T. instead and that works. Just a wee note.

fluid_bed_tfm_2d_mu_g_test.mfx (7.5 KB)

E.

Thanks Eric. That’s what we call an “oops” :slight_smile:

diff --git a/mfixgui/project_manager.py b/mfixgui/project_manager.py
index db5925e3e..69dcdc914 100644
--- a/mfixgui/project_manager.py
+++ b/mfixgui/project_manager.py
@@ -740,7 +740,7 @@ class ProjectManager(Project):
             # Set mu_g_model
             if not self.get_value('mu_g_model'):
                 if self.get_value('usr_mug'):
-                    self.unset_keyword('usr_mug')
+                    self.gui.unset_keyword('usr_mug')
                     self.gui.update_keyword('mu_g_model', 'USR')
                 elif self.get_value('mu_g0') is not None:
                     self.gui.update_keyword('mu_g_model', 'CONSTANT')

Line 743 in project_manager.py is incorrect. Instead of self.unset_keyword it should be self.gui.unset_keyword. You can fix this in-place by editing $CONDA_PREFIX/lib/python3.13/site-packages/mfixgui/project_manager.py

This will be fixed for the next release (26.1). Thanks as always for the report.

– Charles

1 Like