Skip to content

Commit 2dc48aa

Browse files
authored
Merge branch 'main' into release-automation-notes
2 parents dc3b6d7 + 14af23a commit 2dc48aa

File tree

3,237 files changed

+192959
-149340
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,237 files changed

+192959
-149340
lines changed

.browserslistrc

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,14 @@
11
[production]
2-
last 2 Firefox versions
3-
last 2 Chrome versions
4-
last 2 Safari versions
5-
> 0.25%
6-
not ie 11
2+
Firefox > 0 and last 2 years and > 0.01%
3+
Chrome > 0 and last 2 years and > 0.01%
4+
Safari > 0 and last 2 years and > 0.01%
5+
Edge > 0 and last 1 years and > 0.01%
6+
Opera > 0 and last 2 years and > 0.01%
7+
> 0.2%
8+
not op_mini all
9+
not and_uc < 100
10+
not android < 100
11+
not dead
712

813
[dev]
914
last 1 chrome versions

.eslintignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
/.chromium
44
/build
55
/built_assets
6+
/bwc_tmp
67
/config/apm.dev.js
78
/data
89
/html_docs
@@ -17,8 +18,7 @@ target
1718
# plugin overrides
1819
/src/core/lib/osd_internal_native_observable
1920
/src/legacy/plugin_discovery/plugin_pack/__tests__/fixtures/plugins/broken
20-
/src/plugins/data/common/opensearch_query/kuery/ast/_generated_/**
21-
/src/plugins/vis_type_timeline/public/_generated_/**
21+
/src/plugins/**/_generated_/**
2222

2323
# package overrides
2424
/packages/opensearch-eslint-config-opensearch-dashboards

.eslintrc.js

Lines changed: 16 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -272,26 +272,22 @@ module.exports = {
272272
basePath: __dirname,
273273
zones: [
274274
{
275-
target: ['(src)/**/*', '!src/core/**/*'],
275+
target: ['src/**/*', '!src/core/**/*'],
276276
from: ['src/core/utils/**/*'],
277277
errorMessage: `Plugins may only import from src/core/server and src/core/public.`,
278278
},
279279
{
280-
target: ['(src)/plugins/*/server/**/*'],
281-
from: ['(src)/plugins/*/public/**/*'],
280+
target: ['src/plugins/*/server/**/*'],
281+
from: ['src/plugins/*/public/**/*'],
282282
errorMessage: `Server code can not import from public, use a common directory.`,
283283
},
284284
{
285-
target: ['(src)/plugins/*/common/**/*'],
286-
from: ['(src)/plugins/*/(server|public)/**/*'],
285+
target: ['src/plugins/*/common/**/*'],
286+
from: ['src/plugins/*/(server|public)/**/*'],
287287
errorMessage: `Common code can not import from server or public, use a common directory.`,
288288
},
289289
{
290-
target: [
291-
'src/legacy/**/*',
292-
'(src)/plugins/**/(public|server)/**/*',
293-
'examples/**/*',
294-
],
290+
target: ['src/legacy/**/*', 'src/plugins/**/(public|server)/**/*', 'examples/**/*'],
295291
from: [
296292
'src/core/public/**/*',
297293
'!src/core/public/index.ts', // relative import
@@ -320,30 +316,30 @@ module.exports = {
320316
{
321317
target: [
322318
'src/legacy/**/*',
323-
'(src)/plugins/**/(public|server)/**/*',
319+
'src/plugins/**/(public|server)/**/*',
324320
'examples/**/*',
325-
'!(src)/**/*.test.*',
321+
'!src/**/*.test.*',
326322
],
327323
from: [
328-
'(src)/plugins/**/(public|server)/**/*',
329-
'!(src)/plugins/**/(public|server)/mocks/index.{js,mjs,ts}',
330-
'!(src)/plugins/**/(public|server)/(index|mocks).{js,mjs,ts,tsx}',
324+
'src/plugins/**/(public|server)/**/*',
325+
'!src/plugins/**/(public|server)/mocks/index.{js,mjs,ts}',
326+
'!src/plugins/**/(public|server)/(index|mocks).{js,mjs,ts,tsx}',
331327
],
332328
allowSameFolder: true,
333329
errorMessage: 'Plugins may only import from top-level public and server modules.',
334330
},
335331
{
336332
target: [
337-
'(src)/plugins/**/*',
338-
'!(src)/plugins/**/server/**/*',
333+
'src/plugins/**/*',
334+
'!src/plugins/**/server/**/*',
339335

340336
'examples/**/*',
341337
'!examples/**/server/**/*',
342338
],
343339
from: [
344340
'src/core/server',
345341
'src/core/server/**/*',
346-
'(src)/plugins/*/server/**/*',
342+
'src/plugins/*/server/**/*',
347343
'examples/**/server/**/*',
348344
],
349345
errorMessage:
@@ -355,7 +351,7 @@ module.exports = {
355351
errorMessage: 'The core cannot depend on any plugins.',
356352
},
357353
{
358-
target: ['(src)/plugins/*/public/**/*'],
354+
target: ['src/plugins/*/public/**/*'],
359355
from: ['ui/**/*'],
360356
errorMessage: 'Plugins cannot import legacy UI code.',
361357
},
@@ -459,7 +455,7 @@ module.exports = {
459455
* Files that run BEFORE node version check
460456
*/
461457
{
462-
files: ['scripts/**/*.js', 'src/setup_node_env/**/*.js'],
458+
files: ['scripts/**/*.js', 'src/setup_node_env/**/!(*.test).js'],
463459
rules: {
464460
'import/no-commonjs': 'off',
465461
'prefer-object-spread/prefer-object-spread': 'off',

.github/.codecov.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
# https://docs.codecov.com/docs/codecov-yaml
2+
codecov:
3+
require_ci_to_pass: yes
4+
25
coverage:
36
status:
47
project:
58
default:
6-
# https://docs.codecov.com/docs/commit-status#target
7-
target: auto # coverage must be equal or above the previous commit
9+
target: auto
10+
threshold: 2% # the leniency in hitting the target
11+

.github/CODEOWNERS

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
1-
# This should match the owning team set up in https://github.com/orgs/opensearch-project/teams
2-
* @opensearch-project/opensearch-dashboards-core
1+
* @ananzh @kavilla @AMoo-Miki @ashwin-pc @joshuarrrr @abbyhu2000 @zengyan-amazon @zhongnansu @manasvinibs @ZilongX @Flyingliuhub @curq @bandinib-amzn @SuZhou-Joe @ruanyl @BionIT @xinruiba @zhyuanqi @mengweieric @LDrago27

.github/pull_request_template.md

Lines changed: 33 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,42 @@
11
### Description
2-
[Describe what this change achieves]
3-
2+
3+
<!-- Describe what this change achieves-->
4+
45
### Issues Resolved
5-
[List any issues this PR will resolve]
6-
6+
7+
<!-- List any issues this PR will resolve. Prefix the issue with the keyword closes, fixes, fix -->
8+
<!-- Example: closes #1234 or fixes <Issue_URL> -->
9+
10+
## Screenshot
11+
12+
<!-- Attach any relevant screenshots. Any change to the UI requires an attached screenshot in the PR Description -->
13+
14+
## Testing the changes
15+
16+
<!--
17+
Please provide detailed steps for validating your changes. This could involve specific commands to run,
18+
pages to visit, scenarios to try or any other information that would help reviewers verify
19+
the functionality of your change
20+
-->
21+
22+
## Changelog
23+
<!--
24+
Add a short but concise sentence about the impact of this pull request. Prefix an entry with the type of change they correspond to: breaking, chore, deprecate, doc, feat, fix, infra, refactor, test.
25+
- fix: Update the graph
26+
- feat: Add a new feature
27+
28+
If this change does not need to added to the changelog, just add a single `skip` line e.g.
29+
- skip
30+
31+
Descriptions following the prefixes must be 100 characters long or less
32+
-->
33+
734
### Check List
35+
836
- [ ] All tests pass
937
- [ ] `yarn test:jest`
1038
- [ ] `yarn test:jest_integration`
11-
- [ ] `yarn test:ftr`
1239
- [ ] New functionality includes testing.
1340
- [ ] New functionality has been documented.
1441
- [ ] Update [CHANGELOG.md](./../CHANGELOG.md)
15-
- [ ] Commits are signed per the DCO using --signoff
42+
- [ ] Commits are signed per the DCO using --signoff
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Apply 'untriaged' label during issue lifecycle
2+
3+
on:
4+
issues:
5+
types: [opened, reopened, transferred]
6+
7+
jobs:
8+
apply-label-if-not-collaborator:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Check if issue author is a collaborator
12+
id: check-collaborator
13+
uses: actions/github-script@v6
14+
with:
15+
script: |
16+
const issueAuthor = context.payload.issue.user.login;
17+
const repoOwner = context.repo.owner;
18+
const repoName = context.repo.repo;
19+
let isCollaborator = false;
20+
try {
21+
// Attempt to fetch user's permission level
22+
await github.rest.repos.getCollaboratorPermissionLevel({
23+
owner: repoOwner,
24+
repo: repoName,
25+
username: issueAuthor,
26+
});
27+
28+
// If no error is thrown, the user is a collaborator
29+
isCollaborator = true;
30+
} catch (error) {
31+
// Error thrown indicates the user is not a collaborator,
32+
// or does not have explicit permission set.
33+
console.log(`${issueAuthor} is not a collaborator.`);
34+
}
35+
core.setOutput('is_collaborator', isCollaborator.toString());
36+
- name: Apply label if not a collaborator
37+
if: steps.check-collaborator.outputs.is_collaborator == 'false'
38+
uses: actions/github-script@v6
39+
with:
40+
script: |
41+
github.rest.issues.addLabels({
42+
issue_number: context.issue.number,
43+
owner: context.repo.owner,
44+
repo: context.repo.repo,
45+
labels: ['untriaged']
46+
})

.github/workflows/backport.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,10 @@ jobs:
3434
installation_id: 22958780
3535

3636
- name: Backport
37-
uses: VachaShah/backport@v2.1.0
37+
uses: VachaShah/backport@v2.2.0
3838
with:
3939
github_token: ${{ steps.github_app_token.outputs.token }}
4040
head_template: backport/backport-<%= number %>-to-<%= base %>
4141
files_to_skip: "CHANGELOG.md"
42+
labels_template: "<%= JSON.stringify([...labels, 'autocut']) %>"
43+
failure_labels: "failed backport"

0 commit comments

Comments
 (0)