Skip to content

Commit 0800284

Browse files
authored
Merge pull request #2280 from delftswa2017/fix-deprecation-warning
Fix deprecated decodestring warning
2 parents 21baa9b + 2fe8e46 commit 0800284

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

notebook/services/contents/largefilemanager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ def _save_large_file(self, os_path, content, format):
5757
bcontent = content.encode('utf8')
5858
else:
5959
b64_bytes = content.encode('ascii')
60-
bcontent = base64.decodestring(b64_bytes)
60+
bcontent = base64.b64decode(b64_bytes)
6161
except Exception as e:
6262
raise web.HTTPError(
6363
400, u'Encoding error saving %s: %s' % (os_path, e)

setup.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ warningfilters=module |.* |DeprecationWarning |notebook.*
88
ignore |.*schema.* |UserWarning |nbfor.*
99
ignore |The 'warn' method is deprecated, use 'warning' instead | DeprecationWarning |notebook.*
1010
error |encodestring\(\) is a deprecated alias, use encodebytes\(\)| DeprecationWarning | notebook.*
11-
11+
error |decodestring\(\) is a .*| DeprecationWarning | notebook.*

0 commit comments

Comments
 (0)