diff options
author | Jinwei Zhao <[email protected]> | 2017-01-31 21:50:48 +0800 |
---|---|---|
committer | Jinwei Zhao <[email protected]> | 2017-02-01 21:41:54 +0800 |
commit | 9e8f476d124ae81b0434e17cd6fdb13d981e06ae (patch) | |
tree | 7ba1f752c4fea9760f591e9cde560c23fd43eb13 | |
parent | 105498f501ed48145ba21470badc7fdcddcdd10c (diff) | |
download | COMM2TG-9e8f476d124ae81b0434e17cd6fdb13d981e06ae.tar.gz |
delete useless
-rw-r--r-- | async_test.py | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/async_test.py b/async_test.py deleted file mode 100644 index 41f5cd7..0000000 --- a/async_test.py +++ /dev/null | |||
@@ -1,25 +0,0 @@ | |||
1 | ''' | ||
2 | import aiohttp | ||
3 | import asyncio | ||
4 | import async_timeout | ||
5 | |||
6 | async def fetch(session, url): | ||
7 | with async_timeout.timeout(10): | ||
8 | async with session.get(url) as response: | ||
9 | return await response.text() | ||
10 | |||
11 | async def main(loop): | ||
12 | async with aiohttp.ClientSession(loop=loop) as session: | ||
13 | html = await fetch(session, 'http://python.org') | ||
14 | print(html) | ||
15 | |||
16 | loop = asyncio.get_event_loop() | ||
17 | loop.run_until_complete(main(loop)) | ||
18 | ''' | ||
19 | |||
20 | |||
21 | import telegram | ||
22 | |||
23 | bot = telegram.Bot('243806890:AAEFw0bAA2E5hkxtprb7qGM7mZSlcevQs4Y') | ||
24 | |||
25 | bot.sendMessage(chat_id='-1001052481058', text="Hello") \ No newline at end of file | ||