Commit Graph

269 Commits

Author SHA1 Message Date
sinwar
6f0564e9f4 python: Fix remaining bare excepts in codebase.
Fixes #2862.
2017-03-05 16:17:04 -08:00
Raghav Jajodia
a3a03bd6a5 mypy: Added Dict, List and Set imports.
Fixed mypy errors associated with the upgrade.
2017-03-04 14:33:44 -08:00
Rishi Gupta
0218422e96 Use time.time() instead of datetime.now() to measure elapsed time.
Both because it is more idiomatic and because we will soon start enforcing
that all datetimes in Zulip are timezone aware.
2017-03-01 22:54:28 -08:00
Tim Abbott
4e171ce787 lint: Clean up E126 PEP-8 rule. 2017-01-23 22:06:13 -08:00
Tim Abbott
d6e38e2a5c lint: Clean up E123 PEP-8 rule. 2017-01-23 21:34:26 -08:00
Tim Abbott
9cc83f87fc lint: Clean up E241 PEP-8 rule. 2017-01-23 21:21:14 -08:00
Tim Abbott
22d1aa396b lint: Clean up W503 PEP-8 warning. 2017-01-23 20:50:04 -08:00
JefftheBest1
ff8639f9db Fixed typos with threshold. 2017-01-12 04:50:20 -08:00
Tommy Ip
011eac1d92 bots: Fix bare except clause. 2017-01-09 00:39:33 +00:00
Tommy Ip
ada95c4fca bots: Fix bare except clause. 2017-01-08 16:25:22 -08:00
Tommy Ip
9f38277224 bots: Fix bare except clause. 2017-01-08 16:25:22 -08:00
Tim Abbott
5a51f5f9d5 bots: Move gcal-bot into official API release. 2016-12-30 12:01:31 -08:00
Tim Abbott
45324e08c1 bots: Fix jabber_mirror_backend annotations.
mypy was super confused because the name "zulip" was both an import
and a global variable in the file.
2016-12-27 21:39:32 -08:00
Steve Howell
680ff3f80c Remove mypy exemption for api/zulip/__init__.py.
This required instead exempting these files:

    bots/jabber_mirror_backend.py
    tools/deprecated/iframe-bot/show-last-messages

Turning on mypy for the API exposes issues in the annotations
of other files.
2016-12-21 11:22:42 -08:00
Tim Abbott
4cef220789 bots: Remove obsolete tddium-notify-humbug. 2016-12-15 12:16:26 -08:00
Tim Abbott
2674a3f78b bots: Remove old zulip.com configuration files. 2016-12-15 09:39:32 -08:00
reallyly
94b28e0afb pep8: Fix E128 violations.
With some line-wrapping tweaks by tabbott.
2016-12-13 10:50:14 -08:00
anirudhjain75
4bb6735e77 Annotate zephyr_mirror_backend.py.
With some tweaks by tabbott to update tuple->Tuple and update comments.
2016-12-07 15:57:55 -08:00
Tudor Nazarie
5b22959f1c Annotate bots/jabber_mirror_backend.py 2016-12-06 09:52:08 -08:00
nikolay
abc2ff4a06 pep8: Fix many rule E128 violations.
[Tweaked by tabbott to adjust some approaches used in wrapping]
2016-12-03 13:33:31 -08:00
bulat22101
a6f91064a2 pep8: Fix E129 violations 2016-12-03 10:56:36 -08:00
bulat22101
adebc75740 pep8: Fix E502 violations 2016-12-03 10:56:36 -08:00
Alex Huang
007b693cc7 pep8: Fix E131. 2016-12-01 23:16:47 -08:00
Alex Huang
c8ddea16c3 pep8: Fix E122. 2016-12-01 23:16:35 -08:00
AZtheAsian
62494eeb97 pep8: fix E201 violations 2016-12-01 23:06:02 -08:00
AZtheAsian
7e14fe65ab pep8: fix E202 violations 2016-12-01 23:06:02 -08:00
AZtheAsian
1ba150fa85 pep8: Fix E203 violations 2016-12-01 20:37:57 -08:00
Bickio
6b0df43463 pep8: Fix E125. 2016-11-30 20:03:29 -08:00
Tommy Ip
46b7d54b3e pep8: Fix E701 violations. 2016-11-30 20:45:09 +00:00
Heidi Dong
ba7d4e7452 mypy: Annotate bots/gcal-bot. 2016-11-29 20:49:11 -08:00
Rafid Aslam
41bd88d5ed pep8: Fix E301 pep8 violations.
Fix "E301: expected (1 or 2) blank line" pep8 violations.
2016-11-29 08:51:44 -08:00
Anders Kaseorg
207cf6302b Always start python via shebang lines.
This is preparation for supporting using Python 3 in production.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2016-11-26 14:46:37 -08:00
Anders Kaseorg
d1dc2cf30e Mark scripts executable
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2016-11-26 13:20:22 -08:00
Tim Abbott
37722fa650 Annotate remaining scripts. 2016-10-15 22:36:10 -07:00
reyha
34766e38c3 irc-mirror: Update the installation link.
This updates the link to python-irc to its current URL.
2016-10-10 16:23:11 -07:00
Sahil Dua
058587da77 Remove extra new lines at the ends of Zulip authoried files.
Fixes #1627.

[tweaked by tabbott to avoid patching third-party modules, for now]
2016-09-26 21:05:24 -07:00
Tim Abbott
9bccd10582 check-mirroring: Fix unnecessary type: ignore. 2016-09-12 21:43:45 -07:00
Tim Abbott
54820de522 Annotate bots/summarize_stream.py. 2016-09-11 17:09:27 -07:00
Tim Abbott
4f091fd844 Annotate irc-mirror.py. 2016-09-10 12:20:24 -07:00
Tim Abbott
de3fe38e8a Annotate bots/zulip_git_config.py. 2016-09-10 11:57:08 -07:00
Tim Abbott
d32e691fe9 Annotate check-mirroring. 2016-09-10 11:57:01 -07:00
Tim Abbott
2e2dee3396 lint: Ban lines longer than 140 characters without #ignorelongline. 2016-08-19 12:03:09 -07:00
Tim Abbott
f999f63999 zephyr_mirror_backend: Update support email address.
Arguably we should figure out a way to make this fetch the support
email from the server (or something), but in the short term it seems
worth making the email address at least correct.
2016-08-17 22:39:08 -07:00
Tim Abbott
5194485d74 log2zulip: use a Zulip virtualenv if available.
This makes it easier to use log2zulip in a Zulip server environment.
2016-08-12 13:17:36 -07:00
Tim Abbott
ac86cfcc37 Annotate zephyr_mirror.py. 2016-08-04 15:57:03 -07:00
Tim Abbott
bde3c666a9 zephyr_mirror: Add typing import. 2016-08-04 15:57:03 -07:00
Tim Abbott
552fc06844 jabber_mirror: Add missing annotation. 2016-08-04 15:57:03 -07:00
Taranjeet
a137bf15ed Wrap some lines with length greater than 120.
With some tweaks by tabbott.
2016-07-06 14:35:16 -07:00
Eklavya Sharma
94e4b39112 Replace python2.7 by python everywhere. 2016-05-29 05:03:08 -07:00
Eklavya Sharma
149938d468 Change shebangs from python2.7 to python. 2016-05-29 05:03:08 -07:00