Skip to content

Commit a7eec04

Browse files
crvvjettify
authored andcommitted
remove basic example in README.rst (#348)
1 parent 6cc678c commit a7eec04

File tree

1 file changed

+1
-23
lines changed

1 file changed

+1
-23
lines changed

README.rst

Lines changed: 1 addition & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ Mailing List
3535
https://groups.google.com/forum/#!forum/aio-libs
3636

3737

38-
Basic Example
38+
Basic
3939
-------------
4040

4141
**aiomysql** based on PyMySQL_ , and provides same api, you just need
@@ -46,28 +46,6 @@ Properties are unchanged, so ``conn.prop`` is correct as well as
4646
``conn.prop = val``.
4747

4848

49-
.. code:: python
50-
51-
import asyncio
52-
from aiomysql import create_pool
53-
54-
55-
loop = asyncio.get_event_loop()
56-
57-
async def go():
58-
async with create_pool(host='127.0.0.1', port=3306,
59-
user='root', password='',
60-
db='mysql', loop=loop) as pool:
61-
async with pool.get() as conn:
62-
async with conn.cursor() as cur:
63-
await cur.execute("SELECT 42;")
64-
value = await cur.fetchone()
65-
print(value)
66-
67-
68-
loop.run_until_complete(go())
69-
70-
7149
Connection Pool
7250
---------------
7351
Connection pooling ported from aiopg_ :

0 commit comments

Comments
 (0)