From fe2f154290762eaf4f8964b6c7833f1d782cbf50 Mon Sep 17 00:00:00 2001 From: Akshat Shrivastava Date: Mon, 18 May 2026 22:02:30 +0530 Subject: [PATCH] Update setup.py get_version() is called twice unnecessarily MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In the setup() call, get_version() is invoked twice — once for version= and once for download_url=. This means the file is opened and parsed twice, which is inefficient and fragile (if the file changes between calls, you'd get inconsistent results) --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 341bc78..7616b01 100755 --- a/setup.py +++ b/setup.py @@ -31,7 +31,7 @@ def get_version(): setup( name='datasheets', description='Read data from, write data to, and format Google Sheets from Python', - version=get_version(), + version = get_version(), author='Squarespace Data Engineering', url='https://github.com/Squarespace/datasheets', download_url='https://github.com/Squarespace/datasheets/tarball/{}'.format(get_version()),