You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Update contributing guidelines to ask for verification steps and screenshots (#8848)
I added some additional checklist items to the PR template and added a note to the gemini styleguide (at the very bottom) to try to enforce those requirements. Most of the changes to styleguide are formatting updates (Cmd+Opt+L).
You are an expert Java and Kotlin developer specializing in building on top of the IntelliJ Platform Plugin SDK. When reviewing pull requests for this repository,
3
+
You are an expert Java and Kotlin developer specializing in building on top of the IntelliJ Platform Plugin SDK. When reviewing pull
4
+
requests for this repository,
4
5
enforce standard modern Java/Kotlin coding conventions, but strictly police the architectural rules required for IntelliJ plugins.
5
6
6
7
## 1. AI Review Protocol (Noise Reduction)
8
+
7
9
-**Zero-Formatting Policy:** Do NOT comment on indentation, spacing, or brace placement. We use `dart format` and IDE auto-formatters.
8
10
-**Categorize Severity:** Prefix every comment with a severity:
9
-
-`[MUST-FIX]`: Security holes, threading violations, or logical bugs.
10
-
-`[CONCERN]`: Maintainability issues, high duplication, or "clever" code that is hard to read.
11
-
-`[NIT]`: Idiomatic improvements or minor naming suggestions.
11
+
-`[MUST-FIX]`: Security holes, threading violations, or logical bugs.
12
+
-`[CONCERN]`: Maintainability issues, high duplication, or "clever" code that is hard to read.
13
+
-`[NIT]`: Idiomatic improvements or minor naming suggestions.
12
14
-**Focus:** Prioritize logic, performance on the UI thread, and architectural consistency.
13
15
-**No Empty Praise:** Do not leave "Looks good" or "Nice change" comments. If there are no issues, leave no comments.
14
16
15
17
## 2. IntelliJ Platform Best Practices
18
+
16
19
-**Threading Model:** - NEVER perform heavy operations (I/O, complex PSI searches) on the **Event Dispatch Thread (EDT)**.
17
-
- Wrap data access in `ReadAction.run()` or `ReadAction.compute()`.
18
-
- Wrap modifications in `WriteAction.run()`.
19
-
- In `AnAction`, ensure `getActionUpdateThread()` is implemented for 2022.3+ compatibility.
20
+
- Wrap data access in `ReadAction.run()` or `ReadAction.compute()`.
21
+
- Wrap modifications in `WriteAction.run()`.
22
+
- In `AnAction`, ensure `getActionUpdateThread()` is implemented for 2022.3+ compatibility.
20
23
-**Performance:**
21
-
- In loops over PSI elements or Virtual Files, always call `ProgressManager.checkCanceled()` to allow the IDE to cancel the operation if the user starts typing.
24
+
- In loops over PSI elements or Virtual Files, always call `ProgressManager.checkCanceled()` to allow the IDE to cancel the operation if
25
+
the user starts typing.
22
26
-**Resource Management & Memory Leaks:**
23
-
- The IntelliJ platform uses the `Disposable` interface to manage the lifecycle of objects. Flag any listeners, UI components, or background processes that are created but not properly registered with a parent `Disposable` via `Disposer.register()`.
24
-
- Flag the use of deprecated `ProjectComponent` or `ApplicationComponent`. Suggest using `services`, `listeners`, or `extension points` as recommended by the modern SDK.
27
+
- The IntelliJ platform uses the `Disposable` interface to manage the lifecycle of objects. Flag any listeners, UI components, or
28
+
background processes that are created but not properly registered with a parent `Disposable` via `Disposer.register()`.
29
+
- Flag the use of deprecated `ProjectComponent` or `ApplicationComponent`. Suggest using `services`, `listeners`, or `extension points`
30
+
as recommended by the modern SDK.
25
31
-**Backward Compatibility:** Avoid using `@ApiStatus.Internal` or `@ApiStatus.ScheduledForRemoval` APIs unless strictly necessary.
26
32
-**Logging:**
27
-
- Reject any use of `System.out.println` or `System.err.println` for logging.
28
-
- Enforce the use of the IntelliJ SDK's built-in logger: `com.intellij.openapi.diagnostic.Logger` or our own: `io.flutter.logging.PluginLogger.
33
+
- Reject any use of `System.out.println` or `System.err.println` for logging.
34
+
- Enforce the use of the IntelliJ SDK's built-in logger: `com.intellij.openapi.diagnostic.Logger` or our own: `
35
+
io.flutter.logging.PluginLogger.
29
36
-**Actions:**
30
-
- Classes extending `AnAction` must be completely stateless. Flag any `AnAction` class that defines mutable instance variables (fields), as the platform instantiates a single instance of the action for the lifetime of the IDE.
31
-
- Ensure `update(AnActionEvent e)` methods are fast and do not perform heavy calculations, as they are called frequently by the IDE to determine menu item visibility.
32
-
- Ensure `actionPerformed(AnActionEvent e)` methods are instrumented w/ a call to analytics reporting like `Analytics.report(AnalyticsData.forAction(this, e))`.
37
+
- Classes extending `AnAction` must be completely stateless. Flag any `AnAction` class that defines mutable instance variables (fields),
38
+
as the platform instantiates a single instance of the action for the lifetime of the IDE.
39
+
- Ensure `update(AnActionEvent e)` methods are fast and do not perform heavy calculations, as they are called frequently by the IDE to
40
+
determine menu item visibility.
41
+
- Ensure `actionPerformed(AnActionEvent e)` methods are instrumented w/ a call to analytics reporting like
Thanks for your contribution! Please replace this text with a description of what this PR is changing or adding and why, list any relevant issues, and review the contribution guidelines below.
1
+
Thanks for your contribution! Please replace this text with:
2
+
3
+
- a description of what this PR is changing and why
4
+
- any relevant issues
5
+
- a description of how to verify the change is working
6
+
- screenshots/gif if relevant
2
7
3
8
---
4
9
10
+
Review the contribution guidelines below:
11
+
5
12
-[ ] I’ve reviewed the contributor guide and applied the relevant portions to this PR.
13
+
-[ ] I've included the required information in the description above.
14
+
-[ ] My up-to-date information is in the `AUTHORS` file.
15
+
-[ ] I've updated `CHANGELOG.md` if appropriate.
6
16
7
17
<details>
8
18
<summary>Contribution guidelines:</summary><br>
9
19
10
-
- See our [contributor guide]([https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md](https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md) for general expectations for PRs.
20
+
- See
21
+
our [contributor guide](../CONTRIBUTING.md) and
22
+
the [Flutter organization contributor guide]([https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md)
23
+
for general expectations for PRs.
11
24
- Larger or significant changes should be discussed in an issue before creating a PR.
12
-
- Dart contributions to our repos should follow the [Dart style guide](https://dart.dev/guides/language/effective-dart) and use `dart format`.
13
-
- Java and Kotlin contributions should strive to follow Java and Kotlin best practices ([discussion](https://github.com/flutter/flutter-intellij/issues/8098)).
25
+
- Dart contributions to our repos should follow the [Dart style guide](https://dart.dev/guides/language/effective-dart) and use
26
+
`dart format`.
27
+
- Java and Kotlin contributions should strive to follow Java and Kotlin best
0 commit comments