lusid-sdk 2.1.747__py3-none-any.whl → 2.1.749__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.
- lusid/api/entities_api.py +12 -12
- lusid/api/transaction_portfolios_api.py +17 -8
- lusid/configuration.py +1 -1
- lusid/models/access_metadata_operation.py +52 -0
- lusid/models/account.py +52 -0
- lusid/models/accumulation_event.py +52 -0
- lusid/models/address_definition.py +52 -0
- lusid/models/address_key_compliance_parameter.py +52 -0
- lusid/models/address_key_list.py +52 -0
- lusid/models/address_key_list_compliance_parameter.py +52 -0
- lusid/models/adjust_global_commitment_event.py +52 -0
- lusid/models/aggregate_spec.py +52 -0
- lusid/models/aggregation_query.py +104 -0
- lusid/models/amortisation_event.py +52 -0
- lusid/models/append_fx_forward_curve_by_quote_reference.py +52 -0
- lusid/models/append_fx_forward_curve_data.py +52 -0
- lusid/models/append_fx_forward_pips_curve_data.py +52 -0
- lusid/models/append_fx_forward_tenor_curve_data.py +52 -0
- lusid/models/append_fx_forward_tenor_pips_curve_data.py +52 -0
- lusid/models/append_market_data.py +52 -0
- lusid/models/basket.py +52 -0
- lusid/models/bond.py +52 -0
- lusid/models/bond_conversion_schedule.py +52 -0
- lusid/models/bond_coupon_event.py +52 -0
- lusid/models/bond_default_event.py +52 -0
- lusid/models/bond_principal_event.py +52 -0
- lusid/models/bonus_issue_event.py +52 -0
- lusid/models/bool_compliance_parameter.py +52 -0
- lusid/models/bool_list_compliance_parameter.py +52 -0
- lusid/models/branch_step.py +52 -0
- lusid/models/branch_step_request.py +52 -0
- lusid/models/calendar_dependency.py +52 -0
- lusid/models/call_on_intermediate_securities_event.py +52 -0
- lusid/models/cap_floor.py +52 -0
- lusid/models/capital_distribution_event.py +52 -0
- lusid/models/cash.py +52 -0
- lusid/models/cash_dependency.py +52 -0
- lusid/models/cash_dividend_event.py +52 -0
- lusid/models/cash_flow_event.py +52 -0
- lusid/models/cash_flow_value.py +52 -0
- lusid/models/cash_flow_value_set.py +52 -0
- lusid/models/cash_perpetual.py +52 -0
- lusid/models/cds_credit_event.py +52 -0
- lusid/models/cds_index.py +52 -0
- lusid/models/cdx_credit_event.py +52 -0
- lusid/models/change_history.py +52 -0
- lusid/models/check_step.py +52 -0
- lusid/models/check_step_request.py +52 -0
- lusid/models/close_event.py +52 -0
- lusid/models/complete_portfolio.py +52 -0
- lusid/models/complex_bond.py +52 -0
- lusid/models/complex_market_data.py +52 -0
- lusid/models/compliance_parameter.py +52 -0
- lusid/models/compliance_step.py +52 -0
- lusid/models/compliance_step_request.py +52 -0
- lusid/models/constant_volatility_surface.py +52 -0
- lusid/models/contract_for_difference.py +52 -0
- lusid/models/contract_initialisation_event.py +52 -0
- lusid/models/create_data_type_request.py +156 -0
- lusid/models/create_derived_property_definition_request.py +52 -0
- lusid/models/create_derived_transaction_portfolio_request.py +52 -0
- lusid/models/create_identifier_definition_request.py +104 -0
- lusid/models/create_property_definition_request.py +104 -0
- lusid/models/create_simple_position_portfolio_request.py +52 -0
- lusid/models/create_transaction_portfolio_request.py +52 -0
- lusid/models/credit_default_swap.py +52 -0
- lusid/models/credit_premium_cash_flow_event.py +52 -0
- lusid/models/credit_spread_curve_data.py +52 -0
- lusid/models/curve_options.py +52 -0
- lusid/models/data_type.py +156 -0
- lusid/models/data_type_summary.py +156 -0
- lusid/models/date_time_compliance_parameter.py +52 -0
- lusid/models/date_time_list_compliance_parameter.py +52 -0
- lusid/models/decimal_compliance_parameter.py +52 -0
- lusid/models/decimal_list.py +52 -0
- lusid/models/decimal_list_compliance_parameter.py +52 -0
- lusid/models/deposit_close_event.py +52 -0
- lusid/models/deposit_interest_payment_event.py +52 -0
- lusid/models/discount_factor_curve_data.py +52 -0
- lusid/models/discounting_dependency.py +52 -0
- lusid/models/dividend_option_event.py +52 -0
- lusid/models/dividend_reinvestment_event.py +52 -0
- lusid/models/drawdown_event.py +52 -0
- lusid/models/early_redemption_event.py +52 -0
- lusid/models/economic_dependency.py +52 -0
- lusid/models/empty_model_options.py +52 -0
- lusid/models/equity.py +52 -0
- lusid/models/equity_curve_by_prices_data.py +52 -0
- lusid/models/equity_curve_dependency.py +52 -0
- lusid/models/equity_model_options.py +52 -0
- lusid/models/equity_option.py +52 -0
- lusid/models/equity_swap.py +52 -0
- lusid/models/equity_vol_dependency.py +52 -0
- lusid/models/equity_vol_surface_data.py +52 -0
- lusid/models/exchange_traded_option.py +52 -0
- lusid/models/exercise_event.py +52 -0
- lusid/models/exotic_instrument.py +52 -0
- lusid/models/expiry_event.py +52 -0
- lusid/models/field_schema.py +52 -0
- lusid/models/filter_predicate_compliance_parameter.py +52 -0
- lusid/models/filter_step.py +52 -0
- lusid/models/filter_step_request.py +52 -0
- lusid/models/fixed_leg.py +52 -0
- lusid/models/fixed_schedule.py +52 -0
- lusid/models/flexible_deposit.py +52 -0
- lusid/models/flexible_loan.py +52 -0
- lusid/models/float_schedule.py +52 -0
- lusid/models/floating_leg.py +52 -0
- lusid/models/forward_rate_agreement.py +52 -0
- lusid/models/fund_id_list.py +52 -0
- lusid/models/fund_share_class.py +52 -0
- lusid/models/funding_leg.py +52 -0
- lusid/models/funding_leg_options.py +52 -0
- lusid/models/future.py +52 -0
- lusid/models/future_expiry_event.py +52 -0
- lusid/models/future_mark_to_market_event.py +52 -0
- lusid/models/fx_dependency.py +52 -0
- lusid/models/fx_forward.py +52 -0
- lusid/models/fx_forward_curve_by_quote_reference.py +52 -0
- lusid/models/fx_forward_curve_data.py +52 -0
- lusid/models/fx_forward_model_options.py +156 -0
- lusid/models/fx_forward_pips_curve_data.py +52 -0
- lusid/models/fx_forward_settlement_event.py +52 -0
- lusid/models/fx_forward_tenor_curve_data.py +52 -0
- lusid/models/fx_forward_tenor_pips_curve_data.py +52 -0
- lusid/models/fx_forwards_dependency.py +52 -0
- lusid/models/fx_linked_notional_schedule.py +52 -0
- lusid/models/fx_option.py +52 -0
- lusid/models/fx_rate_schedule.py +52 -0
- lusid/models/fx_swap.py +52 -0
- lusid/models/fx_vol_dependency.py +52 -0
- lusid/models/fx_vol_surface_data.py +52 -0
- lusid/models/get_reference_portfolio_constituents_response.py +104 -0
- lusid/models/group_by_selector_compliance_parameter.py +52 -0
- lusid/models/group_by_step.py +52 -0
- lusid/models/group_by_step_request.py +52 -0
- lusid/models/group_calculation_compliance_parameter.py +52 -0
- lusid/models/group_filter_predicate_compliance_parameter.py +52 -0
- lusid/models/group_filter_step.py +52 -0
- lusid/models/group_filter_step_request.py +52 -0
- lusid/models/holdings_adjustment.py +52 -0
- lusid/models/holdings_adjustment_header.py +52 -0
- lusid/models/i_unit_definition_dto.py +52 -0
- lusid/models/identifier_definition.py +104 -0
- lusid/models/index_model_options.py +104 -0
- lusid/models/index_projection_dependency.py +52 -0
- lusid/models/inflation_fixing_dependency.py +52 -0
- lusid/models/inflation_leg.py +52 -0
- lusid/models/inflation_linked_bond.py +52 -0
- lusid/models/inflation_swap.py +52 -0
- lusid/models/informational_error_event.py +52 -0
- lusid/models/informational_event.py +52 -0
- lusid/models/instrument.py +104 -0
- lusid/models/instrument_event.py +52 -0
- lusid/models/instrument_leg.py +52 -0
- lusid/models/instrument_list.py +52 -0
- lusid/models/instrument_list_compliance_parameter.py +52 -0
- lusid/models/interest_rate_swap.py +52 -0
- lusid/models/interest_rate_swaption.py +52 -0
- lusid/models/intermediate_compliance_step.py +52 -0
- lusid/models/intermediate_compliance_step_request.py +52 -0
- lusid/models/intermediate_securities_distribution_event.py +52 -0
- lusid/models/ir_vol_cube_data.py +52 -0
- lusid/models/ir_vol_dependency.py +52 -0
- lusid/models/life_cycle_event_value.py +52 -0
- lusid/models/loan_facility.py +52 -0
- lusid/models/loan_interest_repayment_event.py +52 -0
- lusid/models/loan_principal_repayment_event.py +52 -0
- lusid/models/lusid_instrument.py +52 -0
- lusid/models/lusid_trade_ticket.py +52 -0
- lusid/models/market_data_key_rule.py +52 -0
- lusid/models/market_data_options.py +52 -0
- lusid/models/market_data_specific_rule.py +52 -0
- lusid/models/market_quote.py +52 -0
- lusid/models/mastered_instrument.py +52 -0
- lusid/models/match_criterion.py +52 -0
- lusid/models/maturity_event.py +52 -0
- lusid/models/mbs_coupon_event.py +52 -0
- lusid/models/mbs_interest_deferral_event.py +52 -0
- lusid/models/mbs_interest_shortfall_event.py +52 -0
- lusid/models/mbs_principal_event.py +52 -0
- lusid/models/mbs_principal_write_off_event.py +52 -0
- lusid/models/merger_event.py +52 -0
- lusid/models/model_options.py +52 -0
- lusid/models/model_selection.py +104 -0
- lusid/models/opaque_dependency.py +52 -0
- lusid/models/opaque_market_data.py +52 -0
- lusid/models/opaque_model_options.py +52 -0
- lusid/models/open_event.py +52 -0
- lusid/models/option_exercise_cash_event.py +52 -0
- lusid/models/option_exercise_physical_event.py +52 -0
- lusid/models/optionality_schedule.py +52 -0
- lusid/models/order_by_spec.py +52 -0
- lusid/models/output_transaction.py +52 -0
- lusid/models/percent_check_step.py +52 -0
- lusid/models/percent_check_step_request.py +52 -0
- lusid/models/portfolio.py +104 -0
- lusid/models/portfolio_details.py +52 -0
- lusid/models/portfolio_group_id_compliance_parameter.py +52 -0
- lusid/models/portfolio_group_id_list.py +52 -0
- lusid/models/portfolio_group_id_list_compliance_parameter.py +52 -0
- lusid/models/portfolio_id_compliance_parameter.py +52 -0
- lusid/models/portfolio_id_list.py +52 -0
- lusid/models/portfolio_id_list_compliance_parameter.py +52 -0
- lusid/models/portfolio_result_data_key_rule.py +52 -0
- lusid/models/portfolio_search_result.py +52 -0
- lusid/models/portfolio_without_href.py +104 -0
- lusid/models/property_definition.py +312 -0
- lusid/models/property_definition_search_result.py +312 -0
- lusid/models/property_filter.py +104 -0
- lusid/models/property_key_compliance_parameter.py +52 -0
- lusid/models/property_key_list_compliance_parameter.py +52 -0
- lusid/models/property_list.py +52 -0
- lusid/models/property_list_compliance_parameter.py +52 -0
- lusid/models/property_value_equals.py +52 -0
- lusid/models/property_value_in.py +52 -0
- lusid/models/protection_payout_cash_flow_event.py +52 -0
- lusid/models/quote_dependency.py +52 -0
- lusid/models/quote_series_id.py +104 -0
- lusid/models/raw_vendor_event.py +52 -0
- lusid/models/recombine_step.py +52 -0
- lusid/models/reconcile_date_time_rule.py +104 -0
- lusid/models/reconcile_numeric_rule.py +104 -0
- lusid/models/reconcile_string_rule.py +104 -0
- lusid/models/reconciliation_rule.py +52 -0
- lusid/models/reference_instrument.py +52 -0
- lusid/models/reference_list.py +52 -0
- lusid/models/repo.py +52 -0
- lusid/models/reset_event.py +52 -0
- lusid/models/resource_list_of_value_type.py +1 -1
- lusid/models/result_data_key_rule.py +52 -0
- lusid/models/result_key_rule.py +52 -0
- lusid/models/result_value.py +52 -0
- lusid/models/result_value0_d.py +52 -0
- lusid/models/result_value_bool.py +52 -0
- lusid/models/result_value_currency.py +52 -0
- lusid/models/result_value_date_time_offset.py +52 -0
- lusid/models/result_value_decimal.py +52 -0
- lusid/models/result_value_dictionary.py +52 -0
- lusid/models/result_value_int.py +52 -0
- lusid/models/result_value_string.py +52 -0
- lusid/models/reverse_stock_split_event.py +52 -0
- lusid/models/schedule.py +52 -0
- lusid/models/scrip_dividend_event.py +52 -0
- lusid/models/simple_cash_flow_loan.py +52 -0
- lusid/models/simple_instrument.py +104 -0
- lusid/models/spin_off_event.py +52 -0
- lusid/models/step_schedule.py +52 -0
- lusid/models/stock_dividend_event.py +52 -0
- lusid/models/stock_split_event.py +52 -0
- lusid/models/string_compliance_parameter.py +52 -0
- lusid/models/string_list.py +52 -0
- lusid/models/string_list_compliance_parameter.py +52 -0
- lusid/models/sub_holding_key_value_equals.py +52 -0
- lusid/models/swap_cash_flow_event.py +52 -0
- lusid/models/swap_principal_event.py +52 -0
- lusid/models/tender_event.py +52 -0
- lusid/models/term_deposit.py +52 -0
- lusid/models/term_deposit_interest_event.py +52 -0
- lusid/models/term_deposit_principal_event.py +52 -0
- lusid/models/total_return_swap.py +52 -0
- lusid/models/trade_ticket.py +52 -0
- lusid/models/transaction.py +52 -0
- lusid/models/transaction_configuration_movement_data.py +52 -0
- lusid/models/transaction_configuration_movement_data_request.py +52 -0
- lusid/models/transaction_configuration_type_alias.py +52 -0
- lusid/models/transaction_price.py +52 -0
- lusid/models/transaction_query_parameters.py +52 -0
- lusid/models/transition_event.py +52 -0
- lusid/models/trigger_event.py +52 -0
- lusid/models/update_deposit_amount_event.py +52 -0
- lusid/models/upsert_reference_portfolio_constituents_request.py +104 -0
- lusid/models/vendor_dependency.py +52 -0
- lusid/models/vendor_model_rule.py +52 -0
- lusid/models/weekend_mask.py +1 -1
- lusid/models/yield_curve_data.py +52 -0
- {lusid_sdk-2.1.747.dist-info → lusid_sdk-2.1.749.dist-info}/METADATA +7 -7
- {lusid_sdk-2.1.747.dist-info → lusid_sdk-2.1.749.dist-info}/RECORD +279 -279
- {lusid_sdk-2.1.747.dist-info → lusid_sdk-2.1.749.dist-info}/WHEEL +0 -0
@@ -35,6 +35,58 @@ class PortfolioGroupIdComplianceParameter(ComplianceParameter):
|
|
35
35
|
@validator('compliance_parameter_type')
|
36
36
|
def compliance_parameter_type_validate_enum(cls, value):
|
37
37
|
"""Validates the enum"""
|
38
|
+
|
39
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
40
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
41
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
42
|
+
|
43
|
+
|
44
|
+
# check it's a class that uses the 'type' property as a discriminator
|
45
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
46
|
+
if 'PortfolioGroupIdComplianceParameter' not in [
|
47
|
+
# For notification application classes
|
48
|
+
'AmazonSqsNotificationType',
|
49
|
+
'AmazonSqsNotificationTypeResponse',
|
50
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
51
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
52
|
+
'AzureServiceBusTypeResponse',
|
53
|
+
'AzureServiceBusNotificationType',
|
54
|
+
'EmailNotificationType',
|
55
|
+
'EmailNotificationTypeResponse',
|
56
|
+
'SmsNotificationType',
|
57
|
+
'SmsNotificationTypeResponse',
|
58
|
+
'WebhookNotificationType',
|
59
|
+
'WebhookNotificationTypeResponse',
|
60
|
+
|
61
|
+
# For workflow application classes
|
62
|
+
'CreateChildTasksAction',
|
63
|
+
'RunWorkerAction',
|
64
|
+
'TriggerParentTaskAction',
|
65
|
+
'CreateChildTasksActionResponse',
|
66
|
+
'RunWorkerActionResponse',
|
67
|
+
'TriggerParentTaskActionResponse',
|
68
|
+
'CreateNewTaskActivity',
|
69
|
+
'UpdateMatchingTasksActivity',
|
70
|
+
'CreateNewTaskActivityResponse',
|
71
|
+
'UpdateMatchingTasksActivityResponse',
|
72
|
+
'Fail',
|
73
|
+
'GroupReconciliation',
|
74
|
+
'HealthCheck',
|
75
|
+
'LuminesceView',
|
76
|
+
'SchedulerJob',
|
77
|
+
'Sleep',
|
78
|
+
'FailResponse',
|
79
|
+
'GroupReconciliationResponse',
|
80
|
+
'HealthCheckResponse',
|
81
|
+
'LuminesceViewResponse',
|
82
|
+
'SchedulerJobResponse',
|
83
|
+
'SleepResponse']:
|
84
|
+
return value
|
85
|
+
|
86
|
+
# Only validate the 'type' property of the class
|
87
|
+
if "compliance_parameter_type" != "type":
|
88
|
+
return value
|
89
|
+
|
38
90
|
if value not in ('BoolComplianceParameter', 'StringComplianceParameter', 'DecimalComplianceParameter', 'DateTimeComplianceParameter', 'PropertyKeyComplianceParameter', 'AddressKeyComplianceParameter', 'PortfolioIdComplianceParameter', 'PortfolioGroupIdComplianceParameter', 'StringListComplianceParameter', 'BoolListComplianceParameter', 'DateTimeListComplianceParameter', 'DecimalListComplianceParameter', 'PropertyKeyListComplianceParameter', 'AddressKeyListComplianceParameter', 'PortfolioIdListComplianceParameter', 'PortfolioGroupIdListComplianceParameter', 'InstrumentListComplianceParameter', 'FilterPredicateComplianceParameter', 'GroupFilterPredicateComplianceParameter', 'GroupBySelectorComplianceParameter', 'PropertyListComplianceParameter', 'GroupCalculationComplianceParameter'):
|
39
91
|
raise ValueError("must be one of enum values ('BoolComplianceParameter', 'StringComplianceParameter', 'DecimalComplianceParameter', 'DateTimeComplianceParameter', 'PropertyKeyComplianceParameter', 'AddressKeyComplianceParameter', 'PortfolioIdComplianceParameter', 'PortfolioGroupIdComplianceParameter', 'StringListComplianceParameter', 'BoolListComplianceParameter', 'DateTimeListComplianceParameter', 'DecimalListComplianceParameter', 'PropertyKeyListComplianceParameter', 'AddressKeyListComplianceParameter', 'PortfolioIdListComplianceParameter', 'PortfolioGroupIdListComplianceParameter', 'InstrumentListComplianceParameter', 'FilterPredicateComplianceParameter', 'GroupFilterPredicateComplianceParameter', 'GroupBySelectorComplianceParameter', 'PropertyListComplianceParameter', 'GroupCalculationComplianceParameter')")
|
40
92
|
return value
|
@@ -35,6 +35,58 @@ class PortfolioGroupIdList(ReferenceList):
|
|
35
35
|
@validator('reference_list_type')
|
36
36
|
def reference_list_type_validate_enum(cls, value):
|
37
37
|
"""Validates the enum"""
|
38
|
+
|
39
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
40
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
41
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
42
|
+
|
43
|
+
|
44
|
+
# check it's a class that uses the 'type' property as a discriminator
|
45
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
46
|
+
if 'PortfolioGroupIdList' not in [
|
47
|
+
# For notification application classes
|
48
|
+
'AmazonSqsNotificationType',
|
49
|
+
'AmazonSqsNotificationTypeResponse',
|
50
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
51
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
52
|
+
'AzureServiceBusTypeResponse',
|
53
|
+
'AzureServiceBusNotificationType',
|
54
|
+
'EmailNotificationType',
|
55
|
+
'EmailNotificationTypeResponse',
|
56
|
+
'SmsNotificationType',
|
57
|
+
'SmsNotificationTypeResponse',
|
58
|
+
'WebhookNotificationType',
|
59
|
+
'WebhookNotificationTypeResponse',
|
60
|
+
|
61
|
+
# For workflow application classes
|
62
|
+
'CreateChildTasksAction',
|
63
|
+
'RunWorkerAction',
|
64
|
+
'TriggerParentTaskAction',
|
65
|
+
'CreateChildTasksActionResponse',
|
66
|
+
'RunWorkerActionResponse',
|
67
|
+
'TriggerParentTaskActionResponse',
|
68
|
+
'CreateNewTaskActivity',
|
69
|
+
'UpdateMatchingTasksActivity',
|
70
|
+
'CreateNewTaskActivityResponse',
|
71
|
+
'UpdateMatchingTasksActivityResponse',
|
72
|
+
'Fail',
|
73
|
+
'GroupReconciliation',
|
74
|
+
'HealthCheck',
|
75
|
+
'LuminesceView',
|
76
|
+
'SchedulerJob',
|
77
|
+
'Sleep',
|
78
|
+
'FailResponse',
|
79
|
+
'GroupReconciliationResponse',
|
80
|
+
'HealthCheckResponse',
|
81
|
+
'LuminesceViewResponse',
|
82
|
+
'SchedulerJobResponse',
|
83
|
+
'SleepResponse']:
|
84
|
+
return value
|
85
|
+
|
86
|
+
# Only validate the 'type' property of the class
|
87
|
+
if "reference_list_type" != "type":
|
88
|
+
return value
|
89
|
+
|
38
90
|
if value not in ('PortfolioGroupIdList', 'PortfolioIdList', 'AddressKeyList', 'StringList', 'InstrumentList', 'DecimalList', 'PropertyList', 'FundIdList'):
|
39
91
|
raise ValueError("must be one of enum values ('PortfolioGroupIdList', 'PortfolioIdList', 'AddressKeyList', 'StringList', 'InstrumentList', 'DecimalList', 'PropertyList', 'FundIdList')")
|
40
92
|
return value
|
@@ -35,6 +35,58 @@ class PortfolioGroupIdListComplianceParameter(ComplianceParameter):
|
|
35
35
|
@validator('compliance_parameter_type')
|
36
36
|
def compliance_parameter_type_validate_enum(cls, value):
|
37
37
|
"""Validates the enum"""
|
38
|
+
|
39
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
40
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
41
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
42
|
+
|
43
|
+
|
44
|
+
# check it's a class that uses the 'type' property as a discriminator
|
45
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
46
|
+
if 'PortfolioGroupIdListComplianceParameter' not in [
|
47
|
+
# For notification application classes
|
48
|
+
'AmazonSqsNotificationType',
|
49
|
+
'AmazonSqsNotificationTypeResponse',
|
50
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
51
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
52
|
+
'AzureServiceBusTypeResponse',
|
53
|
+
'AzureServiceBusNotificationType',
|
54
|
+
'EmailNotificationType',
|
55
|
+
'EmailNotificationTypeResponse',
|
56
|
+
'SmsNotificationType',
|
57
|
+
'SmsNotificationTypeResponse',
|
58
|
+
'WebhookNotificationType',
|
59
|
+
'WebhookNotificationTypeResponse',
|
60
|
+
|
61
|
+
# For workflow application classes
|
62
|
+
'CreateChildTasksAction',
|
63
|
+
'RunWorkerAction',
|
64
|
+
'TriggerParentTaskAction',
|
65
|
+
'CreateChildTasksActionResponse',
|
66
|
+
'RunWorkerActionResponse',
|
67
|
+
'TriggerParentTaskActionResponse',
|
68
|
+
'CreateNewTaskActivity',
|
69
|
+
'UpdateMatchingTasksActivity',
|
70
|
+
'CreateNewTaskActivityResponse',
|
71
|
+
'UpdateMatchingTasksActivityResponse',
|
72
|
+
'Fail',
|
73
|
+
'GroupReconciliation',
|
74
|
+
'HealthCheck',
|
75
|
+
'LuminesceView',
|
76
|
+
'SchedulerJob',
|
77
|
+
'Sleep',
|
78
|
+
'FailResponse',
|
79
|
+
'GroupReconciliationResponse',
|
80
|
+
'HealthCheckResponse',
|
81
|
+
'LuminesceViewResponse',
|
82
|
+
'SchedulerJobResponse',
|
83
|
+
'SleepResponse']:
|
84
|
+
return value
|
85
|
+
|
86
|
+
# Only validate the 'type' property of the class
|
87
|
+
if "compliance_parameter_type" != "type":
|
88
|
+
return value
|
89
|
+
|
38
90
|
if value not in ('BoolComplianceParameter', 'StringComplianceParameter', 'DecimalComplianceParameter', 'DateTimeComplianceParameter', 'PropertyKeyComplianceParameter', 'AddressKeyComplianceParameter', 'PortfolioIdComplianceParameter', 'PortfolioGroupIdComplianceParameter', 'StringListComplianceParameter', 'BoolListComplianceParameter', 'DateTimeListComplianceParameter', 'DecimalListComplianceParameter', 'PropertyKeyListComplianceParameter', 'AddressKeyListComplianceParameter', 'PortfolioIdListComplianceParameter', 'PortfolioGroupIdListComplianceParameter', 'InstrumentListComplianceParameter', 'FilterPredicateComplianceParameter', 'GroupFilterPredicateComplianceParameter', 'GroupBySelectorComplianceParameter', 'PropertyListComplianceParameter', 'GroupCalculationComplianceParameter'):
|
39
91
|
raise ValueError("must be one of enum values ('BoolComplianceParameter', 'StringComplianceParameter', 'DecimalComplianceParameter', 'DateTimeComplianceParameter', 'PropertyKeyComplianceParameter', 'AddressKeyComplianceParameter', 'PortfolioIdComplianceParameter', 'PortfolioGroupIdComplianceParameter', 'StringListComplianceParameter', 'BoolListComplianceParameter', 'DateTimeListComplianceParameter', 'DecimalListComplianceParameter', 'PropertyKeyListComplianceParameter', 'AddressKeyListComplianceParameter', 'PortfolioIdListComplianceParameter', 'PortfolioGroupIdListComplianceParameter', 'InstrumentListComplianceParameter', 'FilterPredicateComplianceParameter', 'GroupFilterPredicateComplianceParameter', 'GroupBySelectorComplianceParameter', 'PropertyListComplianceParameter', 'GroupCalculationComplianceParameter')")
|
40
92
|
return value
|
@@ -35,6 +35,58 @@ class PortfolioIdComplianceParameter(ComplianceParameter):
|
|
35
35
|
@validator('compliance_parameter_type')
|
36
36
|
def compliance_parameter_type_validate_enum(cls, value):
|
37
37
|
"""Validates the enum"""
|
38
|
+
|
39
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
40
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
41
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
42
|
+
|
43
|
+
|
44
|
+
# check it's a class that uses the 'type' property as a discriminator
|
45
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
46
|
+
if 'PortfolioIdComplianceParameter' not in [
|
47
|
+
# For notification application classes
|
48
|
+
'AmazonSqsNotificationType',
|
49
|
+
'AmazonSqsNotificationTypeResponse',
|
50
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
51
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
52
|
+
'AzureServiceBusTypeResponse',
|
53
|
+
'AzureServiceBusNotificationType',
|
54
|
+
'EmailNotificationType',
|
55
|
+
'EmailNotificationTypeResponse',
|
56
|
+
'SmsNotificationType',
|
57
|
+
'SmsNotificationTypeResponse',
|
58
|
+
'WebhookNotificationType',
|
59
|
+
'WebhookNotificationTypeResponse',
|
60
|
+
|
61
|
+
# For workflow application classes
|
62
|
+
'CreateChildTasksAction',
|
63
|
+
'RunWorkerAction',
|
64
|
+
'TriggerParentTaskAction',
|
65
|
+
'CreateChildTasksActionResponse',
|
66
|
+
'RunWorkerActionResponse',
|
67
|
+
'TriggerParentTaskActionResponse',
|
68
|
+
'CreateNewTaskActivity',
|
69
|
+
'UpdateMatchingTasksActivity',
|
70
|
+
'CreateNewTaskActivityResponse',
|
71
|
+
'UpdateMatchingTasksActivityResponse',
|
72
|
+
'Fail',
|
73
|
+
'GroupReconciliation',
|
74
|
+
'HealthCheck',
|
75
|
+
'LuminesceView',
|
76
|
+
'SchedulerJob',
|
77
|
+
'Sleep',
|
78
|
+
'FailResponse',
|
79
|
+
'GroupReconciliationResponse',
|
80
|
+
'HealthCheckResponse',
|
81
|
+
'LuminesceViewResponse',
|
82
|
+
'SchedulerJobResponse',
|
83
|
+
'SleepResponse']:
|
84
|
+
return value
|
85
|
+
|
86
|
+
# Only validate the 'type' property of the class
|
87
|
+
if "compliance_parameter_type" != "type":
|
88
|
+
return value
|
89
|
+
|
38
90
|
if value not in ('BoolComplianceParameter', 'StringComplianceParameter', 'DecimalComplianceParameter', 'DateTimeComplianceParameter', 'PropertyKeyComplianceParameter', 'AddressKeyComplianceParameter', 'PortfolioIdComplianceParameter', 'PortfolioGroupIdComplianceParameter', 'StringListComplianceParameter', 'BoolListComplianceParameter', 'DateTimeListComplianceParameter', 'DecimalListComplianceParameter', 'PropertyKeyListComplianceParameter', 'AddressKeyListComplianceParameter', 'PortfolioIdListComplianceParameter', 'PortfolioGroupIdListComplianceParameter', 'InstrumentListComplianceParameter', 'FilterPredicateComplianceParameter', 'GroupFilterPredicateComplianceParameter', 'GroupBySelectorComplianceParameter', 'PropertyListComplianceParameter', 'GroupCalculationComplianceParameter'):
|
39
91
|
raise ValueError("must be one of enum values ('BoolComplianceParameter', 'StringComplianceParameter', 'DecimalComplianceParameter', 'DateTimeComplianceParameter', 'PropertyKeyComplianceParameter', 'AddressKeyComplianceParameter', 'PortfolioIdComplianceParameter', 'PortfolioGroupIdComplianceParameter', 'StringListComplianceParameter', 'BoolListComplianceParameter', 'DateTimeListComplianceParameter', 'DecimalListComplianceParameter', 'PropertyKeyListComplianceParameter', 'AddressKeyListComplianceParameter', 'PortfolioIdListComplianceParameter', 'PortfolioGroupIdListComplianceParameter', 'InstrumentListComplianceParameter', 'FilterPredicateComplianceParameter', 'GroupFilterPredicateComplianceParameter', 'GroupBySelectorComplianceParameter', 'PropertyListComplianceParameter', 'GroupCalculationComplianceParameter')")
|
40
92
|
return value
|
@@ -35,6 +35,58 @@ class PortfolioIdList(ReferenceList):
|
|
35
35
|
@validator('reference_list_type')
|
36
36
|
def reference_list_type_validate_enum(cls, value):
|
37
37
|
"""Validates the enum"""
|
38
|
+
|
39
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
40
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
41
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
42
|
+
|
43
|
+
|
44
|
+
# check it's a class that uses the 'type' property as a discriminator
|
45
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
46
|
+
if 'PortfolioIdList' not in [
|
47
|
+
# For notification application classes
|
48
|
+
'AmazonSqsNotificationType',
|
49
|
+
'AmazonSqsNotificationTypeResponse',
|
50
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
51
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
52
|
+
'AzureServiceBusTypeResponse',
|
53
|
+
'AzureServiceBusNotificationType',
|
54
|
+
'EmailNotificationType',
|
55
|
+
'EmailNotificationTypeResponse',
|
56
|
+
'SmsNotificationType',
|
57
|
+
'SmsNotificationTypeResponse',
|
58
|
+
'WebhookNotificationType',
|
59
|
+
'WebhookNotificationTypeResponse',
|
60
|
+
|
61
|
+
# For workflow application classes
|
62
|
+
'CreateChildTasksAction',
|
63
|
+
'RunWorkerAction',
|
64
|
+
'TriggerParentTaskAction',
|
65
|
+
'CreateChildTasksActionResponse',
|
66
|
+
'RunWorkerActionResponse',
|
67
|
+
'TriggerParentTaskActionResponse',
|
68
|
+
'CreateNewTaskActivity',
|
69
|
+
'UpdateMatchingTasksActivity',
|
70
|
+
'CreateNewTaskActivityResponse',
|
71
|
+
'UpdateMatchingTasksActivityResponse',
|
72
|
+
'Fail',
|
73
|
+
'GroupReconciliation',
|
74
|
+
'HealthCheck',
|
75
|
+
'LuminesceView',
|
76
|
+
'SchedulerJob',
|
77
|
+
'Sleep',
|
78
|
+
'FailResponse',
|
79
|
+
'GroupReconciliationResponse',
|
80
|
+
'HealthCheckResponse',
|
81
|
+
'LuminesceViewResponse',
|
82
|
+
'SchedulerJobResponse',
|
83
|
+
'SleepResponse']:
|
84
|
+
return value
|
85
|
+
|
86
|
+
# Only validate the 'type' property of the class
|
87
|
+
if "reference_list_type" != "type":
|
88
|
+
return value
|
89
|
+
|
38
90
|
if value not in ('PortfolioGroupIdList', 'PortfolioIdList', 'AddressKeyList', 'StringList', 'InstrumentList', 'DecimalList', 'PropertyList', 'FundIdList'):
|
39
91
|
raise ValueError("must be one of enum values ('PortfolioGroupIdList', 'PortfolioIdList', 'AddressKeyList', 'StringList', 'InstrumentList', 'DecimalList', 'PropertyList', 'FundIdList')")
|
40
92
|
return value
|
@@ -35,6 +35,58 @@ class PortfolioIdListComplianceParameter(ComplianceParameter):
|
|
35
35
|
@validator('compliance_parameter_type')
|
36
36
|
def compliance_parameter_type_validate_enum(cls, value):
|
37
37
|
"""Validates the enum"""
|
38
|
+
|
39
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
40
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
41
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
42
|
+
|
43
|
+
|
44
|
+
# check it's a class that uses the 'type' property as a discriminator
|
45
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
46
|
+
if 'PortfolioIdListComplianceParameter' not in [
|
47
|
+
# For notification application classes
|
48
|
+
'AmazonSqsNotificationType',
|
49
|
+
'AmazonSqsNotificationTypeResponse',
|
50
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
51
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
52
|
+
'AzureServiceBusTypeResponse',
|
53
|
+
'AzureServiceBusNotificationType',
|
54
|
+
'EmailNotificationType',
|
55
|
+
'EmailNotificationTypeResponse',
|
56
|
+
'SmsNotificationType',
|
57
|
+
'SmsNotificationTypeResponse',
|
58
|
+
'WebhookNotificationType',
|
59
|
+
'WebhookNotificationTypeResponse',
|
60
|
+
|
61
|
+
# For workflow application classes
|
62
|
+
'CreateChildTasksAction',
|
63
|
+
'RunWorkerAction',
|
64
|
+
'TriggerParentTaskAction',
|
65
|
+
'CreateChildTasksActionResponse',
|
66
|
+
'RunWorkerActionResponse',
|
67
|
+
'TriggerParentTaskActionResponse',
|
68
|
+
'CreateNewTaskActivity',
|
69
|
+
'UpdateMatchingTasksActivity',
|
70
|
+
'CreateNewTaskActivityResponse',
|
71
|
+
'UpdateMatchingTasksActivityResponse',
|
72
|
+
'Fail',
|
73
|
+
'GroupReconciliation',
|
74
|
+
'HealthCheck',
|
75
|
+
'LuminesceView',
|
76
|
+
'SchedulerJob',
|
77
|
+
'Sleep',
|
78
|
+
'FailResponse',
|
79
|
+
'GroupReconciliationResponse',
|
80
|
+
'HealthCheckResponse',
|
81
|
+
'LuminesceViewResponse',
|
82
|
+
'SchedulerJobResponse',
|
83
|
+
'SleepResponse']:
|
84
|
+
return value
|
85
|
+
|
86
|
+
# Only validate the 'type' property of the class
|
87
|
+
if "compliance_parameter_type" != "type":
|
88
|
+
return value
|
89
|
+
|
38
90
|
if value not in ('BoolComplianceParameter', 'StringComplianceParameter', 'DecimalComplianceParameter', 'DateTimeComplianceParameter', 'PropertyKeyComplianceParameter', 'AddressKeyComplianceParameter', 'PortfolioIdComplianceParameter', 'PortfolioGroupIdComplianceParameter', 'StringListComplianceParameter', 'BoolListComplianceParameter', 'DateTimeListComplianceParameter', 'DecimalListComplianceParameter', 'PropertyKeyListComplianceParameter', 'AddressKeyListComplianceParameter', 'PortfolioIdListComplianceParameter', 'PortfolioGroupIdListComplianceParameter', 'InstrumentListComplianceParameter', 'FilterPredicateComplianceParameter', 'GroupFilterPredicateComplianceParameter', 'GroupBySelectorComplianceParameter', 'PropertyListComplianceParameter', 'GroupCalculationComplianceParameter'):
|
39
91
|
raise ValueError("must be one of enum values ('BoolComplianceParameter', 'StringComplianceParameter', 'DecimalComplianceParameter', 'DateTimeComplianceParameter', 'PropertyKeyComplianceParameter', 'AddressKeyComplianceParameter', 'PortfolioIdComplianceParameter', 'PortfolioGroupIdComplianceParameter', 'StringListComplianceParameter', 'BoolListComplianceParameter', 'DateTimeListComplianceParameter', 'DecimalListComplianceParameter', 'PropertyKeyListComplianceParameter', 'AddressKeyListComplianceParameter', 'PortfolioIdListComplianceParameter', 'PortfolioGroupIdListComplianceParameter', 'InstrumentListComplianceParameter', 'FilterPredicateComplianceParameter', 'GroupFilterPredicateComplianceParameter', 'GroupBySelectorComplianceParameter', 'PropertyListComplianceParameter', 'GroupCalculationComplianceParameter')")
|
40
92
|
return value
|
@@ -40,6 +40,58 @@ class PortfolioResultDataKeyRule(ResultKeyRule):
|
|
40
40
|
@validator('result_key_rule_type')
|
41
41
|
def result_key_rule_type_validate_enum(cls, value):
|
42
42
|
"""Validates the enum"""
|
43
|
+
|
44
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
45
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
46
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
47
|
+
|
48
|
+
|
49
|
+
# check it's a class that uses the 'type' property as a discriminator
|
50
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
51
|
+
if 'PortfolioResultDataKeyRule' not in [
|
52
|
+
# For notification application classes
|
53
|
+
'AmazonSqsNotificationType',
|
54
|
+
'AmazonSqsNotificationTypeResponse',
|
55
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
56
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
57
|
+
'AzureServiceBusTypeResponse',
|
58
|
+
'AzureServiceBusNotificationType',
|
59
|
+
'EmailNotificationType',
|
60
|
+
'EmailNotificationTypeResponse',
|
61
|
+
'SmsNotificationType',
|
62
|
+
'SmsNotificationTypeResponse',
|
63
|
+
'WebhookNotificationType',
|
64
|
+
'WebhookNotificationTypeResponse',
|
65
|
+
|
66
|
+
# For workflow application classes
|
67
|
+
'CreateChildTasksAction',
|
68
|
+
'RunWorkerAction',
|
69
|
+
'TriggerParentTaskAction',
|
70
|
+
'CreateChildTasksActionResponse',
|
71
|
+
'RunWorkerActionResponse',
|
72
|
+
'TriggerParentTaskActionResponse',
|
73
|
+
'CreateNewTaskActivity',
|
74
|
+
'UpdateMatchingTasksActivity',
|
75
|
+
'CreateNewTaskActivityResponse',
|
76
|
+
'UpdateMatchingTasksActivityResponse',
|
77
|
+
'Fail',
|
78
|
+
'GroupReconciliation',
|
79
|
+
'HealthCheck',
|
80
|
+
'LuminesceView',
|
81
|
+
'SchedulerJob',
|
82
|
+
'Sleep',
|
83
|
+
'FailResponse',
|
84
|
+
'GroupReconciliationResponse',
|
85
|
+
'HealthCheckResponse',
|
86
|
+
'LuminesceViewResponse',
|
87
|
+
'SchedulerJobResponse',
|
88
|
+
'SleepResponse']:
|
89
|
+
return value
|
90
|
+
|
91
|
+
# Only validate the 'type' property of the class
|
92
|
+
if "result_key_rule_type" != "type":
|
93
|
+
return value
|
94
|
+
|
43
95
|
if value not in ('Invalid', 'ResultDataKeyRule', 'PortfolioResultDataKeyRule'):
|
44
96
|
raise ValueError("must be one of enum values ('Invalid', 'ResultDataKeyRule', 'PortfolioResultDataKeyRule')")
|
45
97
|
return value
|
@@ -44,6 +44,58 @@ class PortfolioSearchResult(BaseModel):
|
|
44
44
|
@validator('type')
|
45
45
|
def type_validate_enum(cls, value):
|
46
46
|
"""Validates the enum"""
|
47
|
+
|
48
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
49
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
50
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
51
|
+
|
52
|
+
|
53
|
+
# check it's a class that uses the 'type' property as a discriminator
|
54
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
55
|
+
if 'PortfolioSearchResult' not in [
|
56
|
+
# For notification application classes
|
57
|
+
'AmazonSqsNotificationType',
|
58
|
+
'AmazonSqsNotificationTypeResponse',
|
59
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
60
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
61
|
+
'AzureServiceBusTypeResponse',
|
62
|
+
'AzureServiceBusNotificationType',
|
63
|
+
'EmailNotificationType',
|
64
|
+
'EmailNotificationTypeResponse',
|
65
|
+
'SmsNotificationType',
|
66
|
+
'SmsNotificationTypeResponse',
|
67
|
+
'WebhookNotificationType',
|
68
|
+
'WebhookNotificationTypeResponse',
|
69
|
+
|
70
|
+
# For workflow application classes
|
71
|
+
'CreateChildTasksAction',
|
72
|
+
'RunWorkerAction',
|
73
|
+
'TriggerParentTaskAction',
|
74
|
+
'CreateChildTasksActionResponse',
|
75
|
+
'RunWorkerActionResponse',
|
76
|
+
'TriggerParentTaskActionResponse',
|
77
|
+
'CreateNewTaskActivity',
|
78
|
+
'UpdateMatchingTasksActivity',
|
79
|
+
'CreateNewTaskActivityResponse',
|
80
|
+
'UpdateMatchingTasksActivityResponse',
|
81
|
+
'Fail',
|
82
|
+
'GroupReconciliation',
|
83
|
+
'HealthCheck',
|
84
|
+
'LuminesceView',
|
85
|
+
'SchedulerJob',
|
86
|
+
'Sleep',
|
87
|
+
'FailResponse',
|
88
|
+
'GroupReconciliationResponse',
|
89
|
+
'HealthCheckResponse',
|
90
|
+
'LuminesceViewResponse',
|
91
|
+
'SchedulerJobResponse',
|
92
|
+
'SleepResponse']:
|
93
|
+
return value
|
94
|
+
|
95
|
+
# Only validate the 'type' property of the class
|
96
|
+
if "type" != "type":
|
97
|
+
return value
|
98
|
+
|
47
99
|
if value not in ('Transaction', 'Reference', 'DerivedTransaction', 'SimplePosition'):
|
48
100
|
raise ValueError("must be one of enum values ('Transaction', 'Reference', 'DerivedTransaction', 'SimplePosition')")
|
49
101
|
return value
|
@@ -57,6 +57,58 @@ class PortfolioWithoutHref(BaseModel):
|
|
57
57
|
@validator('type')
|
58
58
|
def type_validate_enum(cls, value):
|
59
59
|
"""Validates the enum"""
|
60
|
+
|
61
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
62
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
63
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
64
|
+
|
65
|
+
|
66
|
+
# check it's a class that uses the 'type' property as a discriminator
|
67
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
68
|
+
if 'PortfolioWithoutHref' not in [
|
69
|
+
# For notification application classes
|
70
|
+
'AmazonSqsNotificationType',
|
71
|
+
'AmazonSqsNotificationTypeResponse',
|
72
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
73
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
74
|
+
'AzureServiceBusTypeResponse',
|
75
|
+
'AzureServiceBusNotificationType',
|
76
|
+
'EmailNotificationType',
|
77
|
+
'EmailNotificationTypeResponse',
|
78
|
+
'SmsNotificationType',
|
79
|
+
'SmsNotificationTypeResponse',
|
80
|
+
'WebhookNotificationType',
|
81
|
+
'WebhookNotificationTypeResponse',
|
82
|
+
|
83
|
+
# For workflow application classes
|
84
|
+
'CreateChildTasksAction',
|
85
|
+
'RunWorkerAction',
|
86
|
+
'TriggerParentTaskAction',
|
87
|
+
'CreateChildTasksActionResponse',
|
88
|
+
'RunWorkerActionResponse',
|
89
|
+
'TriggerParentTaskActionResponse',
|
90
|
+
'CreateNewTaskActivity',
|
91
|
+
'UpdateMatchingTasksActivity',
|
92
|
+
'CreateNewTaskActivityResponse',
|
93
|
+
'UpdateMatchingTasksActivityResponse',
|
94
|
+
'Fail',
|
95
|
+
'GroupReconciliation',
|
96
|
+
'HealthCheck',
|
97
|
+
'LuminesceView',
|
98
|
+
'SchedulerJob',
|
99
|
+
'Sleep',
|
100
|
+
'FailResponse',
|
101
|
+
'GroupReconciliationResponse',
|
102
|
+
'HealthCheckResponse',
|
103
|
+
'LuminesceViewResponse',
|
104
|
+
'SchedulerJobResponse',
|
105
|
+
'SleepResponse']:
|
106
|
+
return value
|
107
|
+
|
108
|
+
# Only validate the 'type' property of the class
|
109
|
+
if "type" != "type":
|
110
|
+
return value
|
111
|
+
|
60
112
|
if value not in ('Transaction', 'Reference', 'DerivedTransaction', 'SimplePosition'):
|
61
113
|
raise ValueError("must be one of enum values ('Transaction', 'Reference', 'DerivedTransaction', 'SimplePosition')")
|
62
114
|
return value
|
@@ -64,6 +116,58 @@ class PortfolioWithoutHref(BaseModel):
|
|
64
116
|
@validator('accounting_method')
|
65
117
|
def accounting_method_validate_enum(cls, value):
|
66
118
|
"""Validates the enum"""
|
119
|
+
|
120
|
+
# Finbourne have removed enum validation on all models, except for this use case:
|
121
|
+
# Workflow and notification application SDK use the property name 'type' as the discriminator on a number of classes.
|
122
|
+
# During instantiation, the value of 'type' is checked against the enum values,
|
123
|
+
|
124
|
+
|
125
|
+
# check it's a class that uses the 'type' property as a discriminator
|
126
|
+
# list of classes can be found by searching for 'actual_instance: Union[' in the generated code
|
127
|
+
if 'PortfolioWithoutHref' not in [
|
128
|
+
# For notification application classes
|
129
|
+
'AmazonSqsNotificationType',
|
130
|
+
'AmazonSqsNotificationTypeResponse',
|
131
|
+
'AmazonSqsPrincipalAuthNotificationType',
|
132
|
+
'AmazonSqsPrincipalAuthNotificationTypeResponse',
|
133
|
+
'AzureServiceBusTypeResponse',
|
134
|
+
'AzureServiceBusNotificationType',
|
135
|
+
'EmailNotificationType',
|
136
|
+
'EmailNotificationTypeResponse',
|
137
|
+
'SmsNotificationType',
|
138
|
+
'SmsNotificationTypeResponse',
|
139
|
+
'WebhookNotificationType',
|
140
|
+
'WebhookNotificationTypeResponse',
|
141
|
+
|
142
|
+
# For workflow application classes
|
143
|
+
'CreateChildTasksAction',
|
144
|
+
'RunWorkerAction',
|
145
|
+
'TriggerParentTaskAction',
|
146
|
+
'CreateChildTasksActionResponse',
|
147
|
+
'RunWorkerActionResponse',
|
148
|
+
'TriggerParentTaskActionResponse',
|
149
|
+
'CreateNewTaskActivity',
|
150
|
+
'UpdateMatchingTasksActivity',
|
151
|
+
'CreateNewTaskActivityResponse',
|
152
|
+
'UpdateMatchingTasksActivityResponse',
|
153
|
+
'Fail',
|
154
|
+
'GroupReconciliation',
|
155
|
+
'HealthCheck',
|
156
|
+
'LuminesceView',
|
157
|
+
'SchedulerJob',
|
158
|
+
'Sleep',
|
159
|
+
'FailResponse',
|
160
|
+
'GroupReconciliationResponse',
|
161
|
+
'HealthCheckResponse',
|
162
|
+
'LuminesceViewResponse',
|
163
|
+
'SchedulerJobResponse',
|
164
|
+
'SleepResponse']:
|
165
|
+
return value
|
166
|
+
|
167
|
+
# Only validate the 'type' property of the class
|
168
|
+
if "accounting_method" != "type":
|
169
|
+
return value
|
170
|
+
|
67
171
|
if value is None:
|
68
172
|
return value
|
69
173
|
|