I have made buffer local changes to `process-environment' using the technique described in How can I get buffer-local environment variables via .dir-locals. I then call shell from that buffer. If I then view the environment variables in that shell using the following command, the buffer local changes are not included.
set | sort
I have used C-h v process-environment to confirm that the buffer local changes were made. However, if I added a variable in the buffer local process-environment it is not available in the shell.
For example, I set the environment variable P4ROOT in the buffer local process-environment. When I open a shell from that buffer, the P4ROOT environment variable is not set in the shell.