internlm/SWE-Fixer-Train-110K huggingface dataset:
Repository: zulip/zulip

Issue:
Document new help menu
We should update the help center docs to reflect the new dedicated help menu. Known pages to update:

- https://zulip.com/help/keyboard-shortcuts#keyboard-shortcuts-reference
- https://zulip.com/help/format-your-message-using-markdown#message-formatting-reference
- https://zulip.com/help/search-for-messages#search-filters-reference

We should also add a keyboard tip to /help/keyboard-shortcuts#keyboard-shortcuts-reference, documenting the `?` keyboard shortcut.


Discussion:
Hello @zulip/server-user-docs members, this issue was labeled with the "area: documentation (user)" label, so you may want to check it out!

<!-- areaLabelAddition -->


Resolving patch:
diff --git a/zerver/lib/markdown/help_relative_links.py b/zerver/lib/markdown/help_relative_links.py
--- a/zerver/lib/markdown/help_relative_links.py
+++ b/zerver/lib/markdown/help_relative_links.py
@@ -29,15 +29,6 @@
     "stats": ['<i class="fa fa-bar-chart"></i> Usage statistics', "/stats"],
     "plans": ['<i class="fa fa-rocket"></i> Plans and pricing', "/plans/"],
     "billing": ['<i class="fa fa-credit-card"></i> Billing', "/billing/"],
-    "keyboard-shortcuts": [
-        '<i class="fa fa-keyboard-o"></i> Keyboard shortcuts (?)',
-        "/#keyboard-shortcuts",
-    ],
-    "message-formatting": [
-        '<i class="fa fa-pencil"></i> Message formatting',
-        "/#message-formatting",
-    ],
-    "search-filters": ['<i class="fa fa-search"></i> Search filters', "/#search-operators"],
     "about-zulip": ["About Zulip", "/#about-zulip"],
 }
 
@@ -57,6 +48,41 @@ def gear_handle_match(key: str) -> str:
     return gear_instructions.format(item=item)
 
 
+help_info = {
+    # The pattern is key: [name, link]
+    # key is from REGEXP: `{relative|help|key}`
+    # name is what the item is called in the help menu: `Select **name**.`
+    # link is used for relative links: `Select [name](link).`
+    "keyboard-shortcuts": [
+        '<i class="zulip-icon zulip-icon-keyboard"></i> Keyboard shortcuts',
+        "/#keyboard-shortcuts",
+    ],
+    "message-formatting": [
+        '<i class="zulip-icon zulip-icon-edit"></i> Message formatting',
+        "/#message-formatting",
+    ],
+    "search-filters": [
+        '<i class="zulip-icon zulip-icon-manage-search"></i> Search filters',
+        "/#search-operators",
+    ],
+}
+
+help_instructions = """
+1. Click on the **Help menu** (<i class="zulip-icon zulip-icon-help"></i>) icon
+   in the upper right corner of the app.
+
+1. Select {item}.
+"""
+
+
+def help_handle_match(key: str) -> str:
+    if relative_help_links:
+        item = f"[{help_info[key][0]}]({help_info[key][1]})"
+    else:
+        item = f"**{help_info[key][0]}**"
+    return help_instructions.format(item=item)
+
+
 stream_info = {
     "all": ["All streams", "/#streams/all"],
     "subscribed": ["Subscribed streams", "/#streams/subscribed"],
@@ -136,6 +162,7 @@ def message_handle_match(key: str) -> str:
     "gear": gear_handle_match,
     "stream": stream_handle_match,
     "message": message_handle_match,
+    "help": help_handle_match,
 }
 
 


Test patch:
Repository: zulip/zulip

Issue:
Document option to paste URL to create a named link
We should document the new functionality in #18692.

I would add a "Via paste" tab to https://zulip.com/help/insert-a-link#insert-a-link_1, probably as the first tab, since that's often the most handy option.


Discussion:
Hello @zulip/server-user-docs members, this issue was labeled with the "area: documentation (user)" label, so you may want to check it out!

<!-- areaLabelAddition -->

@drrosa You have been unassigned from this issue because you have not made any updates for over 14 days. Please feel free to reclaim the issue if you decide to pick up again. Thanks!

@zulipbot claim

Resolving patch:
diff --git a/zerver/lib/markdown/tabbed_sections.py b/zerver/lib/markdown/tabbed_sections.py
--- a/zerver/lib/markdown/tabbed_sections.py
+++ b/zerver/lib/markdown/tabbed_sections.py
@@ -98,6 +98,7 @@
     "user": "User",
     "bot": "Bot",
     "on-sign-up": "On sign-up",
+    "via-paste": "Via paste",
     "via-markdown": "Via Markdown",
     "via-compose-box-buttons": "Via compose box buttons",
     "stream-compose": "Compose to a stream",


Test patch:
Repository: zulip/zulip

Issue:
Display mentions of cross realm bots as mention pills
<!-- Issue description -->

As reported on CZO, cross realm bots aren't being included in the data set available for rendering user mentions. As a result, their mentions don't appear as user pills. E.g., in a quote-and-reply:

![Screenshot-from-2023-07-12-12-25-44](https://github.com/zulip/zulip/assets/2090066/b86d4ed9-7e42-4022-87e2-0a2d6236b5dc)

We should fix this.

<!-- Link to a message in the chat.zulip.org discussion. Message links will still work even if the topic is renamed or resolved. Link back to this issue from the chat.zulip.org thread. -->

[CZO thread](https://chat.zulip.org/#narrow/stream/9-issues/topic/silent.20mentions.20of.20system.20bots.20in.20quote.20and.20reply/near/1608266)


Discussion:
Good Day @alya i'm an Outreachy Contributor and i'd like to fix this as my first contribution
@zulipbot claim
Welcome to Zulip, @Tochukwu-Omeja! We just sent you an invite to collaborate on this repository at https://github.com/zulip/zulip/invitations. Please accept this invite in order to claim this issue and begin a fun, rewarding experience contributing to Zulip!

Here's some tips to get you off to a good start:

- Join me on the [Zulip developers' server](https://chat.zulip.org), to get help, chat about this issue, and meet the other developers.
- [Unwatch this repository](https://help.github.com/articles/unwatching-repositories/), so that you don't get 100 emails a day.

As you work on this issue, you'll also want to refer to the [Zulip code contribution guide](https://zulip.readthedocs.io/en/latest/contributing/index.html), as well as the rest of the developer documentation on that site.

See you on the other side (that is, the pull request side)!

@Tochukwu-Omeja You have been unassigned from this issue because you have not made any updates for over 14 days. Please feel free to reclaim the issue if you decide to pick up again. Thanks!


Resolving patch:
diff --git a/zerver/lib/mention.py b/zerver/lib/mention.py
--- a/zerver/lib/mention.py
+++ b/zerver/lib/mention.py
@@ -3,6 +3,7 @@
 from dataclasses import dataclass
 from typing import Dict, List, Match, Optional, Set, Tuple
 
+from django.conf import settings
 from django.db.models import Q
 
 from zerver.models import UserGroup, UserProfile, get_linkable_streams
@@ -91,9 +92,9 @@ def get_full_name_info_list(self, user_filters: List[UserFilter]) -> List[FullNa
 
             rows = (
                 UserProfile.objects.filter(
-                    realm_id=self.realm_id,
-                    is_active=True,
+                    Q(realm_id=self.realm_id) | Q(email__in=settings.CROSS_REALM_BOT_EMAILS),
                 )
+                .filter(is_active=True)
                 .filter(
                     functools.reduce(lambda a, b: a | b, q_list),
                 )


Test patch:
Repository: zulip/zulip

Issue:
Document ability to drag-and-drop anywhere to upload a file
We should document the functionality introduced in #14579 / https://github.com/zulip/zulip/pull/26041.

I would probably replace the "Via Markdown" tab with "Via drag-and-drop", and modify the instructions to explain that you can drag anywhere, whether or not the compose box is open.


Discussion:
 @zulipbot claim
@Victoria-27 This issue cannot be claimed, as someone else is already working on it. Please see our [contributor guide](https://zulip.readthedocs.io/en/latest/overview/contributing.html#your-first-codebase-contribution) for advice on finding an issue to work on. Thanks!

@drrosa You have been unassigned from this issue because you have not made any updates for over 14 days. Please feel free to reclaim the issue if you decide to pick up again. Thanks!

@zulipbot claim
Welcome to Zulip, @thejaysharma! We just sent you an invite to collaborate on this repository at https://github.com/zulip/zulip/invitations. Please accept this invite in order to claim this issue and begin a fun, rewarding experience contributing to Zulip!

Here's some tips to get you off to a good start:

- Join me on the [Zulip developers' server](https://chat.zulip.org), to get help, chat about this issue, and meet the other developers.
- [Unwatch this repository](https://help.github.com/articles/unwatching-repositories/), so that you don't get 100 emails a day.

As you work on this issue, you'll also want to refer to the [Zulip code contribution guide](https://zulip.readthedocs.io/en/latest/contributing/index.html), as well as the rest of the developer documentation on that site.

See you on the other side (that is, the pull request side)!

@zulipbot claim

Resolving patch:
diff --git a/zerver/lib/markdown/tabbed_sections.py b/zerver/lib/markdown/tabbed_sections.py
--- a/zerver/lib/markdown/tabbed_sections.py
+++ b/zerver/lib/markdown/tabbed_sections.py
@@ -99,6 +99,7 @@
     "bot": "Bot",
     "on-sign-up": "On sign-up",
     "via-paste": "Via paste",
+    "via-drag-and-drop": "Via drag-and-drop",
     "via-markdown": "Via Markdown",
     "via-compose-box-buttons": "Via compose box buttons",
     "stream-compose": "Compose to a stream",


Test patch:
Repository: zulip/zulip

Issue:
docs: Add user guide for pin a stream



Discussion:
*Automated message from Dropbox CLA bot*

@KingxBanana, it looks like you've already signed the Dropbox CLA. Thanks!
@KingxBanana In general looks good - thanks for working on it!
Please read my comments and just think about it - I'm not native ;-)
@showell could you check the English grammar?

Additional comments - I'd change images names:
`arrow` -> `streams-arrow`
`pinX` -> `streams-something`
@TomaszKolek Alright, thanks for the tips :). I'll try to fix all of it once I get home
I checked the English grammar and didn't find anything, but we should wrap the text.
Alright, I made every line shorter than 76 characters and changed the file names of the images. Anything else?
Merged!  Thanks, @KingxBanana!

Resolving patch:
diff --git a/zerver/lib/markdown/help_relative_links.py b/zerver/lib/markdown/help_relative_links.py
--- a/zerver/lib/markdown/help_relative_links.py
+++ b/zerver/lib/markdown/help_relative_links.py
@@ -19,7 +19,7 @@
     # key is from REGEXP: `{relative|gear|key}`
     # name is what the item is called in the gear menu: `Select **name**.`
     # link is used for relative links: `Select [name](link).`
-    "manage-streams": ['<i class="fa fa-exchange"></i> Manage streams', "/#streams/subscribed"],
+    "stream-settings": ['<i class="fa fa-exchange"></i> Stream settings', "/#streams/subscribed"],
     "settings": ['<i class="fa fa-wrench"></i> Personal Settings', "/#settings/profile"],
     "organization-settings": [
         '<i class="fa fa-bolt"></i> Organization settings',
@@ -92,7 +92,7 @@ def help_handle_match(key: str) -> str:
 1. Click on the **gear** (<i class="fa fa-cog"></i>) icon in the upper
    right corner of the web or desktop app.
 
-1. Click **Manage streams**.
+1. Click **Stream settings**.
 """
 
 


Test patch:
diff --git a/docs/testing/manual-testing.md b/docs/testing/manual-testing.md
--- a/docs/testing/manual-testing.md
+++ b/docs/testing/manual-testing.md
@@ -446,7 +446,7 @@ Test subscribe/unsubscribe:
 
 - Log in as Hamlet and go to his stream settings.
 - As Cordelia, unsubscribe from "public1" using the checkmark in the
-  streams settings page.
+  stream settings page.
 - Verify that Hamlet sees that Cordelia has unsubscribed (and the
   subscriber count should decrement).
 - As Cordelia, resubscribe to "public1."
diff --git a/zerver/tests/test_docs.py b/zerver/tests/test_docs.py
--- a/zerver/tests/test_docs.py
+++ b/zerver/tests/test_docs.py
@@ -429,7 +429,7 @@ def test_help_relative_links_for_stream(self) -> None:
         with self.settings(ROOT_DOMAIN_LANDING_PAGE=True):
             result = self.client_get("/help/message-a-stream-by-email", subdomain="")
         self.assertEqual(result.status_code, 200)
-        self.assertIn("<strong>Manage streams</strong>", str(result.content))
+        self.assertIn("<strong>Stream settings</strong>", str(result.content))
         self.assertNotIn("/#streams", str(result.content))
Repository: zulip/zulip

Issue:
Document billing management, upgrade flow, and sponsorship requests
We have recently redesigned the billing management, upgrade flow, and sponsorship requests pages.

We should document:

- How to upgrade to a paid plan. (starting point: Plans and pricing option in gear menu)
- How to manage billing (starting point: Billing option in the gear menu)
- How to apply for sponsorship (starting point: Option at the top of the gear menu. The sponsorship form can be accessed form /plans if it's not in the menu, but that should be considered a secondary way to do it.)

This documentation can be added to https://zulip.com/help/zulip-cloud-billing.

Note that the options are conditional on the org's status (whether or not it's on a paid plan), and type (for whether to show the sponsorship request link in the menu; there is also special wording for education orgs). 

You can use `./manage.py populate_billing_realms` in the `dev` environment to create orgs with a bunch of different billing states for testing.



Discussion:
@drrosa It would be great if you could pick this one up as your top priority.
Hello @zulip/server-user-docs members, this issue was labeled with the "area: documentation (user)" label, so you may want to check it out!

<!-- areaLabelAddition -->


Resolving patch:
diff --git a/zerver/lib/markdown/help_relative_links.py b/zerver/lib/markdown/help_relative_links.py
--- a/zerver/lib/markdown/help_relative_links.py
+++ b/zerver/lib/markdown/help_relative_links.py
@@ -28,13 +28,13 @@
     "integrations": ['<i class="fa fa-github"></i> Integrations', "/integrations/"],
     "stats": ['<i class="fa fa-bar-chart"></i> Usage statistics', "/stats"],
     "plans": ['<i class="fa fa-rocket"></i> Plans and pricing', "/plans/"],
-    "billing": ['<i class="fa fa-credit-card"></i> Billing', "/billing/"],
+    "billing": ['<i class="zulip-icon zulip-icon-credit-card"></i> Billing', "/billing/"],
     "about-zulip": ["About Zulip", "/#about-zulip"],
 }
 
 gear_instructions = """
-1. Click on the **gear** (<i class="fa fa-cog"></i>) icon in the upper
-   right corner of the web or desktop app.
+1. Click on the **gear** (<i class="zulip-icon zulip-icon-gear"></i>) icon in
+   the upper right corner of the web or desktop app.
 
 1. Select {item}.
 """
diff --git a/zerver/lib/markdown/tabbed_sections.py b/zerver/lib/markdown/tabbed_sections.py
--- a/zerver/lib/markdown/tabbed_sections.py
+++ b/zerver/lib/markdown/tabbed_sections.py
@@ -86,6 +86,10 @@
     "via-stream-settings": "Via stream settings",
     "default-subdomain": "Default subdomain",
     "custom-subdomain": "Custom subdomain",
+    "zulip-cloud-standard": "Zulip Cloud Standard",
+    "zulip-cloud-plus": "Zulip Cloud Plus",
+    "request-sponsorship": "Request sponsorship",
+    "request-education-pricing": "Request education pricing",
     "zulip-cloud": "Zulip Cloud",
     "self-hosting": "Self hosting",
     "okta": "Okta",


Test patch:
Repository: zulip/zulip

Issue:
Onboarding hotspots are misplaced
I think our grid rewrites of the sidebars have resulted in the onboarding hotspots being somewhat misplaced:

![image](https://github.com/zulip/zulip/assets/2746074/2392e57c-63c1-4cc9-a032-1d9e3bcd10d5)

(The `offset_x` and `offset_y` values may need updating).

I'm not entirely sure where the best place for these are. The main one that seems very wrong is the compose box one.

That said, we should aim to spend pretty minimal time on this system because we plan to rip it out in favor of a totally different onboarding system.

See https://zulip.readthedocs.io/en/latest/subsystems/hotspots.html for notes on how to test using the  `ALWAYS_SEND_ALL_HOTSPOTS` setting as shown in this screenshot. (Usually, they're shown only one at a time in sequence).

@sayamsamal can you pick this one up?



Discussion:
Hello @zulip/server-onboarding members, this issue was labeled with the "area: onboarding" label, so you may want to check it out!

<!-- areaLabelAddition -->

Surely, thanks!
@zulipbot claim
Hello @aarishshahmohsin!

Thanks for your interest in Zulip! You have attempted to claim an issue without the label "help wanted". You can only claim and submit pull requests for issues with the [help wanted](https://github.com/zulip/zulip/issues?q=is%3Aopen+is%3Aissue+no%3Aassignee+label%3A%22help+wanted%22) label.

If this is your first time here, we recommend reading our [guide for new contributors](https://zulip.readthedocs.io/en/latest/overview/contributing.html) before getting started.


Resolving patch:
diff --git a/zerver/lib/hotspots.py b/zerver/lib/hotspots.py
--- a/zerver/lib/hotspots.py
+++ b/zerver/lib/hotspots.py
@@ -46,6 +46,9 @@ def to_dict(self, delay: float = 0) -> Dict[str, Union[str, float, bool]]:
         ),
     ),
     Hotspot(
+        # In theory, this should be renamed to intro_personal, since
+        # it's no longer attached to the gear menu, but renaming these
+        # requires a migration that is not worth doing at this time.
         name="intro_gear",
         title=gettext_lazy("Settings"),
         description=gettext_lazy("Go to Settings to configure your notifications and preferences."),


Test patch:
Repository: zulip/zulip

Issue:
Update Plans and pricing icon
We should update the rocket icon everywhere it shows up in the gear menu (Plans and pricing, Plan management) to:

<img width="128" alt="rocket" src="https://github.com/zulip/zulip/assets/2090066/a951bc3b-1d95-4ec5-b5a2-3cf9d1ba88f4">

![rocket](https://github.com/zulip/zulip/assets/2090066/883735c4-9a2f-49e2-a629-ba8b43d80974)


source: https://lucide.dev/icons/rocket


Discussion:
@sayamsamal Would you be available to take care of this one today?
@alya Surely, thanks!

Resolving patch:
diff --git a/zerver/lib/markdown/help_relative_links.py b/zerver/lib/markdown/help_relative_links.py
--- a/zerver/lib/markdown/help_relative_links.py
+++ b/zerver/lib/markdown/help_relative_links.py
@@ -37,7 +37,7 @@
     ],
     "stats": ['<i class="zulip-icon zulip-icon-bar-chart"></i> Usage statistics', "/stats"],
     "integrations": ['<i class="zulip-icon-git-pull-request"></i> Integrations', "/integrations/"],
-    "plans": ['<i class="fa fa-rocket"></i> Plans and pricing', "/plans/"],
+    "plans": ['<i class="zulip-icon zulip-icon-rocket"></i> Plans and pricing', "/plans/"],
     "billing": ['<i class="zulip-icon zulip-icon-credit-card"></i> Billing', "/billing/"],
     "about-zulip": ["About Zulip", "/#about-zulip"],
 }


Test patch:
Repository: zulip/zulip

Issue:
`manage.py change_user_role --help` should self-document the set of roles it supports
Right now, the only way it self-documents this is when you try an invalid role:

```
manage.py change_user_role: error: argument <new_role>: invalid choice: 'is_billing_administrator' (choose from 'owner', 'admin', 'moderator', 'member', 'guest', 'can_forge_sender', 'can_create_users', 'is_billing_admin')
```


Discussion:

Resolving patch:
diff --git a/zerver/management/commands/change_user_role.py b/zerver/management/commands/change_user_role.py
--- a/zerver/management/commands/change_user_role.py
+++ b/zerver/management/commands/change_user_role.py
@@ -13,6 +13,17 @@
 from zerver.lib.management import ZulipBaseCommand
 from zerver.models import UserProfile
 
+ROLE_CHOICES = [
+    "owner",
+    "admin",
+    "moderator",
+    "member",
+    "guest",
+    "can_forge_sender",
+    "can_create_users",
+    "is_billing_admin",
+]
+
 
 class Command(ZulipBaseCommand):
     help = """Change role of an existing user in their (own) Realm.
@@ -26,17 +37,8 @@ def add_arguments(self, parser: ArgumentParser) -> None:
         parser.add_argument(
             "new_role",
             metavar="<new_role>",
-            choices=[
-                "owner",
-                "admin",
-                "moderator",
-                "member",
-                "guest",
-                "can_forge_sender",
-                "can_create_users",
-                "is_billing_admin",
-            ],
-            help="new role of the user",
+            choices=ROLE_CHOICES,
+            help="new role of the user; choose from " + ", ".join(ROLE_CHOICES),
         )
         parser.add_argument(
             "--revoke",


Test patch:
Repository: zulip/zulip

Issue:
Document flathub option for Zulip desktop apps on Linux
See https://chat.zulip.org/#narrow/stream/19-documentation/topic/Linux.20Desktop.20App.20install.20options/near/1707537.


Discussion:
Hello @zulip/server-misc, @zulip/server-user-docs members, this issue was labeled with the "area: documentation (user)", "area: portico" labels, so you may want to check it out!

<!-- areaLabelAddition -->

@zulipbot claim

Resolving patch:
diff --git a/tools/linter_lib/custom_check.py b/tools/linter_lib/custom_check.py
--- a/tools/linter_lib/custom_check.py
+++ b/tools/linter_lib/custom_check.py
@@ -879,7 +879,7 @@
             "pattern": "[a-z][.][A-Z]",
             "description": "Likely missing space after end of sentence",
             "include_only": {"help/"},
-            "exclude_pattern": "Rocket.Chat",
+            "exclude_pattern": "Rocket.Chat|org.zulip.Zulip",
         },
         {
             "pattern": r"\b[rR]ealm[s]?\b",


Test patch:
Repository: zulip/zulip

Issue:
Improve integrations documentation in help center
We should:
- Rename /help/bots-and-integrations to "Bots overview" everywhere (sidebar, page title, page URL).
- Add a copy of https://zulip.com/api/integrations-overview as the second page in the Bots & integrations section, titled "Integration overview"
- Cross-link as appropriate, both in related articles and in the content of the pages.


Discussion:
Hello @zulip/server-api, @zulip/server-user-docs members, this issue was labeled with the "area: documentation (user)", "area: documentation (api and integrations)" labels, so you may want to check it out!

<!-- areaLabelAddition -->

@drrosa Are you up for taking care of this one? There are probably other improvements we could do, but this seems like a nice easy one.

Resolving patch:
diff --git a/zerver/lib/url_redirects.py b/zerver/lib/url_redirects.py
--- a/zerver/lib/url_redirects.py
+++ b/zerver/lib/url_redirects.py
@@ -81,6 +81,7 @@ class URLRedirect:
     URLRedirect("/help/reading-topics", "/help/reading-conversations"),
     URLRedirect("/help/finding-a-topic-to-read", "/help/finding-a-conversation-to-read"),
     URLRedirect("/help/view-and-browse-images", "/help/view-images-and-videos"),
+    URLRedirect("/help/bots-and-integrations", "/help/bots-overview"),
 ]
 
 LANDING_PAGE_REDIRECTS = [


Test patch: