I got a simple script on my server
import os
import pprint
pprint.pprint(dict(os.environ))
When I connect to my server and run it manually,I got different results with when I run it throw Ctrl+Shift+F10 in Pycharm
that's caused some other code not work well, so I wanna know how to make the latter the same with the former

os.environthe values shown are system dependent. So if you run on your own computer it will show the "environment values" of your own computer, but if you runos.environremotely on a different computer it will show the values of that remote computer. Ideally, you'd want the program to either be independent of the environment, or have a test where it adapts to the environment. (Think that if another users runs your code on their computer, it will also be different.)Ctrl+Shift+F10you are executing a Run configuration of Pycharm that you've previously configured see how to create a Run configuration manually. I would advise keeping 2 different run configurations for simplicity, you can make a dynamic run configuration to adapt to the environment using a macro but it involves some learning.