@@ -14,39 +14,71 @@ by following the instructions at https://pip.pypa.io/en/latest/installing/.
1414Install Pyrogram
1515----------------
1616
17- - The easiest way to install and upgrade Pyrogram is by using **pip **:
17+ - The easiest way to install and upgrade Pyrogram to its latest stable version is by using **pip **:
1818
19- .. code-block :: bash
19+ .. code-block :: text
2020
2121 $ pip3 install --upgrade pyrogram
2222
23- - or, with TgCrypto _ (recommended):
23+ - or, with TgCrypto _ as extra requirement (recommended):
2424
25- .. code-block :: bash
25+ .. code-block :: text
2626
27- $ pip3 install --upgrade pyrogram[tgcrypto ]
27+ $ pip3 install --upgrade pyrogram[fast ]
2828
2929 Bleeding Edge
3030-------------
3131
3232If you want the latest development version of Pyrogram, you can install it straight from the develop _
3333branch using this command (you might need to install **git ** first):
3434
35- .. code-block :: bash
35+ .. code-block :: text
3636
3737 $ pip3 install --upgrade git+https://github.com/pyrogram/pyrogram.git
3838
39+ Asynchronous
40+ ------------
41+
42+ Pyrogram heavily depends on IO-bound network code (it's a cloud-based messaging client library after all), and here's
43+ where asyncio shines the most by providing extra performance while running on a single OS-level thread only.
44+
45+ **A fully asynchronous variant of Pyrogram is therefore available ** (Python 3.5+ required).
46+ Use this command to install:
47+
48+ .. code-block :: text
49+
50+ $ pip3 install --upgrade git+https://github.com/pyrogram/pyrogram.git@asyncio
51+
52+
53+ Pyrogram API remains the same and features are kept up to date from the non-async, default develop branch.
54+
55+
56+ .. note ::
57+
58+ The idea to turn Pyrogram fully asynchronous is still under consideration, but is wise to expect that in future this
59+ would be the one and only way to work with Pyrogram.
60+
61+ .. raw :: html
62+
63+ <script async
64+ src =" https://telegram.org/js/telegram-widget.js?4"
65+ data-telegram-post =" Pyrogram/4"
66+ data-width =" 100%" >
67+ </script >
68+
69+ .. centered :: Subscribe to `@Pyrogram <https://t.me/Pyrogram>`_ for news and announcements
70+
3971Verifying
4072---------
4173
4274To verify that Pyrogram is correctly installed, open a Python shell and import it.
4375If no error shows up you are good to go.
4476
45- .. code-block :: bash
77+ .. code-block :: python
4678
4779 >> > import pyrogram
4880 >> > pyrogram.__version__
4981 ' 0.8.0'
5082
5183 .. _TgCrypto : https://docs.pyrogram.ml/resources/TgCrypto
52- .. _develop : http://github.com/pyrogram/pyrogram
84+ .. _develop : http://github.com/pyrogram/pyrogram
0 commit comments