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
@@ -61,90 +61,131 @@ If commits do not follow the above guidelines, we may request that you modify th
61
61
62
62
[How We Release Arm Mbed OS](../introduction/how-we-release-arm-mbed-os.html) explains Mbed OS versioning.
63
63
64
-
## Pull request types
64
+
## Pull request template
65
65
66
-
We consider the following pull request types.
66
+
The following template is automatically provided when you raise a pull request against `mbed-os`. The details required depend on the type of pull request you create:
67
67
68
-
### Fix
68
+
### Description (*required*)
69
69
70
-
A bug fix is a change that fixes a specific defect in the codebase with backward compatibility. These are the highest priority because of the positive effect the change will have on users developing against the same code. A bug fix should be limited to restoring the documented or proven otherwise, originally intended behavior. Every bug fix should contain a test to verify results before and after the pull request. Bug fixes are candidates for patch releases. Large, nontrivial bug fixes approaching the size of refactors run the risk of being considered refactors themselves.
70
+
##### Summary of change (*What the change is for and why*)
71
71
72
-
Release: patch
73
72
74
-
###Refactor
73
+
##### Documentation (*Details of any document updates required*)
75
74
76
-
A refactor is a contribution that modifies the codebase without fixing a bug or changing the existing behavior. Examples of this are moving functions or variables between translation units, renaming source files or folders, scope modification for nonpublic code, documentation structure changes and test organization changes. There is always the risk that someone depended on the location or name before a refactor; therefore, these are lower in priority than bug fixes and might require detailed justification for the change. Refactors are candidates for feature releases.
A test report for the new target must be part of the pull request. The new target must pass all Mbed OS functional and system validation tests (using `mbed test` command) for the current Mbed OS major release, including all Mbed OS supported toolchains.
86
+
[] No Tests required for this change (E.g docs only update)
87
+
[] Covered by existing mbed-os tests (Greentea or Unittest)
### Release Notes (*required for feature/major PRs*)
89
97
90
-
A functionality change can be any change in the functionality, including adding a new feature, a new method or a function. Software language does not matter.
91
98
92
-
A feature contribution contains a new API, capability or behavior. It does not break backward compatibility with existing APIs, capabilities or behaviors. New feature contributions are very welcome in Mbed OS. However, because they add capability to the codebase, a new feature may introduce bugs and a support burden. New features should also come with documentation, support for most targets and comprehensive test coverage. Feature PRs are treated cautiously, and new features require a new minor version for the codebase. Features are candidates for feature releases.
99
+
##### Summary of changes
93
100
94
-
Every pull request changing or adding functionality must contain a "Release notes" section describing the changes to users.
101
+
##### Impact of changes
95
102
96
-
It must contain:
103
+
##### Migration actions required
97
104
98
-
- A brief description of changes introduced, including justification.
99
-
- An analysis of effects: components affected and potential consequences for users.
100
-
- Migration guidance: actions for updating the current code. Please include code snippets to illustrate before and after the addition or change.
101
105
102
-
<spanclass="notes">**Note:** We may use this content in our official release notes.</span>
106
+
### Description field
103
107
104
-
For more details, please see the [pull request template addition for functional changes](#pull-request-template-functional-changes).
108
+
There are two parts to the description, both of which are required:
105
109
106
-
We initially implement new features on separate branches in the Mbed OS repository. Mbed OS maintainers create the new branches by following the naming convention: "feature-" prefix.
110
+
- The summary of the pull request clearly states the reason for the PR and what the changes involve.
111
+
- The documentation section requires you to state what, if any, documentation changes need to accompany the code changes.
107
112
108
-
Each feature has a tech lead. This person is responsible for:
113
+
### Pull request type
109
114
110
-
- Rebasing often to track master development.
111
-
- Reviewing any addition to the feature branch (approval required by the feature tech lead or another assigned person).
115
+
There are three pull request types, and these correspond to the three main categories specified in semantic versioning: patch, feature (minor) and major.
112
116
113
-
Release: feature
117
+
#### Patch update
114
118
115
-
### Documentation update
119
+
This can contain any of the following changes:
116
120
117
-
Documentation updates include changes to markdown files or Doxygen documentation (comment-only changes).
121
+
##### Bug Fix
122
+
123
+
A bug fix is a change that fixes a specific defect in the codebase with backward compatibility. These are the highest priority because of the positive effect the change will have on users developing against the same code. A bug fix should be limited to restoring the documented or proven otherwise, originally intended behavior. Every bug fix should contain a test to verify results before and after the pull request. Bug fixes are candidates for patch releases. Large, nontrivial bug fixes approaching the size of refactors run the risk of being considered refactors themselves.
124
+
125
+
##### Refactor
118
126
119
-
Release: patch
127
+
A refactor is a contribution that modifies the codebase without fixing a bug or changing the existing behavior. Examples of this are moving functions or variables between translation units, renaming source files or folders, scope modification for nonpublic code, documentation structure changes and test organization changes. There is always the risk that someone depended on the location or name before a refactor; therefore, these are lower in priority than bug fixes and might require detailed justification for the change.
120
128
121
-
### Test update
129
+
##### Target update
130
+
131
+
Updating target implementation (adding a new target or updating already supported target) is a change for a patch release.
132
+
133
+
A test report for the new target must be part of the pull request. The new target must pass all Mbed OS functional and system validation tests (using `mbed test` command) for the current Mbed OS major release, including all Mbed OS supported toolchains.
134
+
135
+
##### Documentation update
136
+
137
+
Documentation updates include changes to markdown files or Doxygen documentation (comment-only changes).
138
+
139
+
##### Test update
122
140
123
141
Test updates include updates to a new test unit or test case.
124
142
125
-
Release: patch
143
+
#### Feature update
126
144
127
-
### Breaking change
145
+
This can be any change in the functionality, including adding a new feature, a new method or a function. Software language does not matter.
128
146
129
-
A breaking change is any change that results in breaking user space. It should have strong justification for us to consider it. Often, such changes can be backward compatible, for example, deprecating the old functionality and introducing the new replacement.
147
+
A feature contribution contains a new API, capability or behavior. It does not break backward compatibility with existing APIs, capabilities or behaviors. New feature contributions are very welcome in Mbed OS. However, because they add capability to the codebase, a new feature may introduce bugs and a support burden. New features should also come with documentation, support for most targets and comprehensive test coverage. Feature PRs are treated cautiously, and new features require a new minor version for the codebase.
130
148
131
-
A contribution containing a breaking change is the most difficult PR to get merged. Any breaking changes in a codebase can have a large negative impact on any users of the codebase. Breaking changes are always limited to a major version release.
149
+
We initially implement new features on separate branches in the Mbed OS repository. Mbed OS maintainers or Mbed OS technical leads may create the new branches by following the naming convention: "feature-" prefix.
132
150
133
-
Every pull request with breaking change must contain a release notes section called "Release notes" to describe the changes to users.
151
+
Each feature has a Mbed OS technical lead. This person is responsible for:
134
152
135
-
It must contain:
153
+
- Rebasing often to track master development.
154
+
- Reviewing any addition to the feature branch.
155
+
- Approving all feature change pull requests.
136
156
137
-
- A brief description of changes introduced, including justification description.
138
-
- An analysis of effects: components affected, potential consequences for users.
139
-
- Migration guidance: actions for updating the current code. Please include code snippets to illustrate before and after the addition or change.
157
+
#### Major update
140
158
141
-
<spanclass="notes">**Note:** We may use this content in our official release notes.</span>
159
+
This is for breaking changes and should be rare. A breaking change is any change that results in breaking user space. It should have strong justification for us to consider it. Often, such changes can be backward compatible, for example, deprecating the old functionality and introducing the new replacement.
142
160
143
-
Please see the [Pull request template](../contributing/workflow.html#pull-request-template-breaking-changes).
161
+
A contribution containing a breaking change is the most difficult PR to get merged. Any breakingchanges in a codebase can have a large negative effect on any users of the codebase. Breaking changes are always limited to a major version release.
144
162
145
163
A project technical lead and the Mbed OS technical lead must approve breaking change pull requests.
146
164
147
-
Release: major
165
+
### Test results
166
+
167
+
This section is to indicate what test results, if any, are required for the PR. The three options are:
168
+
169
+
- No tests required for this change (for example, a documentation-only update).
170
+
- Changes will be tested by existing `mbed-os` tests (Greentea or Unittest).
171
+
- Tests and results will be supplied as part of this PR. For this option, post the tests and test results
172
+
below the tick boxes.
173
+
174
+
### Reviewers
175
+
176
+
A bot automatically adds reviewers based on the files that are actually changed. However, this section gives you the option to specify additional, specific reviewers. Tag required reviewers here, such as @adbridge, @0xc0170.
177
+
178
+
### Release Notes
179
+
180
+
Every pull request changing or adding functionality must fill in the "Release notes" section. This applies to feature and major PRs. For both these types, you must complete the "Summary of changes" section. Provide a brief description of changes introduced, including justification.
181
+
182
+
For major PRs, it is also compulsory to complete the "Impact of changes" and "Migration actions required".
183
+
184
+
The impact of changes must contain an analysis of effects: components affected and potential consequences for users.
185
+
186
+
The migration actions required should describe how to migrate from a previous version of the code being changed to the new version. Please include code snippets to illustrate before and after the addition or change.
187
+
188
+
The release notes section is automatically pulled into the overall release notes for a feature or major release. This should be considered when you write the entries.
148
189
149
190
## GitHub pull requests workflow
150
191
@@ -166,37 +207,46 @@ All pull requests must be reviewed. The Arm Mbed CI bot determines the most suit
166
207
167
208
GitHub dismisses a reviewer's status after any change to the pull request commit history (such as adding a new commit or rebasing). Smaller changes, such as documentation edits or rebases on top of latest master, only require additional review by maintainers. Their approval is sufficient because a team assigned as a reviewer already approved the pull request.
168
209
169
-
Label: `needs: review`
170
-
Time: Three days for reviewers to leave feedback after the maintainers add the label.
210
+
-Label: `needs: review`.
211
+
-Time: Three days for reviewers to leave feedback after the maintainers add the label.
171
212
172
213
### The Continuous Integration (CI) testing
173
214
174
215
There are many [CI systems available](../contributing/ci.html) for testing Mbed OS pull requests and braches. Which CI tests we run against a particular pull request depends on the effect that it has on the code base. Irrespective of which CI tests run, Mbed OS has an all-green policy, meaning that all triggered CI jobs must pass before we merge the pull request.
175
216
176
-
- Label: `needs: CI`
217
+
- Label: `needs: CI`.
177
218
- Time: One day for CI to complete and report back results.
178
219
179
220
### Work needed
180
221
181
222
A pull request in the "work needed" state requires additional work due to failed tests, or rework as a result of the review. If a pull request is in this state, our maintainers request changes from the pull request author.
182
223
183
-
- Label: `needs: work`
224
+
- Label: `needs: work`.
184
225
- Time: Three days for the pull request author to action the review comments.
185
226
186
227
### Ready for integration
187
228
188
229
Maintainers merge pull requests during the internal gatekeeping meetings that occur three times a week. They can merge straightforward pull requests immediately.
189
230
190
-
- Label: `Ready for merge`
191
-
- Time: Two days
231
+
- Label: `Ready for merge`.
232
+
- Time: Two days.
192
233
193
234
### Releases
194
235
195
236
When we merge a pull request that we will publish in a patch release, we tag it with the specific patch release version. This is the release in which we first publish this pull request. For patch releases, we allow only bug fixes, new targets and enhancements to existing functionality. New features are only published in feature releases.
196
237
197
-
The release tag has the following format:
238
+
The release tag has the format:
239
+
240
+
*release-version: m.f.p*
241
+
242
+
Where:
243
+
244
+
-`m` is the major release.
245
+
-`f` is the feature release.
246
+
-`p` is the patch release.
198
247
199
-
*release-version: 5.f.p* - Where `f` is the feature release and `p` the patch release.
248
+
From time to time there may be additional suffixes added which could represent a release candidate or
0 commit comments