Module Import alias Import alias Import alias ImportFrom alias alias alias alias ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr TryExcept body Expr Call AttributeLoad NameLoad attr NameLoad For NameStore NameLoad body Assign TupleStore NameStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad If NameLoad body If NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad orelse Expr Call AttributeLoad NameLoad attr NameLoad NameLoad If BoolOpAnd NameLoad Call AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Call AttributeLoad NameLoad attr NameLoad keyword NameLoad keyword NameLoad orelse If NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Str If BoolOpAnd NameLoad Call AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Call AttributeLoad NameLoad attr NameLoad keyword NameLoad keyword NameLoad orelse If NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad orelse Expr Call AttributeLoad NameLoad attr NameLoad NameLoad keyword NameLoad keyword NameLoad orelse If NameLoad body If BoolOpAnd NameLoad Call AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num SubscriptLoad NameLoad Index Num Call AttributeLoad NameLoad attr NameLoad keyword NameLoad orelse With Call NameLoad NameLoad Str NameStore body Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num NameLoad If CompareEq Call NameLoad NameLoad Num body Expr Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler body If Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Raise decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign TupleStore NameStore NameStore NameStore TupleLoad NameLoad NameLoad NameLoad If Call NameLoad NameLoad NameLoad body If Call AttributeLoad NameLoad attr NameLoad body Assign NameStore NameLoad orelse Assign NameStore NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad orelse Assign NameStore NameLoad Assign NameStore SubscriptLoad NameLoad Index Num Return TupleLoad NameLoad NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return BoolOpAnd Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad If NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad If NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad If NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Return Assign NameStore ListComp NameLoad comprehension NameStore Call AttributeLoad NameLoad attr NameLoad UnaryOpNot Call AttributeLoad NameLoad attr NameLoad If CompareEq Call NameLoad NameLoad Num body Expr Call AttributeLoad NameLoad attr NameLoad SubscriptLoad NameLoad Index Num decorator_list Assign NameStore ListLoad Str Str Assign NameStore ListComp Call AttributeLoad NameLoad attr NameLoad comprehension NameStore ListLoad Str FunctionDef arguments args NameParam NameParam defaults body If CompareIn NameLoad AttributeLoad NameLoad attr body Return NameLoad Return Call NameLoad ListComp Call AttributeLoad NameLoad attr NameLoad comprehension NameStore AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str If CompareIs NameLoad NameLoad body Assign NameStore SubscriptLoad Call AttributeLoad NameLoad attr NameLoad Index Num Assign NameStore BinOpAdd NameLoad Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Assign NameStore NameLoad If Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad orelse Assign NameStore TupleLoad ListLoad ListLoad NameLoad Assign NameStore BinOpMod Str Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad If NameLoad body Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad orelse Assign NameStore Dict Str Str NameLoad Dict Str NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Return Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr keyword NameLoad Assign NameStore Dict Str Str NameLoad Dict Str Num Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr decorator_list decorator_list
N/A N/A re N/A os N/A shutil codalab.lib crypt_util file_util path_util zip_util UploadManager N/A object N/A N/A 
    Contains logic for uploading bundle data to the bundle store and updating
    the associated bundle metadata in the database.
     __init__ N/A N/A self bundle_model bundle_store N/A N/A N/A N/A self _bundle_model bundle_model N/A N/A self _bundle_store bundle_store N/A upload_to_bundle_store N/A N/A self bundle sources follow_symlinks exclude_patterns remove_sources git unpack simplify_archives N/A N/A N/A 
        Uploads contents for the given bundle to the bundle store.

        |sources|: specifies the locations of the contents to upload. Each element is
                   either a URL, a local path or a tuple (filename, file-like object).
        |follow_symlinks|: for local path(s), whether to follow (resolve) symlinks,
                           but only if remove_sources is False.
        |exclude_patterns|: for local path(s), don't upload these patterns (e.g., *.o),
                            but only if remove_sources is False.
        |remove_sources|: for local path(s), whether |sources| should be removed
        |git|: for URLs, whether |source| is a git repo to clone.
        |unpack|: for each source in |sources|, whether to unpack it if it's an archive.
        |simplify_archives|: whether to simplify unpacked archives so that if they
                             contain a single file, the final path is just that file,
                             not a directory containing that file.
    
        If |sources| contains one source, then the bundle contents will be that source.
        Otherwise, the bundle contents will be a directory with each of the sources.
        Exceptions:
        - If |git|, then each source is replaced with the result of running 'git clone |source|'
        - If |unpack| is True or a source is an archive (zip, tar.gz, etc.), then unpack the source.
         N/A bundle_path N/A N/A N/A self _bundle_store get_bundle_location N/A bundle uuid N/A N/A N/A N/A N/A path_util make_directory bundle_path N/A source sources N/A N/A N/A is_url is_local_path is_fileobj filename N/A N/A self _interpret_source source N/A source_output_path N/A N/A N/A os path join bundle_path filename N/A is_url N/A N/A git N/A N/A source_output_path N/A N/A file_util strip_git_ext source_output_path N/A N/A N/A file_util git_clone source source_output_path N/A N/A N/A N/A file_util download_url source source_output_path N/A N/A unpack N/A N/A self _can_unpack_file source_output_path N/A N/A N/A N/A self _unpack_file source_output_path N/A N/A zip_util strip_archive_ext source_output_path remove_source True simplify_archive simplify_archives N/A N/A is_local_path N/A N/A source_path N/A N/A path_util normalize source N/A N/A N/A path_util check_isvalid source_path upload N/A N/A unpack N/A N/A self _can_unpack_file source_path N/A N/A N/A N/A self _unpack_file source_path N/A N/A zip_util strip_archive_ext source_output_path remove_source remove_sources simplify_archive simplify_archives N/A N/A remove_sources N/A N/A N/A N/A path_util rename source_path source_output_path N/A N/A N/A N/A path_util copy source_path source_output_path follow_symlinks follow_symlinks exclude_patterns exclude_patterns N/A N/A is_fileobj N/A N/A N/A unpack N/A N/A zip_util path_is_archive filename N/A N/A N/A N/A self _unpack_fileobj N/A source N/A 0 N/A source N/A 1 N/A N/A zip_util strip_archive_ext source_output_path simplify_archive simplify_archives N/A N/A N/A open source_output_path wb out N/A N/A N/A N/A shutil copyfileobj N/A source N/A 1 out N/A N/A N/A len sources 1 N/A N/A N/A N/A self _simplify_directory bundle_path N/A N/A N/A N/A N/A N/A N/A os path exists bundle_path N/A N/A N/A N/A path_util remove bundle_path N/A N/A _interpret_source N/A N/A self source N/A N/A N/A N/A is_url is_local_path is_fileobj N/A False False False N/A N/A isinstance source basestring N/A N/A N/A N/A path_util path_is_url source N/A N/A is_url True N/A N/A is_local_path True N/A filename N/A N/A N/A os path basename N/A N/A N/A os path normpath source N/A N/A is_fileobj True N/A filename N/A source N/A 0 N/A N/A is_url is_local_path is_fileobj filename N/A _can_unpack_file N/A N/A self path N/A N/A N/A N/A N/A N/A N/A os path isfile path N/A N/A zip_util path_is_archive path N/A _unpack_file N/A N/A self source_path dest_path remove_source simplify_archive N/A N/A N/A N/A N/A zip_util unpack N/A N/A zip_util get_archive_ext source_path source_path dest_path N/A remove_source N/A N/A N/A N/A path_util remove source_path N/A simplify_archive N/A N/A N/A N/A self _simplify_archive dest_path N/A _unpack_fileobj N/A N/A self source_filename source_fileobj dest_path simplify_archive N/A N/A N/A N/A N/A zip_util unpack N/A N/A zip_util get_archive_ext source_filename source_fileobj dest_path N/A simplify_archive N/A N/A N/A N/A self _simplify_archive dest_path N/A _simplify_archive N/A N/A self path N/A N/A N/A 
        Modifies |path| in place: If |path| is a directory containing exactly
        one file / directory that is not ignored, then replace |path| with that
        file / directory.
         N/A N/A N/A N/A N/A os path isdir path N/A N/A N/A files N/A f N/A f N/A N/A os listdir path N/A N/A N/A self _ignore_file_in_archive f N/A N/A N/A len files 1 N/A N/A N/A N/A self _simplify_directory path N/A files N/A 0 N/A N/A IGNORE_FILE_EXACT N/A .DS_Store __MACOSX N/A IGNORE_FILE_PATTERNS N/A N/A N/A re compile s N/A s N/A ^\._.* _ignore_file_in_archive N/A N/A self filename N/A N/A N/A N/A filename N/A self IGNORE_FILE_EXACT N/A N/A True N/A N/A any N/A N/A N/A pattern match filename N/A pattern N/A self IGNORE_FILE_PATTERNS N/A _simplify_directory N/A N/A self path child_path N/A None N/A N/A 
        Modifies |path| in place: If the |path| directory contains exactly
        one file / directory, then replace |path| with that file / directory.
         N/A N/A child_path None N/A N/A child_path N/A N/A N/A os listdir path N/A 0 N/A temp_path N/A path N/A N/A crypt_util get_random_string N/A N/A N/A path_util rename path temp_path N/A child_path N/A N/A N/A os path join temp_path child_path N/A N/A N/A path_util rename child_path path N/A N/A N/A path_util remove temp_path N/A update_metadata_and_save N/A N/A self bundle new_bundle N/A N/A N/A 
        Updates the metadata about the contents of the bundle, including
        data_size as well as the total amount of disk used by the user.

        If |new_bundle| is True, saves the bundle as a new bundle. Otherwise,
        updates it.
         N/A bundle_path N/A N/A N/A self _bundle_store get_bundle_location N/A bundle uuid N/A dirs_and_files None N/A N/A N/A N/A os path isdir bundle_path N/A N/A dirs_and_files N/A N/A path_util recursive_ls bundle_path N/A N/A dirs_and_files N/A N/A N/A bundle_path N/A data_hash N/A 0x%s N/A N/A path_util hash_directory bundle_path dirs_and_files N/A data_size N/A N/A path_util get_size bundle_path dirs_and_files N/A new_bundle N/A N/A N/A bundle data_hash data_hash N/A N/A N/A N/A bundle metadata set_metadata_key data_size data_size N/A N/A N/A N/A self _bundle_model save_bundle bundle N/A N/A bundle_update N/A data_hash metadata data_hash N/A data_size data_size N/A N/A N/A N/A self _bundle_model update_bundle bundle bundle_update N/A N/A N/A N/A self _bundle_model update_user_disk_used N/A bundle owner_id N/A has_contents N/A N/A self bundle N/A N/A N/A N/A N/A N/A os path exists N/A N/A N/A self _bundle_store get_bundle_location N/A bundle uuid N/A cleanup_existing_contents N/A N/A self bundle N/A N/A N/A N/A N/A N/A self _bundle_store cleanup N/A bundle uuid dry_run False N/A bundle_update N/A data_hash metadata None N/A data_size 0 N/A N/A N/A N/A self _bundle_model update_bundle bundle bundle_update N/A N/A N/A N/A self _bundle_model update_user_disk_used N/A bundle owner_id N/A N/A