Same issue as other threads that have been reported and fixed. Using the 0x1000 block layout of gen3 saves, I rearranged the order of blocks since it seems like the save writing was interrupted when overwriting the flash chip, so that each save (primary and main) has a complete set of save blocks, and re-exported from PKHeX.
POKEMONE.SAV