Skip to content

Commit db1fa59

Browse files
fix cyclical imports
1 parent fcbc31a commit db1fa59

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

Diff for: src/onepasswordconnectsdk/config.py

+7-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
import os
22
import shlex
3-
from typing import List, Dict, Optional
3+
from typing import List, Dict, Optional, TYPE_CHECKING
44
import httpx
5-
from onepasswordconnectsdk.client import Client
5+
6+
if TYPE_CHECKING:
7+
from onepasswordconnectsdk.client import Client
68
from onepasswordconnectsdk.models import (
79
Item,
810
ParsedField,
@@ -55,7 +57,7 @@ def get_client_args(self, base_url: str, headers: Dict[str, str], timeout: float
5557
return args
5658

5759

58-
def load_dict(client: Client, config: dict):
60+
def load_dict(client: "Client", config: dict):
5961
"""Load: Takes a dictionary with keys specifiying the user
6062
desired naming scheme of the values to return. Each key's
6163
value is a dictionary that includes information on where
@@ -122,7 +124,7 @@ def load_dict(client: Client, config: dict):
122124
return config_values
123125

124126

125-
def load(client: Client, config: object):
127+
def load(client: "Client", config: object):
126128
"""Load: Takes a an object with class attributes annotated with tags
127129
describing where to find desired fields in 1Password. Manipulates given object
128130
and fills attributes in with 1Password item field values.
@@ -201,7 +203,7 @@ def _vault_uuid_for_field(field: str, vault_tag: dict):
201203

202204

203205
def _set_values_for_item(
204-
client: Client,
206+
client: "Client",
205207
parsed_item: ParsedItem,
206208
config_dict={},
207209
config_object: object = None,

0 commit comments

Comments
 (0)