gh-106392: Fix inconsistency in deprecation warnings (GH-106436)
They used "datetime" to refer to both the object and the module.
(cherry picked from commit d5c5d4bfd3)
Co-authored-by: William Andrea <william.j.andrea@gmail.com>
This breaks the tests, but we are keeping it as a separate commit so
that the move operation and editing of the moved files are separate, for
a cleaner history.