I think I'd prefer to do as little as possible here so I'd just respect whatever `iScansNegatively` currently is and do:

    new_nx = max(gribapi.grib_get_long_array(grib_message, "pl"))
    new_x_step = (max(lons) - min(lons)) / (new_nx - 1)
    if gribapi.grib_get_long(grib_message, 'iScansNegatively'):
        new_x_step *= -1
    ...
    new_lons = np.arange(new_nx) * new_x_step + lons[0]

I think that should work. I would have thought `iScansNegatively` and `jScansPositively` should be defined for quasi-regular grids just like they are for regular grids so they shouldn't need to be set by us, perhaps you know different? I'm no expert on GRIB, just picking things up as I go along.

Also I think that using an if statement is clearer because for the i-direction the flag is `iScansNegatively` and for the j-direction it is `jScansPositively` which is confusing enough, so I'd prefer this to defining a sign variable I think.