forked from zulip/python-zulip-api
-
Notifications
You must be signed in to change notification settings - Fork 0
Git lint #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
LoopThrough-i-j
wants to merge
24
commits into
CI
Choose a base branch
from
git-lint
base: CI
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Git lint #1
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Tests for dropbox_share bot fails for version >= 11.0.0.
0ab22f3
to
2f99c97
Compare
The issue linked to this commit suggest suggests to replace the avatar with the username only, I just needed to remove !avatar as the code already shows the username. Fixes part of zulip#632.
Update `reaction_data` type in add_reaction and remove_reaction, from Dict[str, str] to Dict[str, Any]
This matches the current configuration in zulip/zulip.
5177377
to
3e1d9db
Compare
Changes in dropox version >= 11.0 broke the dropbox bot. The required fixes are mentioned at: https://github.com/dropbox/dropbox-sdk-python/blob/main/UPGRADING.md#upgrading-from-v10xx-to-v1100
1889390
to
4b4f6b4
Compare
- Replace virtualenv with python 3's native venv feature. The venv used is native to python3.5+, so there's no need for a separate dependency. - Remove redundant activation script. An activation script is required to use the pip and python in the virtual environment, but because we're calling the pip inside the venv, we don't need one. Fixes zulip#625.
7ceb832
to
7585161
Compare
Fixes Part of zulip#655
The `BotStorage` Protocol is created to add a common type to all storage classes. Note: Protocol is imported from `typing_extensions` as `typing` doesn't provide Protocol for python <= 3.7.
- The `BotHandler` Protocol is a mypy Protocol s.t. all BotHandlers can use it as a default type. - Fix ExternalBotHandler and StubBotHandler to follow `BotHandler` Protocol Fixes part of zulip#639
- Set `bot_handler` type to `BotHandler`. - Fix mypy issues in improperly typed variables, params and returns. Fixes part of zulip#639
The functions `extract_query_without_mention` and `is_private_message_but_not_group_pm` now accept `BotHandler` instead of `ExternalBotHandler` which allows passing objects of both `EmbeddedBotHandler` and `ExternalBotHandler`. Fixes zulip#639
mypy version 0.770 has a bug where it raises false "syntax error in type comment" warnings on Python 3.9 python/mypy#8627 It has been fixed. zulint had a bug where it raised UnicodeDecodeError while running on Windows, which has been fixed. zulip/zulint@14e3974
Tests were failing on Windows since paths are case-insensitive on it. This uses pathlib library to compare paths on all platforms. Fixes zulip#651
Set and Fetch upstream is required for gitlint, while setting up development env.
Setup gitlint for developers to write well formatted commit messages. Note: .gitlint, gitlint-rules.py and lint-commits are taken directly from zulip/zulip with minor changes.
zulint already has --skip for this. Signed-off-by: Anders Kaseorg <[email protected]>
The only thing it did over ‘tools/lint --skip=gitlint’ was redundantly run mypy again. Signed-off-by: Anders Kaseorg <[email protected]>
Signed-off-by: Anders Kaseorg <[email protected]>
Signed-off-by: Anders Kaseorg <[email protected]>
7a88dc4
to
5356304
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.