omnata-plugin-runtime 0.9.3__tar.gz → 0.9.4__tar.gz

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: omnata-plugin-runtime
3
- Version: 0.9.3
3
+ Version: 0.9.4
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
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "omnata-plugin-runtime"
3
- version = "0.9.3"
3
+ version = "0.9.4"
4
4
  description = "Classes and common runtime components for building and running Omnata Plugins"
5
5
  authors = ["James Weakley <james.weakley@omnata.com>"]
6
6
  readme = "README.md"
@@ -584,15 +584,23 @@ def normalized_view_part(
584
584
  comment="A flag to indicate which run the record was last processed in",
585
585
  )
586
586
  )
587
- json_schema = JsonSchemaTopLevel.model_validate(stream_schema)
587
+ view_columns = snowflake_columns
588
+ joins = []
589
+ comment = None
590
+ if stream_schema is not None:
591
+ json_schema = JsonSchemaTopLevel.model_validate(stream_schema)
592
+ view_columns += json_schema.build_view_columns(
593
+ column_name_environment=column_name_environment,
594
+ column_name_expression=column_name_expression
595
+ )
596
+ if json_schema.joins:
597
+ joins = json_schema.joins
598
+ comment = json_schema.description
588
599
 
589
600
  return SnowflakeViewPart(
590
601
  stream_name=stream_name,
591
602
  raw_table_location=raw_table_location,
592
- columns=snowflake_columns + json_schema.build_view_columns(
593
- column_name_environment=column_name_environment,
594
- column_name_expression=column_name_expression
595
- ),
596
- joins=json_schema.joins or [],
597
- comment=json_schema.description
603
+ columns=view_columns,
604
+ joins=joins,
605
+ comment=comment
598
606
  )