TCPStore() RuntimeError: unmatched '}' in format string
Labels: oncall: distributed

### 🐛 Describe the bug

When I was running: python train.py --exp-dir=./logs --exp-name=first_test --modality=video --mode=offline --root-dir=./lrs3_trained --sp-model-path=./spm_unigram_1023.model
It got some errors.
```
Traceback (most recent call last):
  File "train.py", line 147, in <module>
    cli_main()
  File "train.py", line 141, in cli_main
    trainer.fit(model, data_module)
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\pytorch_lightning\trainer\trainer.py", line 582, in fit
    call._call_and_handle_interrupt(
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\pytorch_lightning\trainer\call.py", line 36, in _call_and_handle_interrupt      
    return trainer.strategy.launcher.launch(trainer_fn, *args, trainer=trainer, **kwargs)
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\pytorch_lightning\strategies\launchers\subprocess_script.py", line 90, in launch
    return function(*args, **kwargs)
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\pytorch_lightning\trainer\trainer.py", line 624, in _fit_impl
    self._run(model, ckpt_path=self.ckpt_path)
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\pytorch_lightning\trainer\trainer.py", line 997, in _run
    self.strategy.setup_environment()
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\pytorch_lightning\strategies\ddp.py", line 153, in setup_environment
    self.setup_distributed()
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\pytorch_lightning\strategies\ddp.py", line 204, in setup_distributed
    _init_dist_connection(self.cluster_environment, self._process_group_backend, timeout=self._timeout)
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\lightning_lite\utilities\distributed.py", line 237, in _init_dist_connection    
    torch.distributed.init_process_group(torch_distributed_backend, rank=global_rank, world_size=world_size, **kwargs)
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\torch\distributed\c10d_logger.py", line 82, in wrapper
    func_return = func(*args, **kwargs)
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\torch\distributed\distributed_c10d.py", line 1142, in init_process_group        
    store, rank, world_size = next(rendezvous_iterator)
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\torch\distributed\rendezvous.py", line 241, in _env_rendezvous_handler
    store = _create_c10d_store(master_addr, master_port, rank, world_size, timeout)
  File "C:\ProjectForCoding\tftorchvenv\lib\site-packages\torch\distributed\rendezvous.py", line 172, in _create_c10d_store
    return TCPStore(
RuntimeError: unmatched '}' in format string
```

### Versions

PyTorch version: 2.1.0.dev20230718+cu121
Is debug build: False
CUDA used to build PyTorch: 12.1

OS: Microsoft Windows 11 pro
GCC version: (MinGW.org GCC-6.3.0-1) 6.3.0
CMake version: version 3.27.5

Python version: 3.8.10
Is CUDA available: True
GPU models and configuration: GPU 0: NVIDIA GeForce RTX 4090
cuDNN version: 8.1.0

Versions of relevant libraries:
[pip3] numpy==1.24.4
[pip3] pytorch-lightning==2.0.9
[pip3] torch==2.1.0.dev20230718+cu121
[pip3] torchaudio==2.1.0.dev20230719+cu121
[pip3] torchelastic==0.2.2
[pip3] torchmetrics==0.7.0
[pip3] torchvision==0.16.0.dev20230718+cu121

cc @mrshenli @pritamdamania87 @zhaojuanmao @satgera @rohan-varma @gqchen @aazzolini @osalpekar @jiayisuse @H-Huang @kwen2501 @awgu @penguinwu