Skip to content

Enable new CI pipeline for standard & distributed tests #1481

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

Merged
merged 12 commits into from
Jul 27, 2022
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
7 changes: 7 additions & 0 deletions awswrangler/distributed/_distributed.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,10 @@ def initialize_ray(
)
os.environ["RAY_ENABLE_MAC_LARGE_OBJECT_STORE"] = "1"

ray_runtime_env_vars = [
"__MODIN_AUTOIMPORT_PANDAS__",
]

ray_init_kwargs = {
"num_cpus": cpu_count or multiprocessing.cpu_count(),
"num_gpus": gpu_count,
Expand All @@ -115,6 +119,9 @@ def initialize_ray(
"object_store_memory": object_store_memory,
"_redis_password": redis_password,
"_memory": object_store_memory,
"runtime_env": {
"env_vars": {var: os.environ.get(var) for var in ray_runtime_env_vars if os.environ.get(var)}
},
}
ray.init(**ray_init_kwargs)

Expand Down
3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -129,3 +129,6 @@ warn_unused_ignores = false
log_cli = false
filterwarnings = "ignore::DeprecationWarning"
addopts = "--log-cli-format \"[%(name)s][%(funcName)s] %(message)s\" --verbose --capture=sys"
markers = [
"distributed: tests againsts methods with distributed functionality",
]
3 changes: 3 additions & 0 deletions tests/test_lakeformation.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,16 @@
import time

import pandas as pd
import pytest

import awswrangler as wr

from ._utils import ensure_data_types, ensure_data_types_csv, get_df, get_df_csv

logging.getLogger("awswrangler").setLevel(logging.DEBUG)

pytestmark = pytest.mark.distributed


def test_lakeformation(path, path2, glue_database, glue_table, glue_table2, use_threads=False):
wr.catalog.delete_table_if_exists(database=glue_database, table=glue_table)
Expand Down
2 changes: 2 additions & 0 deletions tests/test_s3_select.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@

logging.getLogger("awswrangler").setLevel(logging.DEBUG)

pytestmark = pytest.mark.distributed


@pytest.mark.parametrize("use_threads", [True, False, 2])
def test_full_table(path, use_threads):
Expand Down