# Bug report

### Bug description:

```os.environ``` doesn't reflect environment changes that are made outside of Python.

For example, this code adds the environment XXX but os.environ doesn't see this change.

This program:
```python
import os

import ctypes
import ctypes.util

clib = ctypes.util.find_library("c")
dll = ctypes.CDLL(clib)

setenv = dll.setenv
setenv.argtypes = [ctypes.POINTER(ctypes.c_char), ctypes.POINTER(ctypes.c_char), ctypes.c_int]

getenv = dll.getenv
getenv.argtypes = [ctypes.POINTER(ctypes.c_char)]
getenv.restype=ctypes.c_char_p

# set XXX outside of Python's os.environ
setenv(b"XXX", b"Hello", 2)

print(f'real XXX value: {str(getenv(b"XXX"))}')
print(f'XXX is in os.getenv: {os.getenv("XXX")}')
print(f'XXX is in os.environ: {"YES" if "XXX" in os.environ else "NO"}')
```

prints:
```
real XXX value: b'Hello'
XXX is in os.getenv: None
XXX is in os.environ: NO
```

There should be a method, for example ```os.environ_refresh```, that would re-read environment into os.environ.

I've hit this on the real-world case when Python didn't see environment set by TCL script executed in the same process.


### CPython versions tested on:

3.9

### Operating systems tested on:

Other
[feature request] Method to refresh os.environ
This is a GitHub Issue
repo:cpython
owner:python
Title : [feature request] Method to refresh os.environ
Issue date:

--- start body ---
# Bug report

### Bug description:

```os.environ``` doesn't reflect environment changes that are made outside of Python.

For example, this code adds the environment XXX but os.environ doesn't see this change.

This program:
```python
import os

import ctypes
import ctypes.util

clib = ctypes.util.find_library("c")
dll = ctypes.CDLL(clib)

setenv = dll.setenv
setenv.argtypes = [ctypes.POINTER(ctypes.c_char), ctypes.POINTER(ctypes.c_char), ctypes.c_int]

getenv = dll.getenv
getenv.argtypes = [ctypes.POINTER(ctypes.c_char)]
getenv.restype=ctypes.c_char_p

# set XXX outside of Python's os.environ
setenv(b"XXX", b"Hello", 2)

print(f'real XXX value: {str(getenv(b"XXX"))}')
print(f'XXX is in os.getenv: {os.getenv("XXX")}')
print(f'XXX is in os.environ: {"YES" if "XXX" in os.environ else "NO"}')
```

prints:
```
real XXX value: b'Hello'
XXX is in os.getenv: None
XXX is in os.environ: NO
```

There should be a method, for example ```os.environ_refresh```, that would re-read environment into os.environ.

I've hit this on the real-world case when Python didn't see environment set by TCL script executed in the same process.


### CPython versions tested on:

3.9

### Operating systems tested on:

Other
--- end body ---

None