Skip to content

Commit adcaef3

Browse files
authored
Merge pull request #704 from atlanhq/bump-to-release-8.0.0
[release] Bump to release `8.0.0`
2 parents c7287ed + 614a4c8 commit adcaef3

File tree

5 files changed

+175
-29
lines changed

5 files changed

+175
-29
lines changed

β€ŽHISTORY.mdβ€Ž

Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,83 @@
1+
## 8.0.0 (August 20, 2025)
2+
3+
### New Features
4+
5+
#### Full `async/await` support
6+
7+
- Added `async/await` support to the SDK. All existing `clients` and `caches` now have async variants, plus new models (mainly search result models that require `async` iteration). Following `aio` directory convention for all async components.
8+
- Implemented `AsyncAtlanClient` for all async operations (extends `AtlanClient` for reusability).
9+
- For methods that accept client parameters, we've added corresponding `*_async()` variants:
10+
11+
| sync method | async method |
12+
|------------|--------------|
13+
| `Connection.creator()` | `Connection.creator_async()` |
14+
| `Badge.creator()` | `Badge.creator_async()` |
15+
| `FluentSearch.execute()` | `FluentSearch.execute_async()` |
16+
| `AtlanTag.of()` | `AtlanTag.of_async()` |
17+
| `SourceTagAttachment.by_name()` | `SourceTagAttachment.by_name_async()` |
18+
| `CompoundQuery.tagged_with_value()` | `CompoundQuery.tagged_with_value_async()` |
19+
| `Referenceable.json()` | `Referenceable.json_async()` |
20+
| `Referenceable.get_custom_metadata()` | `Referenceable.get_custom_metadata_async()` |
21+
| `Referenceable.set_custom_metadata()` | `Referenceable.set_custom_metadata_async()` |
22+
| `Referenceable.flush_custom_metadata()` | `Referenceable.flush_custom_metadata_async()` |
23+
24+
#### Shared business logic architecture
25+
26+
- Extracted common functionality (request preparation and response processing) into a separate `common` sub-package. This enables reuse across both sync and async operations - only the middle layer (API calling with respective clients) differs.
27+
28+
Example:
29+
```python
30+
from pyatlan.client.common import FindPurposesByName
31+
32+
@validate_arguments
33+
async def find_purposes_by_name(
34+
self,
35+
name: str,
36+
attributes: Optional[List[str]] = None,
37+
) -> List[Purpose]:
38+
"""
39+
Async find purposes by name using shared business logic.
40+
:param name: of the purpose
41+
:param attributes: (optional) collection of attributes to retrieve for the purpose
42+
:returns: all purposes with that name, if found
43+
:raises NotFoundError: if no purpose with the provided name exists
44+
"""
45+
search_request = FindPurposesByName.prepare_request(name, attributes)
46+
search_results = await self.search(search_request)
47+
return FindPurposesByName.process_response(
48+
search_results, name, allow_multiple=True
49+
)
50+
```
51+
52+
### Documentation
53+
54+
- **Asynchronous SDK operations**: https://developer.atlan.com/sdks/python/#asynchronous-sdk-operations
55+
56+
### Breaking Changes
57+
58+
While these aren't direct breaking changes to the SDK API, they may affect your code if you depend on these libraries:
59+
60+
- **Migrated from [`requests`](https://requests.readthedocs.io/en/latest) to [`httpx`](https://www.python-httpx.org)**: Completely removed support for `requests` library and migrated to `httpx`, which provides similar API for `sync` operations plus `async` client support for async operations.
61+
- **Replaced [`urllib3`](https://urllib3.readthedocs.io/en/stable) with [`httpx-retries`](https://will-ockmore.github.io/httpx-retries)**: Removed support for `urllib3` retry mechanism and implemented retries using `httpx-retries` library (API remains similar).
62+
63+
### QOL Improvements
64+
65+
- Generated latest typedef models.
66+
- Removed redundant requirements files (no longer needed since migration to `uv` in previous releases).
67+
- Updated GitHub workflows for Docker image builds to use `uv sync` (without dev dependencies).
68+
- Added unit and integration tests for `async` SDK.
69+
- Added `x-atlan-client-type: sync` or `x-atlan-client-type: async` to SDK headers and logging for better observability.
70+
- Added `async-integration-tests` job to `pyatlan-pr.yaml` workflow. Triggers when there are changes to async SDK code or can be triggered manually via `run-async-tests` label on PR.
71+
- Async SDK unit tests run by default on every commit push as they have minimal time impact on test suite.
72+
- Used module-scoped asyncio test fixtures similar to sync integration tests:
73+
```toml
74+
# pyproject.toml
75+
asyncio_mode = "auto"
76+
asyncio_default_test_loop_scope = "module"
77+
asyncio_default_fixture_loop_scope = "module"
78+
```
79+
- Used `token_client` fixtures when creating/deleting API tokens with `retry=0` to avoid token overpopulation in test tenants.
80+
181
## 7.2.0 (August 13, 2025)
282

383
### New Features

β€ŽREADME.mdβ€Ž

Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -206,6 +206,98 @@ This will:
206206
- 🎨 Format code automatically
207207
- ⚑ Support incremental updates
208208

209+
## πŸ“ Project Structure
210+
211+
Understanding the codebase layout will help you navigate and contribute effectively:
212+
213+
```
214+
atlan-python/
215+
β”œβ”€β”€ pyatlan/ # 🐍 Main Python package
216+
β”‚ β”œβ”€β”€ __init__.py # Package initialization
217+
β”‚ β”œβ”€β”€ cache/ # πŸ’Ύ Caching mechanisms
218+
β”‚ β”‚ β”œβ”€β”€ atlan_tag_cache.py # Tag name ↔ GUID mapping
219+
β”‚ β”‚ β”œβ”€β”€ custom_metadata_cache.py # Custom metadata definitions
220+
β”‚ β”‚ β”œβ”€β”€ enum_cache.py # Enum value caching
221+
β”‚ β”‚ └── aio/ # Async versions of caches
222+
β”‚ β”œβ”€β”€ client/ # 🌐 HTTP client implementations
223+
β”‚ β”‚ β”œβ”€β”€ atlan.py # Main synchronous client
224+
β”‚ β”‚ β”œβ”€β”€ asset.py # Asset operations (CRUD, search)
225+
β”‚ β”‚ β”œβ”€β”€ admin.py # Administrative operations
226+
β”‚ β”‚ β”œβ”€β”€ audit.py # Audit log operations
227+
β”‚ β”‚ β”œβ”€β”€ common/ # Shared client logic
228+
β”‚ β”‚ └── aio/ # Async client implementations
229+
β”‚ β”œβ”€β”€ model/ # πŸ“Š Data models and assets
230+
β”‚ β”‚ β”œβ”€β”€ assets/ # Asset type definitions
231+
β”‚ β”‚ β”‚ β”œβ”€β”€ core/ # Core asset types (Table, Database, etc.)
232+
β”‚ β”‚ β”‚ └── relations/ # Relationship models
233+
β”‚ β”‚ β”œβ”€β”€ fields/ # Search field definitions
234+
β”‚ β”‚ β”œβ”€β”€ open_lineage/ # OpenLineage specification models
235+
β”‚ β”‚ β”œβ”€β”€ packages/ # Package/workflow models
236+
β”‚ β”‚ └── aio/ # Async model variants
237+
β”‚ β”œβ”€β”€ generator/ # πŸ—οΈ Code generation tools
238+
β”‚ β”‚ β”œβ”€β”€ templates/ # Jinja2 templates for generation
239+
β”‚ β”‚ └── class_generator.py # Main generation logic
240+
β”‚ β”œβ”€β”€ pkg/ # πŸ“¦ Package creation utilities
241+
β”‚ β”œβ”€β”€ events/ # πŸ”” Event handling (webhooks, lambdas)
242+
β”‚ β”œβ”€β”€ samples/ # πŸ’‘ Example code and scripts
243+
β”‚ └── test_utils/ # πŸ§ͺ Testing utilities
244+
β”œβ”€β”€ tests/ # πŸ§ͺ Test suite
245+
β”‚ β”œβ”€β”€ unit/ # Unit tests (fast, no external deps)
246+
β”‚ β”œβ”€β”€ integration/ # Integration tests (require Atlan instance)
247+
β”‚ └── data/ # Test fixtures and mock data
248+
β”œβ”€β”€ docs/ # πŸ“š Sphinx documentation
249+
β”‚ β”œβ”€β”€ conf.py # Sphinx configuration
250+
β”‚ └── *.rst # Documentation source files
251+
β”œβ”€β”€ pyproject.toml # πŸ“‹ Project configuration (deps, tools)
252+
β”œβ”€β”€ uv.lock # πŸ”’ Locked dependencies
253+
β”œβ”€β”€ qa-checks # βœ… Quality assurance script
254+
β”œβ”€β”€ formatter # 🎨 Code formatting script
255+
└── generator # πŸ—οΈ Model generation script
256+
```
257+
258+
### Key Components
259+
260+
#### 🌐 **Client Layer** (`pyatlan/client/`)
261+
- **Synchronous**: Direct HTTP operations using `httpx`
262+
- **Asynchronous**: Async/await operations using `httpx.AsyncClient`
263+
- **Common**: Shared business logic between sync/async clients
264+
- **Specialized**: Domain-specific clients (admin, audit, lineage, etc.)
265+
266+
#### πŸ“Š **Model Layer** (`pyatlan/model/`)
267+
- **Assets**: 400+ asset types (tables, dashboards, pipelines, etc.)
268+
- **Core Models**: Base classes, requests, responses
269+
- **Fields**: Search and filtering field definitions
270+
- **OpenLineage**: Data lineage specification compliance
271+
272+
#### πŸ’Ύ **Cache Layer** (`pyatlan/cache/`)
273+
- **Tag Cache**: Maps human-readable tag names to internal GUIDs
274+
- **Custom Metadata**: Caches custom attribute definitions
275+
- **Connection Cache**: Stores connector and connection metadata
276+
- **Async Variants**: Full async implementations for all caches
277+
278+
#### πŸ—οΈ **Generation System** (`pyatlan/generator/`)
279+
- **Templates**: Jinja2 templates for assets, enums, documentation
280+
- **Generator**: Retrieves typedefs and generates Python models
281+
- **Incremental**: Only regenerates changed models for efficiency
282+
283+
#### πŸ§ͺ **Testing Strategy**
284+
- **Unit Tests**: Fast, isolated tests with mocks/fixtures
285+
- **Integration Tests**: Real API calls (requires credentials)
286+
- **VCR Cassettes**: Record/replay HTTP interactions for consistent testing
287+
288+
#### πŸ“¦ **Package System** (`pyatlan/pkg/`)
289+
- **Custom Packages**: Framework for building Atlan-deployable packages
290+
- **Templates**: Pre-built package structures and configurations
291+
- **Utilities**: Helper functions for package development
292+
293+
### Development Workflow
294+
295+
1. **Models**: Generated from your Atlan instance's typedefs
296+
2. **Clients**: Hand-crafted for optimal developer experience
297+
3. **Tests**: Mix of unit (fast iteration) and integration (real validation)
298+
4. **Quality**: Automated formatting, linting, and type checking
299+
5. **Documentation**: Auto-generated from docstrings and examples
300+
209301
## πŸ“„ License
210302

211303
This project is licensed under the **Apache License 2.0** - see the [LICENSE](LICENSE) file for details.

β€Žpyatlan/version.txtβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
7.2.0
1+
8.0.0

β€Žpyproject.tomlβ€Ž

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ dependencies = [
3030
"pydantic~=2.11.7",
3131
"jinja2~=3.1.6",
3232
"tenacity~=9.1.2",
33-
"urllib3>=1.26.0,<3",
3433
"lazy_loader~=0.4",
3534
"nanoid~=2.0.0",
3635
"pytz~=2025.2",
@@ -114,5 +113,4 @@ asyncio_default_test_loop_scope = "module"
114113
asyncio_default_fixture_loop_scope = "module"
115114
filterwarnings = [
116115
"ignore::DeprecationWarning",
117-
"ignore:urllib3 v2 only supports OpenSSL 1.1.1+",
118116
]

β€Žuv.lockβ€Ž

Lines changed: 2 additions & 26 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
Β (0)