Putting aside the stupidity of the legislation for one moment, it at least is logically consistent, in that it prevents California from exporting its fossil fuel based production to other states. In other words, they can't preen themselves over their "green" credentials while exporting pollution to neighbouring states.
It seems to me that once power plants are part of the grid, all the electricity in the grid becomes fungible.
In other words: Which kilowatt is from which plant?