How are you initializing Netlify Dev locally? And how are you killing the Netlify Dev process? Netlify Dev should actually start up and run your SSG system within its own process and killing Netlify Dev should kill the SSG system as well.
I opened an issue on the CLI #2873 a while ago that might have some relevance here.
While the issue was that of an incorrectly typed command, the result was that Netlify CLI did not terminate correctly and the SSG (React in this case) remained running consuming port 3000. I was unaware for some time and receive the same “there’s something running on port 3000” message until I found the React instance and killed it.
You should not “kill terminal” without reason. It will abruptly end any processes and that’s what’s causing this I’d expect. You need to press Ctrl + C (All OS) for Netlify Dev to exit and that would shut down app server too.