Skip to content
Closed
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
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

![](https://www.anduril.com/lattice-sdk/)

[![fern shield](https://img.shields.io/badge/%F0%9F%8C%BF-Built%20with%20Fern-brightgreen)](https://buildwithfern.com?utm_source=github&utm_medium=github&utm_campaign=readme&utm_source=https%3A%2F%2Fgithub.com%2Fanduril%2Flattice-sdk-python)
[![pypi](https://img.shields.io/pypi/v/anduril-lattice-sdk)](https://pypi.python.org/pypi/anduril-lattice-sdk)

The Lattice SDK Python library provides convenient access to the Lattice SDK APIs from Python.
Expand Down
103 changes: 51 additions & 52 deletions poetry.lock

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

3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "anduril-lattice-sdk"

[tool.poetry]
name = "anduril-lattice-sdk"
version = "2.3.0"
version = "2.4.0"
description = "HTTP clients for the Anduril Lattice SDK"
readme = "README.md"
authors = [
Expand Down Expand Up @@ -43,7 +43,6 @@ Repository = 'https://github.com/anduril/lattice-sdk-python'
[tool.poetry.dependencies]
python = "^3.8"
httpx = ">=0.21.2"
httpx-sse = "0.4.0"
pydantic = ">= 1.9.2"
pydantic-core = ">=2.18.2"
typing_extensions = ">= 4.0.0"
Expand Down
1 change: 0 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
httpx>=0.21.2
httpx-sse==0.4.0
pydantic>= 1.9.2
pydantic-core>=2.18.2
typing_extensions>= 4.0.0
4 changes: 2 additions & 2 deletions src/anduril/core/client_wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ def __init__(

def get_headers(self) -> typing.Dict[str, str]:
headers: typing.Dict[str, str] = {
"User-Agent": "anduril-lattice-sdk/2.3.0",
"User-Agent": "anduril-lattice-sdk/2.4.0",
"X-Fern-Language": "Python",
"X-Fern-SDK-Name": "anduril-lattice-sdk",
"X-Fern-SDK-Version": "2.3.0",
"X-Fern-SDK-Version": "2.4.0",
**(self.get_custom_headers() or {}),
}
token = self._get_token()
Expand Down
42 changes: 42 additions & 0 deletions src/anduril/core/http_sse/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# This file was auto-generated by Fern from our API Definition.

# isort: skip_file

import typing
from importlib import import_module

if typing.TYPE_CHECKING:
from ._api import EventSource, aconnect_sse, connect_sse
from ._exceptions import SSEError
from ._models import ServerSentEvent
_dynamic_imports: typing.Dict[str, str] = {
"EventSource": "._api",
"SSEError": "._exceptions",
"ServerSentEvent": "._models",
"aconnect_sse": "._api",
"connect_sse": "._api",
}


def __getattr__(attr_name: str) -> typing.Any:
module_name = _dynamic_imports.get(attr_name)
if module_name is None:
raise AttributeError(f"No {attr_name} found in _dynamic_imports for module name -> {__name__}")
try:
module = import_module(module_name, __package__)
if module_name == f".{attr_name}":
return module
else:
return getattr(module, attr_name)
except ImportError as e:
raise ImportError(f"Failed to import {attr_name} from {module_name}: {e}") from e
except AttributeError as e:
raise AttributeError(f"Failed to get {attr_name} from {module_name}: {e}") from e


def __dir__():
lazy_attrs = list(_dynamic_imports.keys())
return sorted(lazy_attrs)


__all__ = ["EventSource", "SSEError", "ServerSentEvent", "aconnect_sse", "connect_sse"]
Loading