071ca9e161d0422ebae2c3cd311bbacad73cc371
[platform/upstream/gpgme.git] / lang / python / doc / rst / short-history.rst
1 Overview
2 ========
3
4 +-----------------+------------------------------------------+
5 | Version:        | 0.0.1                                    |
6 +-----------------+------------------------------------------+
7 | GPGME Version:  | 1.13.0                                   |
8 +-----------------+------------------------------------------+
9 | Author:         | Ben McGinnes <ben@gnupg.org>             |
10 +-----------------+------------------------------------------+
11 | Author GPG Key: | DB4724E6FA4286C92B4E55C4321E4E2373590E5D |
12 +-----------------+------------------------------------------+
13 | Language:       | Australian English, British English      |
14 +-----------------+------------------------------------------+
15 | xml:lang:       | en-AU, en-GB, en                         |
16 +-----------------+------------------------------------------+
17
18 The GPGME Python bindings passed through many hands and numerous phases
19 before, after a fifteen year journey, coming full circle to return to
20 the source. This is a short explanation of that journey.
21
22 .. _in-the-begining:
23
24 In the beginning
25 ----------------
26
27 In 2002 John Goerzen released PyME; Python bindings for the GPGME module
28 which utilised the current release of Python of the time and SWIG. [1]_
29 Shortly after creating it and ensuring it worked he stopped supporting
30 it, though he left his work available on his Gopher site.
31
32 Keeping the flame alive
33 -----------------------
34
35 A couple of years later the project was picked up by Igor Belyi and
36 actively developed and maintained by him from 2004 to 2008. Igor\'s
37 whereabouts at the time of this document\'s creation are unknown, but
38 the current authors do hope he is well. We\'re assuming (or hoping) that
39 life did what life does and made continuing untenable.
40
41 Passing the torch
42 -----------------
43
44 In 2014 Martin Albrecht wanted to patch a bug in the PyME code and
45 discovered the absence of Igor. Following a discussion on the PyME
46 mailing list he became the new maintainer for PyME, releasing version
47 0.9.0 in May of that year. He remains the maintainer of the original
48 PyME release in Python 2.6 and 2.7 (available via PyPI).
49
50 .. _ouroboros:
51
52 Coming full circle
53 ------------------
54
55 In 2015 Ben McGinnes approached Martin about a Python 3 version, while
56 investigating how complex a task this would be the task ended up being
57 completed. A subsequent discussion with Werner Koch led to the decision
58 to fold the Python 3 port back into the original GPGME release in the
59 languages subdirectory for non-C bindings under the module name of
60 ``pyme3``.
61
62 In 2016 this PyME module was integrated back into the GPGME project by
63 Justus Winter. During the course of this work Justus adjusted the port
64 to restore limited support for Python 2, but not as many minor point
65 releases as the original PyME package supports. During the course of
66 this integration the package was renamed to more accurately reflect its
67 status as a component of GPGME. The ``pyme3`` module was renamed to
68 ``gpg`` and adopted by the upstream GnuPG team.
69
70 In 2017 Justus departed G10code and the GnuPG team. Following this Ben
71 returned to maintain of gpgme Python bindings and continue building them
72 from that point.
73
74 .. _relics-past:
75
76 Relics of the past
77 ==================
78
79 There are a few things, in addition to code specific factors, such as
80 SWIG itself, which are worth noting here.
81
82 The Annoyances of Git
83 ---------------------
84
85 As anyone who has ever worked with git knows, submodules are horrible
86 way to deal with pretty much anything. In the interests of avoiding
87 migraines, that was skipped with addition of the PyME code to GPGME.
88
89 Instead the files were added to a subdirectory of the ``lang/``
90 directory, along with a copy of the entire git log up to that point as a
91 separate file within the ``lang/python/docs/`` directory. [2]_ As the
92 log for PyME is nearly 100KB and the log for GPGME is approximately 1MB,
93 this would cause considerable bloat, as well as some confusion, should
94 the two be merged.
95
96 Hence the unfortunate, but necessary, step to simply move the files. A
97 regular repository version has been maintained should it be possible to
98 implement this better in the future.
99
100 The Perils of PyPI
101 ------------------
102
103 The early port of the Python 2 ``pyme`` module as ``pyme3`` was never
104 added to PyPI while the focus remained on development and testing during
105 2015 and early 2016. Later in 2016, however, when Justus completed his
106 major integration work and subsequently renamed the module from
107 ``pyme3`` to ``gpg``, some prior releases were also provided through
108 PyPI.
109
110 Since these bindings require a matching release of the GPGME libraries
111 in order to function, it was determined that there was little benefit in
112 also providing a copy through PyPI since anyone obtaining the GPGME
113 source code would obtain the Python bindings source code at the same
114 time. Whereas there was the potential to sew confusion amongst Python
115 users installing the module from PyPI, only to discover that without the
116 relevant C files, header files or SWIG compiled binaries, the Python
117 module did them little good.
118
119 There are only two files on PyPI which might turn up in a search for
120 this module or a sample of its content:
121
122 #. gpg (1.8.0) - Python bindings for GPGME GnuPG cryptography library
123 #. pyme (0.9.0) - Python support for GPGME GnuPG cryptography library
124
125 .. _pypi-gpgme-180:
126
127 GPG 1·8·0 - Python bindings for GPGME GnuPG cryptography library
128 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
129
130 This is the most recent version to reach PyPI and is the version of the
131 official Pyhon bindings which shipped with GPGME 1.8.0. If you have
132 GPGME 1.8.0 installed and *only* 1.8.0 installed, then it is probably
133 safe to use this copy from PyPI.
134
135 As there have been a lot of changes since the release of GPGME 1.8.0,
136 the GnuPG Project recommends not using this version of the module and
137 instead installing the current version of GPGME along with the Python
138 bindings included with that package.
139
140 .. _pypi-gpgme-90:
141
142 PyME 0·9·0 - Python support for GPGME GnuPG cryptography library
143 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
144
145 This is the last release of the PyME bindings maintained by Martin
146 Albrecht and is only compatible with Python 2, it will not work with
147 Python 3. This is the version of the software from which the port from
148 Python 2 to Python 3 code was made in 2015.
149
150 Users of the more recent Python bindings will recognise numerous points
151 of similarity, but also significant differences. It is likely that the
152 more recent official bindings will feel \"more pythonic.\"
153
154 For those using Python 2, there is essentially no harm in using this
155 module, but it may lack a number of more recent features added to GPGME.
156
157 Footnotes
158 =========
159
160 .. [1]
161    In all likelihood this would have been Python 2.2 or possibly Python
162    2.3.
163
164 .. [2]
165    The entire PyME git log and other preceding VCS logs are located in
166    the ``gpgme/lang/python/docs/old-commits.log`` file.