You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: MIGRATION_GUIDE.md
+55Lines changed: 55 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,6 +11,61 @@ Changes are grouped as follows:
11
11
12
12
## From v7 to v8
13
13
14
+
### Dependency
15
+
-**httpx**: The SDK now uses `httpx` instead of `requests` for HTTP operations. This is a required dependency.
16
+
-**anyio**: Added as a required dependency (used by httpx, replaces pytest-asyncio).
17
+
18
+
### Functionality
19
+
-**Async Support**: The SDK now provides full async support. The main client is now `AsyncCogniteClient` (previously `CogniteClient`), and a new synchronous `CogniteClient` is available for backward compatibility.
20
+
-**HTTP Client**: All HTTP operations now use `httpx.AsyncClient` instead of `requests`.
21
+
-**DataFrames**: Datapoints DataFrames now use MultiIndex columns for better organization of aggregate data.
22
+
-**File Handling**: FilesAPI now prefers `pathlib.Path` objects over strings (though string support is maintained).
23
+
-**JSON Serialization**: The SDK now uses compact JSON encoding for better performance.
24
+
25
+
### Removed
26
+
-**Deprecated Aggregate Methods**: Removed deprecated `aggregate` methods from AssetsAPI, EventsAPI, SequencesAPI, and TimeSeriesAPI. Use `aggregate_count` instead.
27
+
-**Deprecated Filter Methods**: Removed deprecated filter methods from various APIs.
28
+
-**Deprecated Data Classes**:
29
+
-`CountAggregate` class removed
30
+
-`DataPointSubscriptionCreate` class removed
31
+
-`SequenceData` class replaced by `SequenceRows` (old class still available for backward compatibility)
32
+
-**Deprecated Methods**:
33
+
-`DatapointsArray.__iter__` method removed
34
+
-`CogniteObject.load_yaml` method on Query removed
35
+
-`DataModelingInstancesList.get` method no longer accepts deprecated `id` argument
36
+
- All `__iter__` methods removed from API classes
37
+
-**Legacy Attributes**:
38
+
-`legacy_name` attribute removed from time series data classes
39
+
-`expected_fields` parameter removed from `Datapoints._load`
40
+
-**Pyodide Handling**: Removed special pyodide handling in FilesAPI upload operations.
41
+
42
+
### Function Signature
43
+
-**Client Rename**: `CogniteClient` is now `AsyncCogniteClient`. A new synchronous `CogniteClient` is available.
44
+
-**Sequence Data**: `client.sequences.data.retrieve_latest` renamed to `client.sequences.data.retrieve_last_row`.
45
+
-**Data Modeling**: `expand_properties` parameter in `to_pandas` methods now defaults to `True` for data modeling classes.
46
+
-**File Paths**: FilesAPI methods now prefer `pathlib.Path` objects but still accept strings.
47
+
48
+
### Changed
49
+
-**API Organization**: Many APIs have been split into separate files (Java-style organization):
50
+
- Functions API split into `functions/` directory
51
+
- IAM API split into `iam/` directory
52
+
- Raw API split into `raw/` directory
53
+
- 3D API split into `three_d/` directory
54
+
- Workflows API split into `workflows/` directory
55
+
-**Query Classes**: Query and sync classes have been split into separate dataclasses.
56
+
-**Filter Classes**: Filter classes now have magic `__eq__` method for better usability.
57
+
-**Data Classes**: Various data classes have been updated with new attributes and methods.
58
+
-**Exception Handling**: New exception types added (e.g., `CogniteOrganizationError`, `CogniteModelFailedError`).
59
+
60
+
### Optional
61
+
-**New APIs**: Several new APIs have been added:
62
+
- Agents API for AI agent functionality
63
+
- Simulators API for simulation operations
64
+
- Document Preview API
65
+
- Space Statistics API
66
+
-**New Data Classes**: Many new data classes added for new features like agents, simulators, and enhanced data modeling.
67
+
-**Enhanced Capabilities**: New ACL capabilities added for Streams, Records, and AppConfig.
68
+
14
69
## From v6 to v7
15
70
### Functionality
16
71
-`CogniteResource.to_pandas` and `CogniteResourceList.to_pandas` now converts known timestamps to `datetime` by
0 commit comments