From 4146cd81abc6344f2f606ce33b13719e990eb961 Mon Sep 17 00:00:00 2001 From: Ronald Oussoren Date: Tue, 24 May 2022 17:59:08 +0200 Subject: [PATCH] Fix bad metadata --- doc/changelog.rst | 5 +++++ setup.py | 13 +++++++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/doc/changelog.rst b/doc/changelog.rst index 9e38532..8b4ab7a 100644 --- a/doc/changelog.rst +++ b/doc/changelog.rst @@ -1,6 +1,11 @@ Release history =============== +py2app 0.28.2 +------------- + +* Fix incompatibility with recent setuptools + py2app 0.28.1 ------------- diff --git a/setup.py b/setup.py index 07e2a60..5c6c449 100644 --- a/setup.py +++ b/setup.py @@ -119,7 +119,13 @@ def run(self): egg_info.egg_info.run(self) path = os.path.join(self.egg_info, "PKG-INFO") - with open(path, "a+") as fp: + with open(path) as fp: + contents = fp.read() + + first, middle, last = contents.partition("\n\n") + + with open(path, "w") as fp: + fp.write(first) fp.write( "Project-URL: Documentation, " "https://py2app.readthedocs.io/en/latest/\n" @@ -131,6 +137,9 @@ def run(self): fp.write( "Project-URL: Repository, " "https://github.com/ronaldoussoren/py2app\n" ) + fp.write(middle) + fp.write(last) + class test(Command): @@ -275,7 +284,7 @@ def run(self): setup( # metadata name="py2app", - version="0.28.1", + version="0.28.2", description="Create standalone Mac OS X applications with Python", # author='Bob Ippolito', # author_email='bob@redivi.com',