when I call the setState in a subsequent useEffect call I get this. Seems to work, but the next call is not valid.