Skip to content

Conversation

@co-incc
Copy link

@co-incc co-incc commented Dec 5, 2024

Related to #858

type_ = get_column_python_type(pk)
value = False if type_ is bool and part == "False" else type_(part)
if type_ is datetime:
value = datetime.strptime(part, "%Y-%m-%d %H:%M:%S")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What happens if datetime is in different format? Should we also consider date objecT?

if type_ is datetime:
value = datetime.strptime(part, "%Y-%m-%d %H:%M:%S")
else:
print(part)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove print

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants