tools/cygprofile/profile_android_startup.py
def _PullProfileData(self):
    """Pulls the profile data off of the device.

    Returns:
      A list of profile data files which were pulled.

    Raises:
      NoProfileDataError: No data was found on the device.
    """
    print('Pulling profile data...')
    self._SetUpHostFolders()
    self._device.PullFile(self._DEVICE_PROFILE_DIR, self._host_profile_dir,
                          timeout=300)

    # Temporary workaround/investigation: if (for unknown reason) 'adb pull' of
    # the directory 'orderfile' '.../Release/profile_data' produces
    # '...profile_data/orderfile/files' instead of the usual
    # '...profile_data/files', list the files deeper in the tree.
    files = []
    redundant_dir_root = os.path.basename(self._DEVICE_PROFILE_DIR)
    for root_file in os.listdir(self._host_profile_dir):
      if root_file == redundant_dir_root:
        profile_dir = os.path.join(self._host_profile_dir, root_file)
        files.extend(os.path.join(profile_dir, f)
                     for f in os.listdir(profile_dir))
      else:
        files.append(os.path.join(self._host_profile_dir, root_file))

    if len(files) == 0:
      raise NoProfileDataError('No profile data was collected')

    return files
Pulls the profile data off of the device.

    Returns:
      A list of profile data files which were pulled.

    Raises:
      NoProfileDataError: No data was found on the device.
    
Pulls the profile data off of the device.
Pulls the profile data off of the device .
def _PullProfileData(self):
    print('Pulling profile data...')
    self._SetUpHostFolders()
    self._device.PullFile(self._DEVICE_PROFILE_DIR, self._host_profile_dir,
                          timeout=300)
    files = []
    redundant_dir_root = os.path.basename(self._DEVICE_PROFILE_DIR)
    for root_file in os.listdir(self._host_profile_dir):
      if root_file == redundant_dir_root:
        profile_dir = os.path.join(self._host_profile_dir, root_file)
        files.extend(os.path.join(profile_dir, f)
                     for f in os.listdir(profile_dir))
      else:
        files.append(os.path.join(self._host_profile_dir, root_file))
    if len(files) == 0:
      raise NoProfileDataError('No profile data was collected')
    return files
def _PullProfileData ( self ) : print ( 'Pulling profile data...' ) self . _SetUpHostFolders ( ) self . _device . PullFile ( self . _DEVICE_PROFILE_DIR , self . _host_profile_dir , timeout = 300 ) files = [ ] redundant_dir_root = os . path . basename ( self . _DEVICE_PROFILE_DIR ) for root_file in os . listdir ( self . _host_profile_dir ) : if root_file == redundant_dir_root : profile_dir = os . path . join ( self . _host_profile_dir , root_file ) files . extend ( os . path . join ( profile_dir , f ) for f in os . listdir ( profile_dir ) ) else : files . append ( os . path . join ( self . _host_profile_dir , root_file ) ) if len ( files ) == 0 : raise NoProfileDataError ( 'No profile data was collected' ) return files
Pulls the profile data off of the device.
Pulls the profile data off of the device .
"""Pulls the profile data off of the device.

    Returns:
      A list of profile data files which were pulled.

    Raises:
      NoProfileDataError: No data was found on the device.
    """ # Temporary workaround/investigation: if (for unknown reason) 'adb pull' of # the directory 'orderfile' '.../Release/profile_data' produces # '...profile_data/orderfile/files' instead of the usual # '...profile_data/files', list the files deeper in the tree.
A list of profile data files which were pulled.
A list of profile data files which were pulled .
No data was found on the device.
No data was found on the device .
NoProfileDataError
self