omnata-plugin-runtime 0.10.8a257__py3-none-any.whl → 0.10.9__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.
@@ -173,10 +173,22 @@ class SnowflakeViewColumn(BaseModel):
173
173
  )
174
174
 
175
175
  def __repr__(self) -> str:
176
- return "SnowflakeViewColumn(name=%r, definition=%r, comment=%r)" % (
176
+ return """SnowflakeViewColumn(
177
+ name=%r,
178
+ original_name=%r,
179
+ expression=%r,
180
+ comment=%r,
181
+ is_join_column=%r,
182
+ required_stream_names=%r,
183
+ referenced_columns=%r)
184
+ """ % (
177
185
  self.name,
178
- self.definition(),
186
+ self.original_name,
187
+ self.expression,
179
188
  self.comment,
189
+ self.is_join_column,
190
+ self.required_stream_names,
191
+ self.referenced_columns
180
192
  )
181
193
 
182
194
  def definition(self,original_name:bool = False) -> str:
@@ -614,7 +626,7 @@ class JsonSchemaTopLevel(BaseModel):
614
626
  - current_comment_path is the same length as above, and contains any "description" values found on the way down
615
627
  """
616
628
  json_property = JsonSchemaProperty.model_validate(property_value)
617
- # bit of basic home-grown validation, could probably use a library for this
629
+ children = []
618
630
  if json_property.type:
619
631
  if json_property.type == "object":
620
632
  # TODO: make this depth configurable on the sync
@@ -630,8 +642,7 @@ class JsonSchemaTopLevel(BaseModel):
630
642
  )
631
643
  for child_property_name, child_property_value in json_property.properties.items()
632
644
  ]
633
- return [item for sublist in children for item in sublist]
634
-
645
+ children = [item for sublist in children for item in sublist]
635
646
  current_field_name_path = current_field_name_path + [property_name]
636
647
  current_comment_path = current_comment_path + [
637
648
  json_property.description or ""
@@ -639,7 +650,7 @@ class JsonSchemaTopLevel(BaseModel):
639
650
  # remove empty strings from current_comment_path
640
651
  current_comment_path = [c for c in current_comment_path if c]
641
652
 
642
- return [SnowflakeViewColumn.from_json_schema_property(
653
+ columns = [SnowflakeViewColumn.from_json_schema_property(
643
654
  column_name="_".join(current_field_name_path),
644
655
  comment=" -> ".join(current_comment_path),
645
656
  variant_path=":".join([f'"{p}"' for p in current_field_name_path if p]),
@@ -647,6 +658,8 @@ class JsonSchemaTopLevel(BaseModel):
647
658
  column_name_environment=column_name_environment,
648
659
  column_name_expression=column_name_expression
649
660
  )]
661
+ columns.extend(children)
662
+ return columns
650
663
 
651
664
 
652
665
  def normalized_view_part(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: omnata-plugin-runtime
3
- Version: 0.10.8a257
3
+ Version: 0.10.9
4
4
  Summary: Classes and common runtime components for building and running Omnata Plugins
5
5
  Author: James Weakley
6
6
  Author-email: james.weakley@omnata.com
@@ -2,12 +2,12 @@ omnata_plugin_runtime/__init__.py,sha256=MS9d1whnfT_B3-ThqZ7l63QeC_8OEKTuaYV5wTw
2
2
  omnata_plugin_runtime/api.py,sha256=baGraSMiD4Yvi3ZWrEv_TKh8Ktd1U8riBdOpe9j0Puw,8202
3
3
  omnata_plugin_runtime/configuration.py,sha256=0rfIGv8rCu8OwL7m-VOXIBjd05iyaBWRdt2h9o6scwo,46754
4
4
  omnata_plugin_runtime/forms.py,sha256=9YHJ_T17lT-rwyDaUg_0yj_YMPda4DRCw_wrvf8hE0E,19964
5
- omnata_plugin_runtime/json_schema.py,sha256=6dLkOC_aeD0iwi1neCnjcwHlqj-_IfcTlVDUr-1den0,34158
5
+ omnata_plugin_runtime/json_schema.py,sha256=Ch2tFcTDP16aZ3xFGSbnW7LVsbzIHNQFEhH9z2rHoTE,34417
6
6
  omnata_plugin_runtime/logging.py,sha256=WBuZt8lF9E5oFWM4KYQbE8dDJ_HctJ1pN3BHwU6rcd0,4461
7
7
  omnata_plugin_runtime/omnata_plugin.py,sha256=M0b6f9lKKEoEI0zf-ZwZcIPKPQTmHTIMhvcrBc94Mhg,133278
8
8
  omnata_plugin_runtime/plugin_entrypoints.py,sha256=iqGl8_nEEnPGKg3Aem4YLSQ6d5xS3ju5gq8MJbx6sCA,31968
9
9
  omnata_plugin_runtime/rate_limiting.py,sha256=qpr5esU4Ks8hMzuMpSR3gLFdor2ZUXYWCjmsQH_K6lQ,25882
10
- omnata_plugin_runtime-0.10.8a257.dist-info/LICENSE,sha256=rGaMQG3R3F5-JGDp_-rlMKpDIkg5n0SI4kctTk8eZSI,56
11
- omnata_plugin_runtime-0.10.8a257.dist-info/METADATA,sha256=kfPT1sT9Jhby1FyZuD6bgVchFaJjc-ayKB7TrCtH_Uc,2211
12
- omnata_plugin_runtime-0.10.8a257.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
13
- omnata_plugin_runtime-0.10.8a257.dist-info/RECORD,,
10
+ omnata_plugin_runtime-0.10.9.dist-info/LICENSE,sha256=rGaMQG3R3F5-JGDp_-rlMKpDIkg5n0SI4kctTk8eZSI,56
11
+ omnata_plugin_runtime-0.10.9.dist-info/METADATA,sha256=f5kB8qXsqcr5yRf_Xq-26wKOsCI_Jv33ATgIWbwkcqg,2207
12
+ omnata_plugin_runtime-0.10.9.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
13
+ omnata_plugin_runtime-0.10.9.dist-info/RECORD,,