Skip to content

Commit a16c21b

Browse files
committed
Correct problems with failing unit tests
1 parent 4a0a8a1 commit a16c21b

File tree

5 files changed

+104
-40
lines changed

5 files changed

+104
-40
lines changed

pyatlan/client/entity.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,5 +226,5 @@ def get_entity_by_guid(
226226
def update_entity(self, entity: T) -> AssetMutationResponse[T]:
227227
request = BulkRequest[T](entities=[entity])
228228
raw_json = self.client.call_api(EntityClient.BULK_UPDATE, None, request)
229-
response = AssetMutationResponse(**raw_json)
229+
response: AssetMutationResponse[T] = AssetMutationResponse(**raw_json)
230230
return response

pyatlan/generator/generate_from_typdefs.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,9 @@
1616
TEMPLATES_DIR = PARENT.parent / "templates"
1717
TYPE_DEF_FILE = Path(os.getenv("TMPDIR", "/tmp")) / "typedefs.json"
1818
TYPE_REPLACEMENTS = [
19+
("icon_type", "IconType"),
1920
("string", "str"),
20-
("date", "date"),
21+
("date", "datetime"),
2122
("array", "list"),
2223
("boolean", "bool"),
2324
("float", "float"),

pyatlan/generator/templates/entity.jinja2

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
from __future__ import annotations
22
from typing import Optional, Dict, Any, List, Literal
33
from pydantic import Field
4-
from datetime import date
4+
from datetime import datetime
55
from pyatlan.model.core import AtlanObject, Classification, Announcement
66
from pyatlan.model.enums import CertificateStatus, EntityStatus, google_datastudio_asset_type, powerbi_endorsement, \
7-
icon_type, AnnouncementType
7+
IconType, AnnouncementType, SourceCostUnitType
88

99
class Internal(AtlanObject):
1010
"""For internal usage"""

0 commit comments

Comments
 (0)