From 8bb73c9fd3555deb83f01e1d18fa10c563202f78 Mon Sep 17 00:00:00 2001 From: Jon Dufresne Date: Tue, 11 Dec 2018 06:46:04 -0800 Subject: Simplify open() call by removing default mode The open() function opens files in read-only text mode by default. Drop the mode argument to be slightly simpler and more idiomatic. https://docs.python.org/3/library/functions.html#open > The default mode is 'r' (open for reading text, synonym of 'rt'). --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'setup.py') diff --git a/setup.py b/setup.py index 76986044a..cfcbf5204 100644 --- a/setup.py +++ b/setup.py @@ -132,7 +132,7 @@ else: domain + '.js')) for js_file, (locale, po_file) in zip(js_files, po_files): - with open(po_file, 'r') as infile: + with open(po_file) as infile: catalog = read_po(infile, locale) if catalog.fuzzy and not self.use_fuzzy: -- cgit v1.2.3