


'''simple docstring'''







import socket






def 			lowercase				():







       """simple docstring"""







       _lowerCAmelCase    :							Tuple   			=       socket.socket(socket.AF_INET   ,						socket.SOCK_STREAM					)
       _lowerCAmelCase    :							Optional[int]   			=       socket.gethostname()
       _lowerCAmelCase    :							Any   			=       1_2_3_1_2

       sock.connect((host, port)					)
       sock.send(B'Hello server!'					)

       with open('Received_file'   ,						'wb'					) as out_file:
              print('File opened'					)
              print('Receiving data...'					)
              while True:
                     _lowerCAmelCase    :							Union[str, Any]   			=       sock.recv(1_0_2_4					)
                     if not data:
                            break
                     out_file.write(_A					)

       print('Successfully received the file'					)
       sock.close()
       print('Connection closed'					)


if __name__ == "__main__":
       main()





'''simple docstring'''







import pytest

import datasets


# Import fixture modules as plugins
lowerCAmelCase    :     List[str]					=						["""tests.fixtures.files""", """tests.fixtures.hub""", """tests.fixtures.fsspec"""]






def 			lowercase				(_A   ,						_A					):







       """simple docstring"""







       for item in items:
              if any(marker in item.keywords for marker in ['integration', 'unit']					):
                     continue
              item.add_marker(pytest.mark.unit					)






def 			lowercase				(_A					):







       """simple docstring"""







       config.addinivalue_line('markers'   ,						'torchaudio_latest: mark test to run with torchaudio>=0.12'					)






@pytest.fixture(autouse=_A					)
def 			lowercase				(_A   ,						_A					):







       """simple docstring"""







       _lowerCAmelCase    :							str   			=       tmp_path_factory.getbasetemp() / 'cache'
       _lowerCAmelCase    :							Dict   			=       test_hf_cache_home / 'datasets'
       _lowerCAmelCase    :							List[Any]   			=       test_hf_cache_home / 'metrics'
       _lowerCAmelCase    :							List[Any]   			=       test_hf_cache_home / 'modules'
       monkeypatch.setattr('datasets.config.HF_DATASETS_CACHE'   ,						str(_A					)					)
       monkeypatch.setattr('datasets.config.HF_METRICS_CACHE'   ,						str(_A					)					)
       monkeypatch.setattr('datasets.config.HF_MODULES_CACHE'   ,						str(_A					)					)
       _lowerCAmelCase    :							Dict   			=       test_hf_datasets_cache / 'downloads'
       monkeypatch.setattr('datasets.config.DOWNLOADED_DATASETS_PATH'   ,						str(_A					)					)
       _lowerCAmelCase    :							Union[str, Any]   			=       test_hf_datasets_cache / 'downloads' / 'extracted'
       monkeypatch.setattr('datasets.config.EXTRACTED_DATASETS_PATH'   ,						str(_A					)					)






@pytest.fixture(autouse=_A   ,						scope='session'					)
def 			lowercase				():







       """simple docstring"""







       datasets.disable_progress_bar()






@pytest.fixture(autouse=_A					)
def 			lowercase				(_A					):







       """simple docstring"""







       monkeypatch.setattr('datasets.config.HF_UPDATE_DOWNLOAD_COUNTS'   ,						_A					)






@pytest.fixture
def 			lowercase				(_A					):







       """simple docstring"""







       monkeypatch.setattr('sqlalchemy.util.deprecations.SILENCE_UBER_WARNING'   ,						_A					)

