How do I get the current version of my python Tornado Module Version?
With other packages I can do the following:
print <modulename>.__version__
How do I get the current version of my python Tornado Module Version?
With other packages I can do the following:
print <modulename>.__version__
With no reference, or reason I tried the following:
which seems to do the trick.
Tornado has both
tornado.version
, which is a string for human consumption (currently "4.2"), andtornado.version_info
, which is a numeric tuple that is better for programmatic comparisons (currently(4, 2, 0, 0)
). The fourth value ofversion_info
will be negative for betas and other pre-releases.If using Ubuntu open terminal type
python ,
thenimport tornado
, the write commandtornado.version
and u will get output like'4.2.1'