refine_for_global_qbx() assumes there isn't a stage 2 discretization already defined
This assumption may not hold, e.g. when calling refine_for_global_qbx() on an already refined geometry.
These lines are the problem.
This assumption may not hold, e.g. when calling refine_for_global_qbx() on an already refined geometry.
These lines are the problem.