Skip to content

[MM-67856] docs: add /mobile-logs slash command#8913

Open
Willyfrog wants to merge 2 commits intomasterfrom
attach_logs
Open

[MM-67856] docs: add /mobile-logs slash command#8913
Willyfrog wants to merge 2 commits intomasterfrom
attach_logs

Conversation

@Willyfrog
Copy link
Copy Markdown
Contributor

@Willyfrog Willyfrog commented Apr 20, 2026

Summary

Document the new /mobile-logs command introduced in mattermost/mattermost#35658, which toggles the attach_app_logs preference to enable attaching mobile app logs as a file in the Mattermost mobile client (v2.38+) for debugging.

Ticket Link

MM-67856

Document the new /mobile-logs command introduced in mattermost/mattermost#35658,
which toggles the attach_app_logs preference to enable attaching mobile app
logs as a file in the Mattermost mobile client (v2.38+) for debugging.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@Willyfrog Willyfrog self-assigned this Apr 20, 2026
Copilot AI review requested due to automatic review settings April 20, 2026 11:41
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Apr 20, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 44e1b8fc-8211-4b19-a795-0b3260163575

📥 Commits

Reviewing files that changed from the base of the PR and between 9b0c077 and 1bb1663.

📒 Files selected for processing (1)
  • source/integrations-guide/built-in-slash-commands.rst
✅ Files skipped from review due to trivial changes (1)
  • source/integrations-guide/built-in-slash-commands.rst

📝 Walkthrough

Walkthrough

Documentation added a /mobile-logs built-in slash command describing on, off, and status variants, admin-targeting via @username, ephemeral responses, Mattermost mobile app v2.38+ UI requirement, and audit logging of preference changes.

Changes

Cohort / File(s) Summary
Documentation: Slash Command Reference
source/integrations-guide/built-in-slash-commands.rst
Added subsection for the /mobile-logs command: syntax (on, off, status), admin targeting (/mobile-logs on @username``), ephemeral responses, requirement note for mobile app v2.38+ UI, behavior for non-admin targeting, and audit log recording.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically describes the main change: adding documentation for the /mobile-logs slash command, which aligns directly with the changeset.
Description check ✅ Passed The description is directly related to the changeset, providing context about the /mobile-logs command, its purpose, and relevant ticket information.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch attach_logs

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (3)
source/integrations-guide/built-in-slash-commands.rst (3)

73-75: Consider elevating this note to important severity.

This block documents permission constraints (non-admin limitations), security behaviour (username enumeration protection), and audit logging requirements. According to the coding guidelines, content describing "prerequisites, constraints, or high-impact information that materially affects correctness, supportability, compliance, or success" should use the important admonition rather than note.

⚡ Suggested admonition change
-.. note::
+.. important::
 
     Non-admin users can only manage their own preference. Attempts to target another account return a neutral *Unable to change mobile log settings for that user* message to avoid username enumeration. Preference changes made through this command are recorded in the audit log.

As per coding guidelines, "Use important admonition for prerequisites, constraints, or high-impact information that materially affects correctness, supportability, compliance, or success."

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@source/integrations-guide/built-in-slash-commands.rst` around lines 73 - 75,
The current admonition uses ".. note::" to describe permission constraints,
security behavior, and audit logging; change this to an ".. important::"
admonition so the content is elevated per guidelines. Locate the block that
begins with ".. note::" and the paragraph "Non-admin users can only manage their
own preference..." and replace the directive with ".. important::" leaving the
body text unchanged so the elevated severity correctly signals
prerequisites/constraints, username enumeration protection, and audit logging
requirements.

75-75: Consider consistent formatting for the error message text.

The error message uses italics (*...*), which is valid but differs from typical documentation patterns for UI text or system messages. Consider using quotation marks alone or quotation marks with bold for consistency with how UI labels are typically formatted.

✍️ Alternative formatting options

Option 1: Plain quoted text

-Attempts to target another account return a neutral *Unable to change mobile log settings for that user* message to avoid username enumeration.
+Attempts to target another account return a neutral "Unable to change mobile log settings for that user" message to avoid username enumeration.

Option 2: Bold text (if treating as UI element)

-Attempts to target another account return a neutral *Unable to change mobile log settings for that user* message to avoid username enumeration.
+Attempts to target another account return a neutral **Unable to change mobile log settings for that user** message to avoid username enumeration.

As per coding guidelines, "Use bold for UI labels and short lead-ins."

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@source/integrations-guide/built-in-slash-commands.rst` at line 75, The
sentence uses Markdown/RST italics markup for the error message (*Unable to
change mobile log settings for that user*); update the formatting to follow the
guideline (use bold for UI labels/short messages) by replacing the italics with
bold markup (e.g., **Unable to change mobile log settings for that user**) or,
if preferred, plain quoted text ("Unable to change mobile log settings for that
user"); locate the exact message text and change the surrounding markup
accordingly in the built-in slash command documentation entry.

62-62: Consider clarifying "to the message being sent" for precision.

The phrase "attach their mobile app logs as a file to the message being sent" could be more precise. The definite article "the" suggests a specific message, but the feature applies to any message the user sends.

Consider rewording for clarity:

✍️ Suggested rewording
-Use ``/mobile-logs`` to enable an attachment option in the Mattermost mobile client that lets users attach their mobile app logs as a file to the message being sent. This helps administrators and support engineers debug mobile-specific issues by providing device-side context that isn't available from server logs alone. The command updates the ``attach_app_logs`` advanced preference and always responds with an ephemeral message visible only to the invoking user.
+Use ``/mobile-logs`` to enable an attachment option in the Mattermost mobile client that lets users attach their mobile app logs as a file when sending messages. This helps administrators and support engineers debug mobile-specific issues by providing device-side context that isn't available from server logs alone. The command updates the ``attach_app_logs`` advanced preference and always responds with an ephemeral message visible only to the invoking user.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@source/integrations-guide/built-in-slash-commands.rst` at line 62, Reword the
sentence describing the /mobile-logs command to remove the ambiguous "the
message being sent" and clarify that it enables an attachment option for any
message the user sends; update the text around the command name ``/mobile-logs``
and the preference ``attach_app_logs`` to read something like "lets users attach
their mobile app logs as a file to any message they send" and keep the rest of
the description (advanced preference update and ephemeral response) intact.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@source/integrations-guide/built-in-slash-commands.rst`:
- Around line 73-75: The current admonition uses ".. note::" to describe
permission constraints, security behavior, and audit logging; change this to an
".. important::" admonition so the content is elevated per guidelines. Locate
the block that begins with ".. note::" and the paragraph "Non-admin users can
only manage their own preference..." and replace the directive with "..
important::" leaving the body text unchanged so the elevated severity correctly
signals prerequisites/constraints, username enumeration protection, and audit
logging requirements.
- Line 75: The sentence uses Markdown/RST italics markup for the error message
(*Unable to change mobile log settings for that user*); update the formatting to
follow the guideline (use bold for UI labels/short messages) by replacing the
italics with bold markup (e.g., **Unable to change mobile log settings for that
user**) or, if preferred, plain quoted text ("Unable to change mobile log
settings for that user"); locate the exact message text and change the
surrounding markup accordingly in the built-in slash command documentation
entry.
- Line 62: Reword the sentence describing the /mobile-logs command to remove the
ambiguous "the message being sent" and clarify that it enables an attachment
option for any message the user sends; update the text around the command name
``/mobile-logs`` and the preference ``attach_app_logs`` to read something like
"lets users attach their mobile app logs as a file to any message they send" and
keep the rest of the description (advanced preference update and ephemeral
response) intact.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: e686e2c6-9094-400a-a548-95524e760450

📥 Commits

Reviewing files that changed from the base of the PR and between 5982575 and 9b0c077.

📒 Files selected for processing (1)
  • source/integrations-guide/built-in-slash-commands.rst

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds end-user documentation for the new built-in /mobile-logs slash command, which toggles attaching mobile app logs to messages for debugging in the Mattermost mobile app.

Changes:

  • Documented the /mobile-logs command purpose and behavior.
  • Added usage examples for on, off, and status (including admin targeting).
  • Noted minimum supported mobile app version and non-admin behavior.

Comment thread source/integrations-guide/built-in-slash-commands.rst Outdated
@github-actions
Copy link
Copy Markdown
Contributor

Newest code from mattermost has been published to preview environment for Git SHA 9b0c077

1 similar comment
@github-actions
Copy link
Copy Markdown
Contributor

Newest code from mattermost has been published to preview environment for Git SHA 9b0c077

- Elevate security/audit note to .. important::
- Use bold instead of italics for the error message
- Clarify the attachment applies to any message the user sends

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown
Contributor

Newest code from mattermost has been published to preview environment for Git SHA 1bb1663

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants