-
Notifications
You must be signed in to change notification settings - Fork 32
🎨🔨 AI-assisted workflow for user-facing messages #7345
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
🎨🔨 AI-assisted workflow for user-facing messages #7345
Conversation
11473b4 to
eb7bf18
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #7345 +/- ##
==========================================
- Coverage 88.03% 87.83% -0.20%
==========================================
Files 1845 1448 -397
Lines 71206 59882 -11324
Branches 1220 673 -547
==========================================
- Hits 62685 52597 -10088
+ Misses 8169 7061 -1108
+ Partials 352 224 -128
Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
eb7bf18 to
233a2f4
Compare
233a2f4 to
20e2170
Compare
20e2170 to
105df9d
Compare
|
…s exception handlers
…age function with versioning support
…versioning support
…port for improved clarity
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR standardizes user-facing strings by wrapping them in a user_message call (with version tracking) and provides guidance for maintaining these messages.
- Wraps existing error and status messages in
user_messagefor AI-assisted updates. - Introduces a prompt file and human-readable guidelines for consistent message updates.
- Adds basic tests and the
user_messageimplementation to support this workflow.
Reviewed Changes
Copilot reviewed 20 out of 23 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| services/web/server/src/simcore_service_webserver/tasks/_exception_handlers.py | Replaced literal messages with user_message(..., _version=1). |
| services/web/server/src/simcore_service_webserver/tags/_rest.py | Wrapped tag-related errors in user_message. |
| services/web/server/src/simcore_service_webserver/projects/_controller/trash_rest.py | Wrapped trash errors in user_message. |
| services/web/server/src/simcore_service_webserver/projects/_controller/_rest_exceptions.py | Wrapped folder/node errors with user_message. |
| services/web/server/src/simcore_service_webserver/products/_controller/rest_exceptions.py | Wrapped product errors with user_message. |
| services/web/server/src/simcore_service_webserver/licenses/_common/exceptions_handlers.py | Wrapped license errors with user_message. |
| services/web/server/src/simcore_service_webserver/groups/_common/exceptions_handlers.py | Wrapped group errors with user_message. |
| services/web/server/src/simcore_service_webserver/folders/_common/exceptions_handlers.py | Wrapped folder/workspace errors with user_message. |
| services/web/server/src/simcore_service_webserver/director_v2/_controller/_rest_exceptions.py | Wrapped director_v2 errors with user_message. |
| services/web/server/src/simcore_service_webserver/constants.py | Converted default retry message to user_message. |
| services/web/server/src/simcore_service_webserver/catalog/_controller_rest_exceptions.py | Wrapped catalog errors with user_message. |
| services/web/server/src/simcore_service_webserver/api_keys/_controller/rest_exceptions.py | Wrapped API key errors with user_message. |
| packages/service-library/src/servicelib/aiohttp/rest_middlewares.py | Converted internal error template to user_message. |
| packages/common-library/tests/test_user_messages.py | Added a basic test for user_message. |
| packages/common-library/tests/test_errors_classes.py | Extended tests for error factory functions. |
| packages/common-library/src/common_library/user_messages.py | Introduced user_message function. |
| packages/common-library/src/common_library/errors_classes.py | Added resource-based error factory definitions. |
| docs/user-messages-guidelines.md | Updated guidelines to focus on user-facing messages. |
| .github/prompts/update-user-messages.prompt.md | New Copilot prompt for updating user messages. |
| .github/copilot-instructions.md | Minor link ordering adjustment. |
Comments suppressed due to low confidence (2)
services/web/server/src/simcore_service_webserver/tags/_rest.py:37
- Typo: 'insuficient' should be 'insufficient'. Also add
_version=1to this message to enable version tracking.
)
docs/user-messages-guidelines.md:3
- [nitpick] The phrase 'error and warnings user-facing messages' is awkward; consider rephrasing to 'user-facing error and warning messages' for clarity.
These guidelines ensure that error and warnings user-facing messages are user-friendly, clear, and helpful while maintaining a professional tone. 🚀
…r handling module
odeimaiz
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
very nice 👌
sanderegg
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is looking good! but I am wondering why many of the diffs do not show any change.
services/web/server/src/simcore_service_webserver/director_v2/_controller/_rest_exceptions.py
Show resolved
Hide resolved
services/web/server/src/simcore_service_webserver/groups/_common/exceptions_handlers.py
Show resolved
Hide resolved
services/web/server/src/simcore_service_webserver/licenses/_common/exceptions_handlers.py
Show resolved
Hide resolved
services/web/server/src/simcore_service_webserver/products/_controller/rest_exceptions.py
Show resolved
Hide resolved
services/web/server/src/simcore_service_webserver/projects/_controller/_rest_exceptions.py
Show resolved
Hide resolved
services/web/server/src/simcore_service_webserver/projects/_controller/trash_rest.py
Show resolved
Hide resolved
|
|
@mergify queue |
🟠 Waiting for conditions to match
|
giancarloromeo
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice thanks
…ed because of user_message function)



What do these changes do?
This PR introduces an AI-assisted workflow, using Copilot prompt customization, for generating and maintaining user-facing messages in the backend.
Key Changes
user_messagefunction to mark user-facing strings and associate them with a revision version..github/prompts/update-user-messages.prompt.mdto guide GitHub Copilot in updating these messages.docs/user-messages-guidelines.md, based on @eofli's recommendations, to ensure consistency and clarity in user messages.Example
A screenshot showing the result of running the prompt on a selected file, using Copilot prompt customization:
Notes
Related issue/s
How to test
Dev-ops checklist
NOne