git: b41d7996cdb2 - main - devel/py-zope.browserresource: Fix build with setuptools 58.0.0+
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 03 Jun 2022 14:00:26 UTC
The branch main has been updated by sunpoet:
URL: https://cgit.FreeBSD.org/ports/commit/?id=b41d7996cdb248cd014877486b51e09cc68373f4
commit b41d7996cdb248cd014877486b51e09cc68373f4
Author: Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2022-06-03 13:56:24 +0000
Commit: Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2022-06-03 13:59:05 +0000
devel/py-zope.browserresource: Fix build with setuptools 58.0.0+
With hat: python
---
devel/py-zope.browserresource/files/patch-2to3 | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/devel/py-zope.browserresource/files/patch-2to3 b/devel/py-zope.browserresource/files/patch-2to3
new file mode 100644
index 000000000000..9c237afe883f
--- /dev/null
+++ b/devel/py-zope.browserresource/files/patch-2to3
@@ -0,0 +1,20 @@
+--- src/zope/browserresource/file.py.orig 2009-08-25 05:54:46 UTC
++++ src/zope/browserresource/file.py
+@@ -164,14 +164,14 @@ class FileResource(BrowserView, Resource):
+ # understand the screwy date string as a lucky side effect
+ # of the way they parse it).
+ try:
+- mod_since = long(mktime_tz(parsedate_tz(header)))
++ mod_since = int(mktime_tz(parsedate_tz(header)))
+ except:
+ mod_since = None
+ if mod_since is not None:
+ if getattr(file, 'lmt', None):
+- last_mod = long(file.lmt)
++ last_mod = int(file.lmt)
+ else:
+- last_mod = 0L
++ last_mod = 0
+ if last_mod > 0 and last_mod <= mod_since:
+ response.setStatus(304)
+ return ''