Skip to content

Chore/wpb 20631 update welcome message - #53

Merged
MarianKijewski merged 3 commits into
mainfrom
chore/WPB-20631_update_welcome_message
Jan 19, 2026
Merged

MarianKijewski merged 3 commits into
mainfrom
chore/WPB-20631_update_welcome_message

Conversation

@MarianKijewski

Copy link
Copy Markdown
Contributor

PR Submission Checklist for internal contributors

  • The PR Title

    • conforms to the style of semantic commits messages¹ supported in Wire's Github Workflow²
    • contains a reference JIRA issue number like SQPIT-764
    • answers the question: If merged, this PR will: ... ³
  • The PR Description

    • is free of optional paragraphs and you have filled the relevant parts to the best of your ability

What's new in this PR?

Issues

The capabilities of the App were not clear once it's added to the conversation

Solutions

Greet, describe App's purpose and usage when added to a conversation.

Testing

Test Coverage

  • I have added automated test to this contribution

How to Test

Verify that there's a message, once an App is added to the conversation.


References
  1. https://sparkbox.com/foundry/semantic_commit_messages
  2. https://github.com/wireapp/.github#usage
  3. E.g. feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764.

@MarianKijewski
MarianKijewski requested a review from a team as a code owner January 19, 2026 08:01
@claude

claude Bot commented Jan 19, 2026

Copy link
Copy Markdown

Pull Request Review

Summary

This PR introduces a welcome message when the GitHub App is added to a conversation and updates the help command to use a more specific /github help command. The changes improve user onboarding and command clarity.


Positive Aspects

  1. Improved User Experience: The welcome message provides clear context about the app's purpose when it's added to a conversation.
  2. Better Command Naming: Using /github help instead of /help prevents command conflicts with other apps.
  3. Code Organization: Good refactoring by extracting formatSetupInstructions() from the original formatHelp() function.
  4. Proper String Building: Using buildString {} with appendLine() is idiomatic Kotlin.
  5. Consistent Logging: Maintains the existing logging pattern for event handling.

Code Quality Observations

Good Practices

  • Constants are properly extracted to companion object
  • Multi-line string constants are well-formatted
  • Function naming is descriptive and follows Kotlin conventions
  • Proper separation of concerns between welcome message and setup instructions

Minor Suggestions

  1. Emoji Consideration (Line 106-109):

    • The welcome message includes an emoji. While this adds friendliness, verify:
      • Will this render correctly on all Wire clients (desktop, mobile, web)?
      • Is emoji usage consistent with Wire's UX guidelines?
    • If there are any rendering issues, this is easy to adjust later.
  2. Message Formatting Consistency (Line 57):

    • The backticks around HELP_COMMAND in the message create markdown-style inline code formatting.
    • Verify this renders as intended in Wire messages (may appear as literal backticks).
  3. String Formatting (Line 89-98):

    • The String.format() usage is fine, but consider Kotlin's string templates for consistency.
    • However, the current approach is perfectly acceptable.

Security Considerations

No security issues identified:

  • Secret generation and storage logic remains unchanged
  • No new user input is processed
  • No new external API calls introduced
  • Redis operations are consistent with existing patterns

Potential Issues

Low Priority

  1. Empty Line Handling (Line 56):

    • appendLine() without arguments adds an empty line.
    • This is intentional for formatting, but ensure double newlines render correctly in Wire.
  2. Secret Regeneration Risk:

    • The existing code at line 76-80 generates a new secret if none exists.
    • When /github help is called, if no secret exists, a new one is generated.
    • This could theoretically change the secret if Redis data is lost, breaking existing webhooks.
    • Not introduced by this PR, but worth noting for future consideration.

Performance Considerations

No performance concerns:

  • String building operations are minimal
  • Redis operations remain unchanged
  • No additional network calls
  • Changes are synchronous and lightweight

Test Coverage

Missing Test Coverage

The PR does not include tests for the new functionality. Consider adding tests for:

  1. Welcome Message Test: Verify that onAppAddedToConversation sends a message containing WELCOME_TEXT, setup instructions, and help command reference.

  2. Help Command Test: Test that the new HELP_COMMAND constant works correctly with the updated command name.

  3. Case Insensitivity Test: Verify that ignoreCase = true works as expected for variations like /GitHub Help.

Recommendation: Add unit tests for the new welcome message flow and updated help command, similar to the existing ApplicationTest.kt structure.


Additional Recommendations

  1. Consider Adding a Constant for the Help Message Footer: This would make the message easier to maintain and update.

  2. Documentation:

    • Update README.md to mention the new /github help command instead of just /help.
    • Consider adding the welcome message format to documentation for reference.
  3. Future Enhancement:

    • Consider adding a /github status command to check webhook connection status.
    • This could help users verify their setup is working correctly.

Conclusion

Recommendation: Approve with minor suggestions

This is a solid PR that improves the user experience without introducing bugs or security issues. The code quality is good, follows Kotlin conventions, and aligns with the existing codebase structure.

Key Strengths:

  • Clear improvement to UX
  • Good refactoring
  • No breaking changes
  • Safe changes with minimal risk

Areas for Improvement (Non-blocking):

  • Add test coverage for the new functionality
  • Verify message rendering in Wire clients
  • Update documentation

The changes are production-ready, and the test coverage gap can be addressed in a follow-up PR if needed.


Reviewed by: Claude (Automated Code Review)
Review Date: 2026-01-19

@MarianKijewski

Copy link
Copy Markdown
Contributor Author
image

@MarianKijewski
MarianKijewski merged commit 7380cd1 into main Jan 19, 2026
5 checks passed
@MarianKijewski
MarianKijewski deleted the chore/WPB-20631_update_welcome_message branch January 19, 2026 08:53
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