Skip to content

Commit c471f26

Browse files
committed
ruff: Fix ISC001 Implicitly concatenated string literals on one line.
Signed-off-by: Anders Kaseorg <[email protected]>
1 parent 2f58129 commit c471f26

File tree

13 files changed

+20
-22
lines changed

13 files changed

+20
-22
lines changed

zulip/integrations/trello/zulip_trello.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ def main() -> None:
122122
parser.add_argument(
123123
"--trello-board-id",
124124
required=True,
125-
help=("The Trello board short ID. Can usually be found " "in the URL of the Trello board."),
125+
help=("The Trello board short ID. Can usually be found in the URL of the Trello board."),
126126
)
127127
parser.add_argument(
128128
"--trello-api-key",

zulip/tests/test_default_arguments.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def test_config_path_with_tilde(self, mock_os_path_exists: bool) -> None:
4141
expanded_test_path = os.path.abspath(os.path.expanduser(test_path))
4242
self.assertEqual(
4343
str(cm.exception),
44-
"api_key or email not specified and " f"file {expanded_test_path} does not exist",
44+
f"api_key or email not specified and file {expanded_test_path} does not exist",
4545
)
4646

4747

zulip/zulip/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1395,7 +1395,7 @@ def get_subscriptions(self, request: Optional[Dict[str, Any]] = None) -> Dict[st
13951395

13961396
def list_subscriptions(self, request: Optional[Dict[str, Any]] = None) -> Dict[str, Any]:
13971397
logger.warning(
1398-
"list_subscriptions() is deprecated." " Please use get_subscriptions() instead."
1398+
"list_subscriptions() is deprecated. Please use get_subscriptions() instead."
13991399
)
14001400
return self.get_subscriptions(request)
14011401

@@ -1699,7 +1699,7 @@ def move_topic(
16991699
if message_id is None:
17001700
if propagate_mode != "change_all":
17011701
raise AttributeError(
1702-
"A message_id must be provided if " 'propagate_mode isn\'t "change_all"'
1702+
'A message_id must be provided if propagate_mode isn\'t "change_all"'
17031703
)
17041704

17051705
# ask the server for the latest message ID in the topic.

zulip_bots/zulip_bots/bots/baremetrics/baremetrics.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ def get_sources(self) -> str:
142142
response = "**Listing sources:** \n"
143143
for index, source in enumerate(sources_data):
144144
response += (
145-
"{_count}.ID: {id}\n" "Provider: {provider}\n" "Provider ID: {provider_id}\n\n"
145+
"{_count}.ID: {id}\nProvider: {provider}\nProvider ID: {provider_id}\n\n"
146146
).format(_count=index + 1, **source)
147147

148148
return response

zulip_bots/zulip_bots/bots/chessbot/chessbot.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -401,7 +401,7 @@ def make_loss_response(board: chess.Board, reason: str) -> str:
401401
402402
Returns: The loss response string.
403403
"""
404-
return ("*{}* {}. **{}** wins!\n\n" "{}").format(
404+
return ("*{}* {}. **{}** wins!\n\n{}").format(
405405
"White" if board.turn else "Black",
406406
reason,
407407
"Black" if board.turn else "White",
@@ -418,7 +418,7 @@ def make_not_legal_response(board: chess.Board, move_san: str) -> str:
418418
419419
Returns: The not-legal-move response string.
420420
"""
421-
return ("Sorry, the move *{}* isn't legal.\n\n" "{}" "\n\n\n" "{}").format(
421+
return ("Sorry, the move *{}* isn't legal.\n\n{}\n\n\n{}").format(
422422
move_san, make_str(board, board.turn), make_footer()
423423
)
424424

zulip_bots/zulip_bots/bots/giphy/giphy.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ def get_bot_giphy_response(
9696
"let's try again later! :grin:"
9797
)
9898
except GiphyNoResultException:
99-
return f'Sorry, I don\'t have a GIF for "{keyword}"! ' ":astonished:"
99+
return f'Sorry, I don\'t have a GIF for "{keyword}"! :astonished:'
100100
return (
101101
f"[Click to enlarge]({gif_url})"
102102
"[](/static/images/interactive-bot/giphy/powered-by-giphy.png)"

zulip_bots/zulip_bots/bots/merels/libraries/game.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def getInfo():
1919
2020
:return: Info on how to start the game
2121
"""
22-
return "To start a game, mention me and add `create`. A game will start " "in that topic. "
22+
return "To start a game, mention me and add `create`. A game will start in that topic. "
2323

2424

2525
def getHelp():
@@ -70,7 +70,7 @@ def beat(message, topic_name, merels_storage):
7070
p2 = [int(x) for x in match.group(3).split(",")]
7171

7272
if mechanics.get_take_status(topic_name, merels_storage) == 1:
73-
raise BadMoveException("Take is required to proceed." " Please try again.\n")
73+
raise BadMoveException("Take is required to proceed. Please try again.\n")
7474

7575
responses += mechanics.move_man(topic_name, p1, p2, merels_storage) + "\n"
7676
no_moves = after_event_checkup(responses, topic_name, merels_storage)
@@ -98,7 +98,7 @@ def beat(message, topic_name, merels_storage):
9898
responses = ""
9999

100100
if mechanics.get_take_status(topic_name, merels_storage) == 1:
101-
raise BadMoveException("Take is required to proceed." " Please try again.\n")
101+
raise BadMoveException("Take is required to proceed. Please try again.\n")
102102
responses += mechanics.put_man(topic_name, p1[0], p1[1], merels_storage) + "\n"
103103
no_moves = after_event_checkup(responses, topic_name, merels_storage)
104104

@@ -162,7 +162,7 @@ def check_any_moves(topic_name, merels_storage):
162162
"""
163163
if not mechanics.can_make_any_move(topic_name, merels_storage):
164164
mechanics.update_change_turn(topic_name, merels_storage)
165-
return "Cannot make any move on the grid. Switching to " "previous player.\n"
165+
return "Cannot make any move on the grid. Switching to previous player.\n"
166166

167167
return ""
168168

zulip_bots/zulip_bots/bots/merels/test_merels.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ def test_no_command(self):
1515
)
1616
res = self.get_response(message)
1717
self.assertEqual(
18-
res["content"], "You are not in a game at the moment." " Type `help` for help."
18+
res["content"], "You are not in a game at the moment. Type `help` for help."
1919
)
2020

2121
# FIXME: Add tests for computer moves

zulip_bots/zulip_bots/bots/monkeytestit/lib/parse.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ def execute(message: str, apikey: str) -> str:
2222
len_params = len(params)
2323

2424
if len_params < 2:
25-
return failed("You **must** provide at least an URL to perform a " "check.")
25+
return failed("You **must** provide at least an URL to perform a check.")
2626

2727
options = {
2828
"secret": apikey,
@@ -65,7 +65,7 @@ def execute(message: str, apikey: str) -> str:
6565
# the user needs to modify the asset_count. There are probably ways
6666
# to counteract this, but I think this is more fast to run.
6767
else:
68-
return "Unknown command. Available commands: `check <website> " "[params]`"
68+
return "Unknown command. Available commands: `check <website> [params]`"
6969

7070

7171
def failed(message: str) -> str:

zulip_bots/zulip_bots/bots/tictactoe/tictactoe.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -253,9 +253,7 @@ def alert_move_message(self, original_player: str, move_info: str) -> str:
253253
return f"{original_player} put a token at {move_info}"
254254

255255
def game_start_message(self) -> str:
256-
return (
257-
"Welcome to tic-tac-toe!" "To make a move, type @-mention `move <number>` or `<number>`"
258-
)
256+
return "Welcome to tic-tac-toe!To make a move, type @-mention `move <number>` or `<number>`"
259257

260258

261259
class ticTacToeHandler(GameAdapter):

0 commit comments

Comments
 (0)