solidipes.utils package
Submodules
- solidipes.utils.cloud module
add_global_mount_info()check_process_return()connect_to_postgres()convert_cloud_to_cloud()convert_local_to_cloud()get_existing_mount_info()get_mount_id()list_mounts()mount()mount_all()mount_nfs_with_mount_command()mount_s3_juicefs()mount_s3_juicefs_psql()mount_s3_juicefs_sqlite3()mount_s3fs()mount_smb_with_mount_command()mount_sshfs()mount_with_mount_command()remove_keys_from_info()rsync()unmount()unmount_all()wait_mount()write_temp_passwd_file()
- solidipes.utils.config module
- solidipes.utils.git_infos module
- solidipes.utils.metadata module
- solidipes.utils.solidipes_logging module
- solidipes.utils.utils module
_get_config_path()add_completed_stage()bcolorsbcolors.BLACKbcolors.BLINKbcolors.BLUEbcolors.BOLDbcolors.BRIGHT_BLACKbcolors.BRIGHT_BLUEbcolors.BRIGHT_CYANbcolors.BRIGHT_GREENbcolors.BRIGHT_MAGENTAbcolors.BRIGHT_REDbcolors.BRIGHT_WHITEbcolors.BRIGHT_YELLOWbcolors.CYANbcolors.GREENbcolors.MAGENTAbcolors.REDbcolors.RESETbcolors.UNDERLINEbcolors.WHITEbcolors.YELLOW
dict_to_pretty_str()find_config_directory()generate_readme()get_cloud_dir_path()get_cloud_info()get_completed_stages()get_config()get_config_path()get_git_repository()get_git_root()get_ignore()get_mimes()get_mimes_path()get_path_relative_to_root()get_path_relative_to_workdir()get_readme_path()get_solidipes_directory()get_study_description_path()get_study_log_path()get_study_metadata()get_study_metadata_path()get_study_root_path()get_user_solidipes_directory()get_zenodo_infos()include_metadata_description()init_git_repository()is_stage_completed()load_yaml()populate_metadata_mandatory_fields()remove_completed_stage()rename_file()save_yaml()separate_metadata_description()set_cloud_info()set_config()set_ignore()set_mimes()set_study_metadata()set_zenodo_infos()transform_data_containers_to_dict()transform_dict_to_data_containers()
- solidipes.utils.zenodo_utils module
ZenodoException_download_zenodo_licenses()check_response()clean_deposition()create_deposition()download_file()download_files()get_access_token()get_existing_deposition_identifier()get_existing_deposition_infos()get_host_and_id()save_deposition_identifier()upload_archive()upload_deposition_metadata()
Module contents
- class solidipes.utils.bcolors[source]
Bases:
object- BLACK = '\x1b[30m'
- BLINK = '\x1b[5m'
- BLUE = '\x1b[34m'
- BOLD = '\x1b[1m'
- BRIGHT_BLACK = '\x1b[90m'
- BRIGHT_BLUE = '\x1b[94m'
- BRIGHT_CYAN = '\x1b[96m'
- BRIGHT_GREEN = '\x1b[92m'
- BRIGHT_MAGENTA = '\x1b[95m'
- BRIGHT_RED = '\x1b[91m'
- BRIGHT_WHITE = '\x1b[97m'
- BRIGHT_YELLOW = '\x1b[93m'
- CYAN = '\x1b[36m'
- GREEN = '\x1b[32m'
- MAGENTA = '\x1b[35m'
- RED = '\x1b[31m'
- RESET = '\x1b[0m'
- UNDERLINE = '\x1b[4m'
- WHITE = '\x1b[37m'
- YELLOW = '\x1b[33m'
- solidipes.utils.get_host_and_id(identifier)[source]
Extract Zenodo host and study ID from string identifier
URL has one of the following forms: - https://zenodo.org/record/1234567#xxx - https://zenodo.org/deposit/1234567#xxx - https://sandbox.zenodo.org/record/1234567#xxx - https://sandbox.zenodo.org/deposit/1234567#xxx - https://doi.org/10.5281/zenodo.1234567
DOI has the form 10.5281/zenodo.1234567
- Parameters:
identifier (str) – URL or DOI of the study to download
- Returns:
- Zenodo host and study ID
host: “zenodo.org” or “sandbox.zenodo.org”
- Return type:
(str, str)
- solidipes.utils.include_metadata_description(metadata, generate_readme=False, use_readme=False, md_to_html=False, **kwargs)[source]
Update metadata description field with DESCRIPTION.md file
- solidipes.utils.list_mounts(only_mounted=False)[source]
Get config expressed relative to working directory, with mount status