lusid-sdk 2.1.21__py3-none-any.whl → 2.1.22__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of lusid-sdk might be problematic. Click here for more details.
lusid/configuration.py
CHANGED
|
@@ -373,7 +373,7 @@ class Configuration:
|
|
|
373
373
|
return "Python SDK Debug Report:\n"\
|
|
374
374
|
"OS: {env}\n"\
|
|
375
375
|
"Python Version: {pyversion}\n"\
|
|
376
|
-
"Version of the API: 0.11.
|
|
376
|
+
"Version of the API: 0.11.6457\n"\
|
|
377
377
|
"SDK Package Version: {package_version}".\
|
|
378
378
|
format(env=sys.platform, pyversion=sys.version, package_version=package_version)
|
|
379
379
|
|
|
@@ -18,20 +18,23 @@ import re # noqa: F401
|
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
20
|
from datetime import datetime
|
|
21
|
-
from typing import Any, Dict,
|
|
22
|
-
from pydantic.v1 import Field,
|
|
21
|
+
from typing import Any, Dict, Optional
|
|
22
|
+
from pydantic.v1 import Field, StrictStr, validator
|
|
23
23
|
from lusid.models.instrument_event import InstrumentEvent
|
|
24
|
+
from lusid.models.units_ratio import UnitsRatio
|
|
24
25
|
|
|
25
26
|
class StockSplitEvent(InstrumentEvent):
|
|
26
27
|
"""
|
|
27
28
|
A split in the company's shares. Shareholders are given additional company shares based on the terms of the stock split. # noqa: E501
|
|
28
29
|
"""
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
30
|
+
payment_date: datetime = Field(..., alias="paymentDate", description="Date on which the stock split takes effect.")
|
|
31
|
+
ex_date: datetime = Field(..., alias="exDate", description="The first date on which the shares will trade at the post-split price.")
|
|
32
|
+
units_ratio: UnitsRatio = Field(..., alias="unitsRatio")
|
|
33
|
+
record_date: Optional[datetime] = Field(None, alias="recordDate", description="Date you have to be the holder of record in order to receive the additional shares.")
|
|
34
|
+
announcement_date: Optional[datetime] = Field(None, alias="announcementDate", description="Date the stock split was announced.")
|
|
32
35
|
instrument_event_type: StrictStr = Field(..., alias="instrumentEventType", description="The Type of Event. The available values are: TransitionEvent, InformationalEvent, OpenEvent, CloseEvent, StockSplitEvent, BondDefaultEvent, CashDividendEvent, AmortisationEvent, CashFlowEvent, ExerciseEvent, ResetEvent, TriggerEvent, RawVendorEvent, InformationalErrorEvent, BondCouponEvent, DividendReinvestmentEvent, AccumulationEvent, BondPrincipalEvent, DividendOptionEvent, MaturityEvent, FxForwardSettlementEvent, ExpiryEvent, ScripDividendEvent, StockDividendEvent")
|
|
33
36
|
additional_properties: Dict[str, Any] = {}
|
|
34
|
-
__properties = ["instrumentEventType", "
|
|
37
|
+
__properties = ["instrumentEventType", "paymentDate", "exDate", "unitsRatio", "recordDate", "announcementDate"]
|
|
35
38
|
|
|
36
39
|
@validator('instrument_event_type')
|
|
37
40
|
def instrument_event_type_validate_enum(cls, value):
|
|
@@ -65,11 +68,24 @@ class StockSplitEvent(InstrumentEvent):
|
|
|
65
68
|
"additional_properties"
|
|
66
69
|
},
|
|
67
70
|
exclude_none=True)
|
|
71
|
+
# override the default output from pydantic by calling `to_dict()` of units_ratio
|
|
72
|
+
if self.units_ratio:
|
|
73
|
+
_dict['unitsRatio'] = self.units_ratio.to_dict()
|
|
68
74
|
# puts key-value pairs in additional_properties in the top level
|
|
69
75
|
if self.additional_properties is not None:
|
|
70
76
|
for _key, _value in self.additional_properties.items():
|
|
71
77
|
_dict[_key] = _value
|
|
72
78
|
|
|
79
|
+
# set to None if record_date (nullable) is None
|
|
80
|
+
# and __fields_set__ contains the field
|
|
81
|
+
if self.record_date is None and "record_date" in self.__fields_set__:
|
|
82
|
+
_dict['recordDate'] = None
|
|
83
|
+
|
|
84
|
+
# set to None if announcement_date (nullable) is None
|
|
85
|
+
# and __fields_set__ contains the field
|
|
86
|
+
if self.announcement_date is None and "announcement_date" in self.__fields_set__:
|
|
87
|
+
_dict['announcementDate'] = None
|
|
88
|
+
|
|
73
89
|
return _dict
|
|
74
90
|
|
|
75
91
|
@classmethod
|
|
@@ -83,9 +99,11 @@ class StockSplitEvent(InstrumentEvent):
|
|
|
83
99
|
|
|
84
100
|
_obj = StockSplitEvent.parse_obj({
|
|
85
101
|
"instrument_event_type": obj.get("instrumentEventType"),
|
|
86
|
-
"equity_split_ratio": obj.get("equitySplitRatio"),
|
|
87
102
|
"payment_date": obj.get("paymentDate"),
|
|
88
|
-
"
|
|
103
|
+
"ex_date": obj.get("exDate"),
|
|
104
|
+
"units_ratio": UnitsRatio.from_dict(obj.get("unitsRatio")) if obj.get("unitsRatio") is not None else None,
|
|
105
|
+
"record_date": obj.get("recordDate"),
|
|
106
|
+
"announcement_date": obj.get("announcementDate")
|
|
89
107
|
})
|
|
90
108
|
# store additional fields in additional_properties
|
|
91
109
|
for _key in obj.keys():
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: lusid-sdk
|
|
3
|
-
Version: 2.1.
|
|
3
|
+
Version: 2.1.22
|
|
4
4
|
Summary: LUSID API
|
|
5
5
|
Home-page: https://github.com/finbourne/lusid-sdk-python
|
|
6
6
|
License: MIT
|
|
@@ -29,8 +29,8 @@ FINBOURNE Technology
|
|
|
29
29
|
|
|
30
30
|
This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
|
|
31
31
|
|
|
32
|
-
- API version: 0.11.
|
|
33
|
-
- Package version: 2.1.
|
|
32
|
+
- API version: 0.11.6457
|
|
33
|
+
- Package version: 2.1.22
|
|
34
34
|
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
|
|
35
35
|
For more information, please visit [https://www.finbourne.com](https://www.finbourne.com)
|
|
36
36
|
|
|
@@ -65,7 +65,7 @@ lusid/api/transaction_portfolios_api.py,sha256=q6AoYasxV3LQDossmM2BdJSo3arh526yU
|
|
|
65
65
|
lusid/api/translation_api.py,sha256=xTAaKEW96JTDIZBXCjxSguCa7Gz4oVd5jdObUE2egwo,20092
|
|
66
66
|
lusid/api_client.py,sha256=dF6l9RAsdxdQjf6Qn4ny6LB-QXlJmsscWiozCvyyBFA,30709
|
|
67
67
|
lusid/api_response.py,sha256=uCehWdXXDnAO2HAHGKe0SgpQ_mJiGDbcu-BHDF3n_IM,852
|
|
68
|
-
lusid/configuration.py,sha256=
|
|
68
|
+
lusid/configuration.py,sha256=4GJ9DA9kRzsITqRpFxDHtGBfL0l1J2SnyrMnTrLP2Uo,14404
|
|
69
69
|
lusid/exceptions.py,sha256=HIQwgmQrszLlcVCLaqex8dO0laVuejUyOMz7U2ZWJ6s,5326
|
|
70
70
|
lusid/extensions/__init__.py,sha256=DeUuQP7yTcklJH7LT-bw9wQhKEggcs1KwQbPbFcOlhw,560
|
|
71
71
|
lusid/extensions/api_client.py,sha256=Ob06urm4Em3MLzgP_geyeeGsPCkU225msW_1kpIeABM,30567
|
|
@@ -855,7 +855,7 @@ lusid/models/staging_rule_match_criteria.py,sha256=_RxCyvulK3necsQz6LI7YacbSZAkt
|
|
|
855
855
|
lusid/models/staging_rule_set.py,sha256=OKApxB5rst2X-k8UBwMCJSp7c9u8BZASVsL-X2ofxRw,4196
|
|
856
856
|
lusid/models/step_schedule.py,sha256=uNakrJcB9X3e31PekjEBbu_MLbKr77P-57Qf1Ot3uPg,4504
|
|
857
857
|
lusid/models/stock_dividend_event.py,sha256=46MTaraTbj29R0GRNbAA__tUisBVhE_lvYSMZb-uNXA,6107
|
|
858
|
-
lusid/models/stock_split_event.py,sha256
|
|
858
|
+
lusid/models/stock_split_event.py,sha256=JDltB7EeJIG3NLBLPMOHbrzzPnh6I-jxk8TPiR1vQ5Y,6051
|
|
859
859
|
lusid/models/stream.py,sha256=TGFloyewF3hi9RLyg0K3z13zxgvqAlHt46_AJuP9l7E,2865
|
|
860
860
|
lusid/models/string_comparison_type.py,sha256=4_CrV7WlDTrgAR866IyYXJZyVUXSNHBn7YrRdyiWKj0,799
|
|
861
861
|
lusid/models/string_compliance_parameter.py,sha256=0S7zWDfc9GQdOch-sO_aSLHvkRLqInJjh9hCwCLazow,5100
|
|
@@ -1018,6 +1018,6 @@ lusid/models/weighted_instruments.py,sha256=1y_y_vw4-LPsbkQx4FOzWdZc5fJnzhVkf1D3
|
|
|
1018
1018
|
lusid/models/yield_curve_data.py,sha256=SbxvdJ4-GWK9kpMdw4Fnxc7_kvIMwgsRsd_31UJn7nw,6330
|
|
1019
1019
|
lusid/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
1020
1020
|
lusid/rest.py,sha256=TNUzQ3yLNT2L053EdR7R0vNzQh2J3TlYD1T56Dye0W0,10138
|
|
1021
|
-
lusid_sdk-2.1.
|
|
1022
|
-
lusid_sdk-2.1.
|
|
1023
|
-
lusid_sdk-2.1.
|
|
1021
|
+
lusid_sdk-2.1.22.dist-info/METADATA,sha256=5rte80N8VSp9QYBY-PB-SGi2sdkr0qTulUx3Iscefg4,179952
|
|
1022
|
+
lusid_sdk-2.1.22.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
|
1023
|
+
lusid_sdk-2.1.22.dist-info/RECORD,,
|
|
File without changes
|