Skip to content

Commit

Permalink
Fix componentreflection test (#328)
Browse files Browse the repository at this point in the history
Fix: this allows component reflection test to pass

Databricks returns an empty string in the REMARKS column rather than a
`NoneType`.

Signed-off-by: Jesse Whitehouse <jesse.whitehouse@databricks.com>
  • Loading branch information
Jesse authored Jan 23, 2024
1 parent ae37007 commit a7f4773
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/databricks/sqlalchemy/_parse.py
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ def parse_column_info_from_tgetcolumnsresponse(thrift_resp_row) -> ReflectedColu
"type": final_col_type,
"nullable": bool(thrift_resp_row.NULLABLE),
"default": thrift_resp_row.COLUMN_DEF,
"comment": thrift_resp_row.REMARKS,
"comment": thrift_resp_row.REMARKS or None,
}

# TODO: figure out how to return sqlalchemy.interfaces in a way that mypy respects
Expand Down

0 comments on commit a7f4773

Please sign in to comment.