File tree Expand file tree Collapse file tree 4 files changed +14
-5
lines changed
Expand file tree Collapse file tree 4 files changed +14
-5
lines changed Original file line number Diff line number Diff line change 1313
1414import bitcoin .core
1515
16+ # Note that setup.py can break if __init__.py imports any external
17+ # dependencies, as these might not be installed when setup.py runs. In this
18+ # case __version__ could be moved to a separate version.py and imported here.
19+ __version__ = '0.4.1.dev0'
20+
1621class MainParams (bitcoin .core .CoreMainParams ):
1722 MESSAGE_START = b'\xf9 \xbe \xb4 \xd9 '
1823 DEFAULT_PORT = 8333
Original file line number Diff line number Diff line change @@ -121,7 +121,8 @@ def __init__(self, protover=PROTO_VERSION):
121121 self .addrTo = CAddress (PROTO_VERSION )
122122 self .addrFrom = CAddress (PROTO_VERSION )
123123 self .nNonce = random .getrandbits (64 )
124- self .strSubVer = b'/python-bitcoin-0.0.1/'
124+ self .strSubVer = (b'/python-bitcoinlib:' +
125+ bitcoin .__version__ .encode ('ascii' ) + b'/' )
125126 self .nStartingHeight = - 1
126127
127128 @classmethod
Original file line number Diff line number Diff line change 1212# serve to show the default.
1313
1414PROJECT = 'python-bitcoinlib'
15- VERSION = '0.4.0'
1615DESCRIPTION = 'The Swiss Army Knife of the Bitcoin protocol.'
1716AUTHORS = 'The python-bitcoinlib developers'
1817
2524# documentation root, use os.path.abspath to make it absolute, like shown here.
2625sys .path .insert (0 , os .path .abspath ('..' ))
2726
27+ from bitcoin import __version__
28+
2829# Prevent loading openssl when generating API docs. Either the whole library or
2930# the necessary elliptic curve might not be available, causing import to fail.
3031try :
6667# built documents.
6768#
6869# The short X.Y version.
69- version = VERSION
70+ version = __version__
7071# The full version, including alpha/beta/rc tags.
71- release = VERSION
72+ release = __version__
7273
7374# The language for content autogenerated by Sphinx. Refer to documentation
7475# for a list of supported languages.
Original file line number Diff line number Diff line change 33from setuptools import setup , find_packages
44import os
55
6+ from bitcoin import __version__
7+
68here = os .path .abspath (os .path .dirname (__file__ ))
79with open (os .path .join (here , 'README' )) as f :
810 README = f .read ()
911
1012requires = []
1113
1214setup (name = 'python-bitcoinlib' ,
13- version = '0.4.1-SNAPSHOT' ,
15+ version = __version__ ,
1416 description = 'The Swiss Army Knife of the Bitcoin protocol.' ,
1517 long_description = README ,
1618 classifiers = [
You can’t perform that action at this time.
0 commit comments