Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
chasleslr committed Jul 26, 2024
1 parent d013640 commit cac15c9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -222,10 +222,7 @@ def setup_for_execution(self, context: InitResourceContext) -> None:
kwargs["project"] = self.project
if self.base_url:
kwargs["base_url"] = self.base_url
self._client = Client(
api_key=self.api_key,
**kwargs
)
self._client = Client(api_key=self.api_key, **kwargs)

@public
@contextmanager
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
from mock.mock import Base
import pytest
from dagster import (
AssetExecutionContext,
Expand All @@ -20,7 +19,6 @@
from dagster._utils.test import wrap_op_in_graph_and_execute
from dagster_openai import OpenAIResource, with_usage_metadata
from mock import ANY, MagicMock, patch
from openai import OpenAI


@patch("dagster_openai.resources.Client")
Expand All @@ -39,7 +37,7 @@ def test_openai_client_with_config(mock_client) -> None:
api_key="xoxp-1234123412341234-12341234-1234",
organization="foo",
project="bar",
base_url="https://foo.bar"
base_url="https://foo.bar",
)
openai_resource.setup_for_execution(build_init_resource_context())

Expand All @@ -49,7 +47,7 @@ def test_openai_client_with_config(mock_client) -> None:
api_key="xoxp-1234123412341234-12341234-1234",
organization="foo",
project="bar",
base_url="https://foo.bar"
base_url="https://foo.bar",
)


Expand Down

0 comments on commit cac15c9

Please sign in to comment.