-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PRMP-640 #11
Conversation
gp_dynamo_item.update( | ||
actions=[ | ||
PracticeOds.supplier_name.set(requesting_supplier_name), | ||
PracticeOds.supplier_last_updated.set(datetime.now()), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we check whether the supplier_last_updated
should be of date
type or datetime
type?
I see that we use date.today() above (which output date
type), and we have datetime.now() here (which output datetime
type) .
When I tried compare date and datetime in local terminal it gave an error:
>>> datetime.now() < date.today()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: can't compare datetime.datetime to datetime.date
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you try datetime.now().date() < date.today()
it should be ok.
We convert datetime to date in line 179 😄
if supplier_name is None: | ||
|
||
if supplier_name is None: | ||
print( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are we able to add logger here instead of print?
No description provided.