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

fix(targets): Bumped min joblib dependency to >=1.3.0 and replaced deprecated parallel_backend with parallel_config #2288

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: 2 additions & 2 deletions poetry.lock
edgarrmondragon marked this conversation as resolved.
Show resolved Hide resolved

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ fs = ">=2.4.16"
importlib-metadata = {version = "<8.0.0", python = "<3.12"}
importlib-resources = {version = ">=5.12.0", python = "<3.9"}
inflection = ">=0.5.1"
joblib = ">=1.0.1"
joblib = ">=1.3.0"
jsonpath-ng = ">=1.5.3"
jsonschema = ">=4.16.0"
packaging = ">=23.1"
Expand Down
4 changes: 2 additions & 2 deletions singer_sdk/target_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import typing as t

import click
from joblib import Parallel, delayed, parallel_backend
from joblib import Parallel, delayed, parallel_config

from singer_sdk.exceptions import RecordsWithoutSchemaException
from singer_sdk.helpers._batch import BaseBatchFileEncoding
Expand Down Expand Up @@ -521,7 +521,7 @@ def _drain_all(self, sink_list: list[Sink], parallelism: int) -> None:
def _drain_sink(sink: Sink) -> None:
self.drain_one(sink)

with parallel_backend("threading", n_jobs=parallelism):
with parallel_config(backend="threading", n_jobs=parallelism):
Parallel()(delayed(_drain_sink)(sink=sink) for sink in sink_list)

def _write_state_message(self, state: dict) -> None:
Expand Down