deprecated name warn() -> warning()

pull/2770/head
Thomas Kluyver 9 years ago
parent 1e511c5ebf
commit 3115f0602f

@ -240,13 +240,13 @@ class FileContentsManager(FileManagerMixin, ContentsManager):
# https://github.com/jupyter/notebook/issues/2539
# https://github.com/jupyter/notebook/issues/2757
# Use the Unix epoch as a fallback so we don't crash.
self.log.warn('Invalid mtime %s for %s', info.st_mtime, os_path)
self.log.warning('Invalid mtime %s for %s', info.st_mtime, os_path)
last_modified = datetime(1970, 1, 1, 0, 0, tzinfo=tz.UTC)
try:
created = tz.utcfromtimestamp(info.st_ctime)
except (ValueError, OSError): # See above
self.log.warn('Invalid ctime %s for %s', info.st_ctime, os_path)
self.log.warning('Invalid ctime %s for %s', info.st_ctime, os_path)
created = datetime(1970, 1, 1, 0, 0, tzinfo=tz.UTC)
# Create the base model.

Loading…
Cancel
Save