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

[Dashboard][Test] Fix osx tests failures on memory profiling #42081

Merged
merged 1 commit into from
Dec 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions dashboard/modules/reporter/tests/test_profile_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@ def long_run(self):
reason="This test is not supposed to work for minimal installation.",
)
@pytest.mark.skipif(sys.platform == "win32", reason="No memray on Windows.")
@pytest.mark.skipif(
sys.platform == "darwin",
reason="Fails on OSX, requires memray & lldb installed in osx image",
)
class TestMemoryProfiling:
async def test_basic_attach_profiler(self, setup_memory_profiler, shutdown_only):
# test basic attach profiler to running process
Expand Down
8 changes: 8 additions & 0 deletions dashboard/modules/reporter/tests/test_reporter.py
Original file line number Diff line number Diff line change
Expand Up @@ -809,6 +809,10 @@ def verify():
reason="This test is not supposed to work for minimal installation.",
)
@pytest.mark.skipif(sys.platform == "win32", reason="No memray on Windows.")
@pytest.mark.skipif(
sys.platform == "darwin",
reason="Fails on OSX, requires memray & lldb installed in osx image",
)
def test_get_memory_profile_running_task(shutdown_only):
"""
Verify that we can get the memory profile for a running task.
Expand Down Expand Up @@ -944,6 +948,10 @@ def verify():
reason="This test is not supposed to work for minimal installation.",
)
@pytest.mark.skipif(sys.platform == "win32", reason="No py-spy on Windows.")
@pytest.mark.skipif(
sys.platform == "darwin",
reason="Fails on OSX, requires memray & lldb installed in osx image",
)
def test_task_get_memory_profile_missing_params(shutdown_only):
"""
Verify that we throw an error for a non-running task.
Expand Down
8 changes: 8 additions & 0 deletions python/ray/tests/test_dashboard_profiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,10 @@ def get_actor_flamegraph():
reason="This test is not supposed to work for minimal installation.",
)
@pytest.mark.skipif(sys.platform == "win32", reason="No memray on Windows.")
@pytest.mark.skipif(
sys.platform == "darwin",
reason="Fails on OSX, requires memray & lldb installed in osx image",
)
@pytest.mark.parametrize("leaks", ["0", "1"])
def test_memory_profiler_endpoint(ray_start_with_dashboard, leaks):
# Sanity check memray are installed.
Expand Down Expand Up @@ -172,6 +176,10 @@ def get_actor_memory_multiple_flamegraphs():
reason="This test is not supposed to work for minimal installation.",
)
@pytest.mark.skipif(sys.platform == "win32", reason="No py-spy on Windows.")
@pytest.mark.skipif(
sys.platform == "darwin",
reason="Fails on OSX, requires memray & lldb installed in osx image",
)
def test_profiler_failure_message(ray_start_with_dashboard):
# Sanity check py-spy and memray is installed.
subprocess.check_call(["py-spy", "--version"])
Expand Down
Loading