File: 0001-Remove-post-install-plugin-cache-regeneration.patch

package info (click to toggle)
python-axiom 0.7.5-2
  • links: PTS, VCS
  • area: main
  • in suites: buster, stretch
  • size: 1,336 kB
  • ctags: 2,893
  • sloc: python: 12,583; sh: 33; makefile: 14
file content (58 lines) | stat: -rw-r--r-- 1,569 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
From 71163374b01a6c24653d6e7fa646a9c95dfb3e23 Mon Sep 17 00:00:00 2001
From: Tristan Seligmann <mithrandi@debian.org>
Date: Sat, 10 Sep 2016 16:37:07 +0200
Subject: Remove post-install plugin cache regeneration.

This does not do anything useful during a Debian package build, and
causes some cruft to be introduced into the unpacked source.

Author: Tristan Seligmann <mithrandi@debian.org>
Forwarded: not-needed
---
 setup.py | 21 ---------------------
 1 file changed, 21 deletions(-)

diff --git a/setup.py b/setup.py
index 772fa0e..283dac0 100644
--- a/setup.py
+++ b/setup.py
@@ -1,5 +1,4 @@
 from setuptools import setup, find_packages
-from setuptools.command.install import install as Install
 import re
 
 versionPattern = re.compile(r"""^__version__ = ['"](.*?)['"]$""", re.M)
@@ -8,23 +7,6 @@ with open("axiom/_version.py", "rt") as f:
 
 
 
-class InstallAndRegenerate(Install):
-    def run(self):
-        """
-        Runs the usual install logic, then regenerates the plugin cache.
-        """
-        Install.run(self)
-        _regenerateCache()
-
-
-
-def _regenerateCache():
-    from twisted import plugin
-    from axiom import plugins
-    list(plugin.getPlugins(plugin.IPlugin)) # Twisted
-    list(plugin.getPlugins(plugin.IPlugin, plugins)) # Axiom
-
-
 setup(
     name="Axiom",
     version=version,
@@ -40,9 +22,6 @@ setup(
     ],
     packages=find_packages() + ['twisted.plugins'],
     scripts=['bin/axiomatic'],
-    cmdclass={
-        "install": InstallAndRegenerate,
-    },
     include_package_data=True,
 
     license="MIT",