Teacher:
Let's look at this code:
`comment: str = None`
Is the type correct?
mypy:
Yes, everything is just fine!

@alexcleac
Shouldn't that require Optional[str], or throw an error?

@gappleto97 mypy should throw an error probably. And yes, that should be marked as optional :)

Sign in to participate in the conversation
Mastodon for Tech Folks

This Mastodon instance is for people interested in technology. Discussions aren't limited to technology, because tech folks shouldn't be limited to technology either!