Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor emulator start and stop functions for clarity and efficiency #22861

Open
wants to merge 14 commits into
base: main
Choose a base branch
from

Conversation

jchen351
Copy link
Contributor

Description

Motivation and Context

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can commit the suggested changes from lintrunner.

tools/python/util/android/android.py Outdated Show resolved Hide resolved
tools/python/util/android/android.py Outdated Show resolved Hide resolved
tools/python/util/android/android.py Outdated Show resolved Hide resolved
tools/python/util/android/android.py Outdated Show resolved Hide resolved
tools/python/util/android/android.py Outdated Show resolved Hide resolved
tools/python/util/android/android.py Outdated Show resolved Hide resolved
jchen351 and others added 9 commits November 15, 2024 16:58
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can commit the suggested changes from lintrunner.

tools/python/util/android/android.py Show resolved Hide resolved
tools/python/util/android/android.py Show resolved Hide resolved
tools/python/util/android/android.py Outdated Show resolved Hide resolved
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
"""Check if the emulator process is running based on a Popen instance."""
return emulator_proc.poll() is None

import os

Check warning

Code scanning / lintrunner

RUFF/E402 Warning

Module level import not at top of file.
See https://docs.astral.sh/ruff/rules/module-import-not-at-top-of-file
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can commit the suggested changes from lintrunner.

Comment on lines +254 to +256

import os
def is_emulator_running_by_pid(emulator_pid: int) -> bool:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
import os
def is_emulator_running_by_pid(emulator_pid: int) -> bool:
import os
def is_emulator_running_by_pid(emulator_pid: int) -> bool:

@snnn snnn added the platform:mobile issues related to ONNX Runtime mobile; typically submitted using template label Nov 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform:mobile issues related to ONNX Runtime mobile; typically submitted using template
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants