diff --git a/lyrebird_ios/ios_helper.py b/lyrebird_ios/ios_helper.py index 3987bc5..4e12897 100644 --- a/lyrebird_ios/ios_helper.py +++ b/lyrebird_ios/ios_helper.py @@ -299,7 +299,7 @@ def stop_log(self): self._log_process = None def take_screen_shot(self): - file_name = self.device_name.replace(' ', '_') + file_name = self.model.replace(' ', '_') p = subprocess.run(f'{idevicescreenshot} -u {self.device_id} {tmp_dir}/{file_name}.png', shell=True) if p.returncode == 0: return os.path.abspath(os.path.join(tmp_dir, '%s.png' % file_name)) diff --git a/lyrebird_ios/ui.py b/lyrebird_ios/ui.py index 28881ac..e335e58 100644 --- a/lyrebird_ios/ui.py +++ b/lyrebird_ios/ui.py @@ -97,7 +97,7 @@ def take_screen_shot(self, device_id): 'Please make sure the idevicescreenshot command works correctly') def get_screenshot_image(self, device_id): - return send_from_directory(tmp_dir, '%s.png' % device_service.devices.get(device_id).device_name.replace(' ', '_')) + return send_from_directory(tmp_dir, '%s.png' % device_service.devices.get(device_id).model.replace(' ', '_')) def make_dump_data(self, path): device_data = {} diff --git a/setup.py b/setup.py index 3728ccd..7ad5d25 100644 --- a/setup.py +++ b/setup.py @@ -8,7 +8,7 @@ setup( name='lyrebird-ios', - version='0.1.5', + version='0.1.6', packages=['lyrebird_ios'], url='https://github.com/meituan/lyrebird-ios', author='HBQA',