Skip to content

Commit 7ec0c5e

Browse files
committed
tune
1 parent 0a108cc commit 7ec0c5e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

.github/prompts/update-user-messages.prompt.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ When modifying user messages, follow these rules:
2626
# Before modification
2727
user_message("Error: Unable to connect to the server.")
2828

29-
# After modification
30-
user_message("Error: Cannot establish connection to the server.", _version=1)
29+
# After modification, add _version or increment it if it already exists
30+
user_message("Currently unable to establish connection to the server.", _version=1)
3131
```
3232

3333
2. **F-String Preservation**: When modifying messages that use f-strings, preserve all parameters and their formatting:
@@ -66,7 +66,7 @@ When modifying user messages, follow these rules:
6666
error_dialog(user_message("Failed to save changes."))
6767

6868
# After
69-
error_dialog(user_message("Failed to save your changes. Please try again.", _version=1))
69+
error_dialog(user_message("Unable to save your changes. Please try again.", _version=1))
7070
```
7171

7272
### Example 2: F-string Message Update
@@ -76,7 +76,7 @@ error_dialog(user_message("Failed to save your changes. Please try again.", _ver
7676
raise ValueError(user_message(f"Invalid input parameter: {param_name}"))
7777

7878
# After
79-
raise ValueError(user_message(f"The parameter '{param_name}' contains an invalid value.", _version=1))
79+
raise ValueError(user_message(f"The parameter '{param_name}' contains a value that is not allowed.", _version=1))
8080
```
8181

8282
### Example 3: Already Versioned Message

0 commit comments

Comments
 (0)