Skip to content
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

Update to React 18 #905

Merged
merged 38 commits into from
Jan 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
38a743b
Copy over PR#899
pringshia Oct 3, 2022
faad73c
Add `FORCE_COLOR: 0` to fix setup-node@v3 + GitHub Actions incompatib…
pringshia Oct 3, 2022
329d4b3
Upgrade yarn version
pringshia Oct 3, 2022
533c8e9
fiddle with FORCE_COLOR
pringshia Oct 3, 2022
9d0ec4d
Fiddle with FORCE_COLOR
pringshia Oct 3, 2022
9dbd830
Try different solution for yarn cache GHA error
pringshia Oct 3, 2022
7e38848
Try different solution for yarn cache GHA error
pringshia Oct 3, 2022
1ff49e5
Relax peer deps and remove FORCE_COLOR
pringshia Oct 3, 2022
5320870
Updated lock file
pringshia Jan 26, 2023
eb1a718
Deprecate @annotated for now
pringshia Jan 26, 2023
f351d38
Downgrade react-bootstrap to match last prior working version
pringshia Jan 26, 2023
d870e21
fix syntax error
pringshia Jan 26, 2023
ec17c08
Remove storybook check workflow
pringshia Jan 27, 2023
8874713
Update peer deps for mephisto-task, relaxing them
pringshia Jan 27, 2023
4d34d57
Update lockfile
pringshia Jan 27, 2023
4f4d4b9
Fix lint
pringshia Jan 27, 2023
fe83c47
Bump mephisto-task to v2.0.4
pringshia Jan 27, 2023
e170937
Upgrade all projects to latest mephisto version
pringshia Jan 27, 2023
5403cc2
Add updated lockfile
pringshia Jan 27, 2023
1b7ea7b
Try out differnet workflow file command
pringshia Jan 27, 2023
6f2d10a
Try with updated lockfile instead
pringshia Jan 27, 2023
ae68592
Update peer deps and react versions across the codebase
pringshia Jan 27, 2023
7546d59
Add updated lockfile
pringshia Jan 27, 2023
ae22f8b
Try reordering the test
pringshia Jan 27, 2023
cf028f5
remove all package-lock.json files and run prettier
pringshia Jan 27, 2023
0fd5237
Downgrade react to 16 because of old version of react-table
pringshia Jan 27, 2023
2e3ca86
Fix peer deps for mephisto-worker-addons
pringshia Jan 27, 2023
ad29d76
Downgrade more react versions to 16 because of react-table, which wer…
pringshia Jan 27, 2023
64de201
Add udpated lockfile
pringshia Jan 27, 2023
33f2dfc
Upate published peer deps for mephisto-worker-addons
pringshia Jan 27, 2023
0e70fde
Update prettierignore
pringshia Jan 27, 2023
5f47418
try Cypress fix
pringshia Jan 27, 2023
42b8b0f
Add cypress
pringshia Jan 27, 2023
3d0173a
Add Cypress
pringshia Jan 27, 2023
b049920
Add prebuild step to cypress actions
pringshia Jan 27, 2023
fbf99f0
Fix cypress installation format
pringshia Jan 27, 2023
e09b1b6
Version bump bootstrap-chat
pringshia Jan 27, 2023
cfda313
Update lcokfile
pringshia Jan 27, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 17 additions & 9 deletions .github/workflows/annotated-pkgs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,24 +24,32 @@ jobs:
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
- uses: actions/setup-node@v3
env:
FORCE_COLOR: 0
with:
node-version: "14"
node-version: 16

- name: Install yarn 3
run: npm i -g yarn

- name: Install package dependencies
run: yarn install

- name: Test that docusarus compiles
run: |
yarn workspaces list
yarn docs:build

- name: Build packages
run: yarn workspaces foreach -ptA run build

- name: Build packages with legacy setup
run: cd packages/global-context-store && npm install && npm run build

- name: Test that storybook compiles
run: yarn workspace sb build-storybook

- name: Test that docusarus compiles
run: yarn docs:build
run:
cd packages/global-context-store && npm install && npm run build

# Disabling storybook / components for now. Will re-evaluate
# and move to separate repo if needed - Jan 26, 2023
#
# - name: Test that storybook compiles
# run: yarn workspace sb build-storybook
21 changes: 14 additions & 7 deletions .github/workflows/cypress-end-to-end-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,13 @@ jobs:
- uses: actions/checkout@v3
with:
fetch-depth: 2
# Workaround to avoid Post Use step failures. See: https://github.com/actions/setup-node/issues/317
- run: mkdir -p /home/runner/work/Mephisto/Mephisto/.yarn/cache
continue-on-error: true
- uses: actions/setup-node@v3
with:
cache: "yarn"
node-version: 16
- uses: dorny/paths-filter@v2
id: filter
with:
Expand Down Expand Up @@ -96,13 +103,13 @@ jobs:
- name: ⌛️ Running cypress tests
uses: cypress-io/github-action@v3.1.0
with:
build: npm i -D cypress@11
install: false
browser: chrome
project: ./mephisto/abstractions/blueprints/static_html_task/source
config-file: ./cypress.config.js
start: python ./examples/simple_static_task/static_test_script.py
wait-on: "http://localhost:3000/?worker_id=x&assignment_id=1"
command-prefix: yarn dlx
headless: true

# Learn more about this test here: https://github.com/facebookresearch/Mephisto/pull/795
Expand Down Expand Up @@ -143,13 +150,13 @@ jobs:
- name: ⌛️ Running cypress tests
uses: cypress-io/github-action@v3.1.0
with:
build: npm i -D cypress@11
install: false
browser: chrome
project: ./examples/static_react_task/webapp
config-file: ./cypress.config.js
start: python examples/static_react_task/run_task.py mephisto.task.post_install_script=link_mephisto_task.sh
wait-on: "http://localhost:3000/?worker_id=x&assignment_id=1"
command-prefix: yarn dlx
headless: true

# Learn more about the remote_procedure_tests here: https://github.com/facebookresearch/Mephisto/pull/800
Expand Down Expand Up @@ -190,13 +197,13 @@ jobs:
- name: ⌛️ Running cypress tests
uses: cypress-io/github-action@v3.1.0
with:
build: npm i -D cypress@11
install: false
browser: chrome
project: ./examples/remote_procedure/template/webapp
config-file: ./cypress.config.js
start: python examples/remote_procedure/template/run_task.py mephisto.task.post_install_script=link_mephisto_task.sh
wait-on: "http://localhost:3000/?worker_id=x&assignment_id=1"
command-prefix: yarn dlx
headless: true

remote_procedure_mnist:
Expand Down Expand Up @@ -238,13 +245,13 @@ jobs:
- name: ⌛️ Running cypress tests
uses: cypress-io/github-action@v3.1.0
with:
build: npm i -D cypress@11
install: false
browser: chrome
project: ./examples/remote_procedure/mnist/webapp
config-file: ./cypress.config.js
start: python examples/remote_procedure/mnist/run_task.py mephisto.task.post_install_script=link_mephisto_task.sh
wait-on: "http://localhost:3000/?worker_id=x&assignment_id=1"
command-prefix: yarn dlx
headless: true

remote_procedure_toxicity_detection:
Expand Down Expand Up @@ -284,13 +291,13 @@ jobs:
- name: ⌛️ Running cypress tests
uses: cypress-io/github-action@v3.1.0
with:
build: npm i -D cypress@11
install: false
browser: chrome
project: ./examples/remote_procedure/toxicity_detection/webapp
config-file: ./cypress.config.js
start: python examples/remote_procedure/toxicity_detection/run_task.py mephisto.task.post_install_script=link_mephisto_task.sh
wait-on: "http://localhost:3000/?worker_id=x&assignment_id=1"
command-prefix: yarn dlx
headless: true

# Learn more about this test here: https://github.com/facebookresearch/Mephisto/pull/833
Expand Down Expand Up @@ -339,14 +346,14 @@ jobs:
- name: ⌛️ Running pre-submission cypress tests
uses: cypress-io/github-action@v3.1.0
with:
build: npm i -D cypress@11
install: false
browser: chrome
project: ./examples/static_react_task_with_tips/webapp
config-file: ./cypress.config.js
spec: ./examples/static_react_task_with_tips/webapp/cypress/e2e/pre_submission_tests/*
start: python examples/static_react_task_with_tips/run_task.py mephisto.task.force_rebuild=true mephisto.task.post_install_script=link_packages.sh
wait-on: "http://localhost:3000/?worker_id=x&assignment_id=1"
command-prefix: yarn dlx
headless: true

- name: 🔪 Killing the web server
Expand Down Expand Up @@ -413,12 +420,12 @@ jobs:
- name: ⌛️ Running post-submission cypress tests
uses: cypress-io/github-action@v3.1.0
with:
build: npm i -D cypress@11
install: false
project: ./examples/static_react_task_with_tips/webapp
config-file: cypress.config.js
spec: ./examples/static_react_task_with_tips/webapp/cypress/e2e/post_submission_tests/*
start: python examples/static_react_task_with_tips/run_task.py mephisto.task.post_install_script=link_packages.sh mephisto.task.force_rebuild=true
wait-on: "http://localhost:3000/?worker_id=x&assignment_id=1"
command-prefix: yarn dlx
browser: chrome
headless: true
4 changes: 3 additions & 1 deletion .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ jobs:
working-directory: docs/web
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
- uses: actions/setup-node@v3
env:
FORCE_COLOR: 0
with:
node-version: 16.16.0
cache: yarn
Expand Down
3 changes: 2 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
*.md
**/build/*
docs/web/static/python_api/*
wrap_crowd_source.js
wrap_crowd_source.js
packages/mephisto-worker-addons/lib
546 changes: 546 additions & 0 deletions .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs

Large diffs are not rendered by default.

783 changes: 783 additions & 0 deletions .yarn/releases/yarn-3.2.3.cjs

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,7 @@ plugins:
spec: "@yarnpkg/plugin-workspace-tools"
- path: .yarn/plugins/@yarnpkg/plugin-version.cjs
spec: "@yarnpkg/plugin-version"
- path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
spec: "@yarnpkg/plugin-interactive-tools"

yarnPath: .yarn/releases/yarn-3.2.4.cjs
38 changes: 19 additions & 19 deletions docs/storybook/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,17 @@
"@annotated/keypoint": "workspace:packages/annotated/keypoint",
"@annotated/shell": "workspace:packages/annotated/shell",
"@annotated/video-player": "workspace:packages/annotated/video-player",
"@blueprintjs/core": "^3.50.1",
"@testing-library/jest-dom": "^5.11.4",
"@testing-library/react": "^11.1.0",
"@testing-library/user-event": "^12.1.10",
"eslint-config-react-app": "^6.0.0",
"@blueprintjs/core": "^4.9.4",
"@testing-library/jest-dom": "^5.16.5",
"@testing-library/react": "^13.4.0",
"@testing-library/user-event": "^14.4.3",
"eslint-config-react-app": "^7.0.1",
"global-context-store": "^1.0.3",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-helmet": "^6.1.0",
"react-scripts": "4.0.3",
"web-vitals": "^1.0.1"
"react-scripts": "5.0.1",
"web-vitals": "^3.0.1"
},
"scripts": {
"storybook": "start-storybook -p 6006 -s public",
Expand All @@ -36,16 +36,16 @@
]
},
"devDependencies": {
"@mdx-js/react": "^1.6.22",
"@storybook/addon-actions": "^6.3.8",
"@storybook/addon-docs": "^6.3.8",
"@storybook/addon-essentials": "^6.3.8",
"@storybook/addon-links": "^6.3.8",
"@storybook/node-logger": "^6.3.8",
"@storybook/preset-create-react-app": "^3.2.0",
"@storybook/react": "^6.3.8",
"prop-types": "^15.7.2",
"webpack-hot-middleware": "^2.25.1"
"@mdx-js/react": "^2.1.3",
"@storybook/addon-actions": "^6.5.10",
"@storybook/addon-docs": "^6.5.10",
"@storybook/addon-essentials": "^6.5.10",
"@storybook/addon-links": "^6.5.10",
"@storybook/node-logger": "^6.5.10",
"@storybook/preset-create-react-app": "^4.1.2",
"@storybook/react": "^6.5.10",
"prop-types": "^15.8.1",
"webpack-hot-middleware": "^2.25.2"
},
"eslintConfig": {
"overrides": [
Expand Down
Loading