2014-11-05 04:38:23 +03:00
|
|
|
{
|
2019-03-30 04:22:03 +03:00
|
|
|
"name": "fxa",
|
2020-05-15 03:48:39 +03:00
|
|
|
"private": true,
|
2019-03-30 04:22:03 +03:00
|
|
|
"version": "2.0.0",
|
|
|
|
"description": "Firefox Accounts monorepo",
|
2014-11-05 04:38:23 +03:00
|
|
|
"scripts": {
|
2020-05-15 03:48:39 +03:00
|
|
|
"preinstall": "_scripts/check-package-manager.sh",
|
2019-04-24 10:13:34 +03:00
|
|
|
"authors": "git shortlog -s | cut -c8- | sort -f > AUTHORS",
|
2020-04-10 21:33:30 +03:00
|
|
|
"start": "nps --prefix=start",
|
|
|
|
"stop": "nps --prefix=stop",
|
|
|
|
"restart": "nps --prefix=restart",
|
2021-11-19 22:52:33 +03:00
|
|
|
"delete": "nps --prefix=delete",
|
2023-08-29 21:19:54 +03:00
|
|
|
"rebuild-packages": "nx run-many -t build --all",
|
2020-03-12 23:52:09 +03:00
|
|
|
"adb-reverse": "./_scripts/adb-reverse.sh",
|
2020-04-09 01:58:16 +03:00
|
|
|
"test": "_scripts/test-package.sh",
|
2019-06-25 20:47:56 +03:00
|
|
|
"config-fxios": "node _scripts/config-fxios.js",
|
2020-05-15 03:48:39 +03:00
|
|
|
"format": "yarn workspaces foreach run format",
|
2022-04-21 16:47:21 +03:00
|
|
|
"ports": "pm2 jlist | json -a -c 'this.pm2_env.env.PORT' pm2_env.env.PORT name",
|
2022-08-30 18:46:08 +03:00
|
|
|
"heroku-postbuild": "yarn workspaces foreach --verbose --include 123done install",
|
2022-09-01 18:57:08 +03:00
|
|
|
"mysql": "docker exec -it $(docker container ls | grep mysql | cut -d' ' -f1) mysql",
|
2022-12-16 02:48:16 +03:00
|
|
|
"firefox": "./packages/fxa-dev-launcher/bin/fxa-dev-launcher.mjs",
|
2023-03-15 21:30:44 +03:00
|
|
|
"generate-lockfile": "docker build . -f _dev/docker/ci-lockfile-generator/Dockerfile -t generate-lockfile && docker run generate-lockfile > yarn.lock",
|
|
|
|
"l10n:clone": "_scripts/l10n/clone.sh",
|
2023-03-16 22:44:14 +03:00
|
|
|
"l10n:prime": "_scripts/l10n/prime.sh",
|
2023-03-23 02:10:29 +03:00
|
|
|
"l10n:bundle": "_scripts/l10n/bundle.sh",
|
2023-07-18 15:54:28 +03:00
|
|
|
"legal:clone": "_scripts/clone-legal-docs.sh",
|
2023-08-29 21:19:54 +03:00
|
|
|
"gql:allowlist": "nx run-many -t gql-extract && nx run-many -t gql-copy",
|
|
|
|
"check:mysql": "_scripts/check-mysql.sh",
|
|
|
|
"check:url": "_scripts/check-url.sh"
|
2014-12-30 08:57:38 +03:00
|
|
|
},
|
2019-03-30 04:22:03 +03:00
|
|
|
"homepage": "https://github.com/mozilla/fxa",
|
2015-06-08 03:35:33 +03:00
|
|
|
"bugs": {
|
2019-03-30 04:22:03 +03:00
|
|
|
"url": "https://github.com/mozilla/fxa/issues"
|
2015-06-08 03:35:33 +03:00
|
|
|
},
|
2014-12-30 08:57:38 +03:00
|
|
|
"repository": {
|
|
|
|
"type": "git",
|
2019-03-30 04:22:03 +03:00
|
|
|
"url": "https://github.com/mozilla/fxa"
|
2014-11-05 04:38:23 +03:00
|
|
|
},
|
2015-06-08 03:35:33 +03:00
|
|
|
"author": "Mozilla (https://mozilla.org/)",
|
|
|
|
"license": "MPL-2.0",
|
2014-11-05 04:38:23 +03:00
|
|
|
"dependencies": {
|
2023-09-26 22:09:09 +03:00
|
|
|
"@faker-js/faker": "^8.1.0",
|
2023-08-01 18:33:21 +03:00
|
|
|
"@fluent/react": "^0.15.2",
|
2023-09-07 03:07:43 +03:00
|
|
|
"@nestjs/common": "^10.2.4",
|
2023-08-25 20:46:25 +03:00
|
|
|
"@nestjs/config": "^3.0.0",
|
2023-09-07 03:07:43 +03:00
|
|
|
"@nestjs/core": "^10.2.4",
|
2023-08-25 20:46:25 +03:00
|
|
|
"@nestjs/graphql": "^8.0.2",
|
2023-09-07 03:07:43 +03:00
|
|
|
"@nestjs/mapped-types": "^2.0.2",
|
|
|
|
"@nestjs/passport": "^10.0.1",
|
|
|
|
"@nestjs/platform-express": "^10.2.4",
|
|
|
|
"@nestjs/schedule": "^3.0.3",
|
2023-08-17 18:49:05 +03:00
|
|
|
"@swc/helpers": "~0.5.0",
|
2023-08-29 01:56:33 +03:00
|
|
|
"class-transformer": "^0.5.1",
|
2023-07-18 20:27:35 +03:00
|
|
|
"class-validator": "^0.14.0",
|
2019-03-30 04:22:03 +03:00
|
|
|
"diffparser": "^2.0.1",
|
2023-09-07 03:07:43 +03:00
|
|
|
"graphql": "^15.6.1",
|
2023-11-01 23:40:21 +03:00
|
|
|
"graphql-request": "^6.1.0",
|
2023-07-18 20:27:35 +03:00
|
|
|
"hot-shots": "^10.0.0",
|
2020-08-22 03:06:03 +03:00
|
|
|
"husky": "^4.2.5",
|
2023-06-06 03:09:56 +03:00
|
|
|
"knex": "^2.4.2",
|
2023-08-18 18:02:20 +03:00
|
|
|
"kysely": "^0.26.1",
|
2023-11-02 10:06:51 +03:00
|
|
|
"lint-staged": "^15.0.2",
|
2023-06-06 03:09:56 +03:00
|
|
|
"mysql": "^2.18.1",
|
2023-08-18 18:02:20 +03:00
|
|
|
"mysql2": "^3.6.0",
|
2023-10-31 09:28:49 +03:00
|
|
|
"nest-typed-config": "^2.9.1",
|
2023-11-15 02:34:34 +03:00
|
|
|
"next": "^14.0.2",
|
2022-11-16 23:16:42 +03:00
|
|
|
"node-fetch": "^2.6.7",
|
2020-08-22 03:06:03 +03:00
|
|
|
"nps": "^5.10.0",
|
2023-06-06 03:09:56 +03:00
|
|
|
"objection": "^3.0.1",
|
2023-02-27 22:16:37 +03:00
|
|
|
"p-queue": "^7.3.4",
|
2023-09-07 03:07:43 +03:00
|
|
|
"passport": "^0.6.0",
|
2023-03-22 20:18:31 +03:00
|
|
|
"pm2": "^5.3.0",
|
2023-06-07 18:29:29 +03:00
|
|
|
"prettier": "^2.6.2",
|
2023-07-10 20:55:22 +03:00
|
|
|
"react": "^18.2.0",
|
|
|
|
"react-dom": "^18.2.0",
|
2023-06-29 00:42:33 +03:00
|
|
|
"react-ga4": "^2.1.0",
|
2023-08-02 09:57:45 +03:00
|
|
|
"replace-in-file": "^7.0.1",
|
2023-09-07 03:07:43 +03:00
|
|
|
"rxjs": "^7.8.1",
|
2023-10-12 21:51:27 +03:00
|
|
|
"semver": "^7.5.2",
|
2023-08-11 16:52:52 +03:00
|
|
|
"tslib": "^2.5.0",
|
|
|
|
"uuid": "^9.0.0"
|
2019-03-30 04:22:03 +03:00
|
|
|
},
|
|
|
|
"engines": {
|
2023-10-14 00:29:13 +03:00
|
|
|
"node": "^18.18.2"
|
2019-03-30 04:22:03 +03:00
|
|
|
},
|
2019-06-25 20:47:56 +03:00
|
|
|
"husky": {
|
|
|
|
"hooks": {
|
2019-11-19 22:47:55 +03:00
|
|
|
"pre-commit": "lint-staged",
|
2020-05-22 02:06:10 +03:00
|
|
|
"post-checkout": "_scripts/git-checkout-hook.sh",
|
|
|
|
"post-merge": "_scripts/git-merge-hook.sh"
|
2019-06-25 20:47:56 +03:00
|
|
|
}
|
|
|
|
},
|
|
|
|
"lint-staged": {
|
2022-11-22 23:17:42 +03:00
|
|
|
"packages/!(fxa-payments-server)/**/*.js": [
|
2020-05-30 00:53:35 +03:00
|
|
|
"prettier --config _dev/.prettierrc --write",
|
2022-11-01 23:17:53 +03:00
|
|
|
"eslint"
|
2019-06-25 20:47:56 +03:00
|
|
|
],
|
2019-10-02 19:23:15 +03:00
|
|
|
"*.{ts,tsx}": [
|
2020-03-12 23:52:09 +03:00
|
|
|
"prettier --config _dev/.prettierrc --write"
|
2019-08-16 09:12:35 +03:00
|
|
|
],
|
2022-11-01 23:17:53 +03:00
|
|
|
"packages/fxa-auth-server/**/*.{ts,tsx}": [
|
|
|
|
"eslint"
|
|
|
|
],
|
2019-06-25 20:47:56 +03:00
|
|
|
"*.css": [
|
2020-03-12 23:52:09 +03:00
|
|
|
"prettier --config _dev/.prettierrc --write"
|
2019-06-25 20:47:56 +03:00
|
|
|
],
|
2020-04-27 21:21:23 +03:00
|
|
|
"*.scss": [
|
2020-05-17 22:44:41 +03:00
|
|
|
"stylelint --config _dev/.stylelintrc"
|
2020-04-27 21:21:23 +03:00
|
|
|
],
|
2019-06-25 20:47:56 +03:00
|
|
|
"*.md": [
|
2020-03-12 23:52:09 +03:00
|
|
|
"prettier --config _dev/.prettierrc --write"
|
2019-06-25 20:47:56 +03:00
|
|
|
]
|
2019-10-31 20:50:59 +03:00
|
|
|
},
|
|
|
|
"devDependencies": {
|
2023-08-17 18:49:05 +03:00
|
|
|
"@babel/preset-react": "^7.14.5",
|
2023-08-15 17:28:25 +03:00
|
|
|
"@graphql-codegen/cli": "5.0.0",
|
|
|
|
"@graphql-codegen/client-preset": "^4.1.0",
|
|
|
|
"@graphql-codegen/typescript": "4.0.1",
|
|
|
|
"@graphql-codegen/typescript-document-nodes": "4.0.1",
|
2023-08-25 20:46:25 +03:00
|
|
|
"@nestjs/cli": "^9.4.0",
|
2023-11-08 09:44:34 +03:00
|
|
|
"@nestjs/schematics": "^10.0.3",
|
2023-09-07 03:07:43 +03:00
|
|
|
"@nestjs/testing": "^10.2.4",
|
2023-09-26 22:09:09 +03:00
|
|
|
"@nx/cypress": "^16.9.1",
|
|
|
|
"@nx/eslint-plugin": "^16.9.1",
|
|
|
|
"@nx/jest": "^16.9.1",
|
|
|
|
"@nx/js": "^16.9.1",
|
|
|
|
"@nx/next": "^16.9.1",
|
|
|
|
"@nx/node": "^16.9.1",
|
|
|
|
"@nx/react": "^16.9.1",
|
2023-11-29 09:29:26 +03:00
|
|
|
"@nx/storybook": "^17.1.3",
|
2023-09-26 22:09:09 +03:00
|
|
|
"@nx/workspace": "^16.9.1",
|
2023-10-06 09:53:01 +03:00
|
|
|
"@storybook/addon-essentials": "^7.4.6",
|
2023-09-29 19:19:39 +03:00
|
|
|
"@storybook/addon-styling": "^1.3.7",
|
|
|
|
"@storybook/core-common": "^7.4.5",
|
|
|
|
"@storybook/core-server": "^7.4.5",
|
|
|
|
"@storybook/html-webpack5": "^7.4.5",
|
2023-11-28 02:51:26 +03:00
|
|
|
"@storybook/nextjs": "^7.5.3",
|
2023-09-29 19:19:39 +03:00
|
|
|
"@storybook/react-webpack5": "^7.4.5",
|
2023-08-17 18:49:05 +03:00
|
|
|
"@swc/cli": "~0.1.62",
|
|
|
|
"@swc/core": "~1.3.51",
|
2023-07-10 20:55:22 +03:00
|
|
|
"@testing-library/react": "^14.0.0",
|
2023-04-27 19:56:10 +03:00
|
|
|
"@types/jest": "^29.5.1",
|
2023-06-06 03:09:56 +03:00
|
|
|
"@types/mysql": "^2",
|
2023-10-14 00:29:13 +03:00
|
|
|
"@types/node": "^18.18.2",
|
2023-09-07 03:07:43 +03:00
|
|
|
"@types/passport": "^1.0.6",
|
2023-07-10 20:55:22 +03:00
|
|
|
"@types/react": "^18",
|
|
|
|
"@types/react-dom": "^18",
|
|
|
|
"@types/react-test-renderer": "^18",
|
2023-08-11 16:52:52 +03:00
|
|
|
"@types/uuid": "^8.3.0",
|
2023-04-27 19:56:10 +03:00
|
|
|
"@typescript-eslint/eslint-plugin": "^5.59.1",
|
2023-11-07 09:18:15 +03:00
|
|
|
"@typescript-eslint/parser": "^6.10.0",
|
2023-06-14 21:42:07 +03:00
|
|
|
"autoprefixer": "^10.4.14",
|
|
|
|
"babel-jest": "^29.4.1",
|
2023-08-17 18:49:05 +03:00
|
|
|
"cypress": "^12.16.0",
|
2021-10-07 01:38:39 +03:00
|
|
|
"eslint": "^7.32.0",
|
2023-11-02 18:35:38 +03:00
|
|
|
"eslint-config-next": "14.0.1",
|
2023-03-22 16:27:13 +03:00
|
|
|
"eslint-plugin-fxa": "workspace:*",
|
2023-08-01 09:41:02 +03:00
|
|
|
"eslint-plugin-import": "2.28.0",
|
2023-03-10 10:01:36 +03:00
|
|
|
"eslint-plugin-jest": "^27.2.1",
|
2023-06-14 21:42:07 +03:00
|
|
|
"eslint-plugin-jsx-a11y": "6.7.1",
|
2023-03-02 21:34:45 +03:00
|
|
|
"eslint-plugin-react": "^7.32.2",
|
2023-06-14 21:42:07 +03:00
|
|
|
"eslint-plugin-react-hooks": "4.6.0",
|
2023-04-27 19:56:10 +03:00
|
|
|
"jest": "^29.5.0",
|
|
|
|
"jest-environment-jsdom": "^29.5.0",
|
2023-06-07 18:29:29 +03:00
|
|
|
"jest-environment-node": "^29.4.1",
|
2021-05-24 21:44:40 +03:00
|
|
|
"json": "^11.0.0",
|
task(CI): build, unit test, and integration test jobs
Because:
- We wanted to run a few preliminary checks before proceeding to more
expensive CI jobs. Checks include:
- Compiling typescript in commonly referenced workspace packages
- Linting code that has changed
- Executing Unit Tests for code that has changed
- We wanted to partition test operations into unit tests, and
integration tests. Unit tests can be run relatively quickly and
require no additional infrastructure. Integration tests require
additional infrastructure and generally have longer execution
times. Now that jobs are blocked from running until preliminary
checks pass, one of which is unit tests, it is important to draw a
distinction between these two types of tests.
- We want to avoid unnecessary yarn installs and typescript
compilations, which are time consuming.
- We want to make sure that test results are published and failing tests
can be easily viewed in the CI.
This Commit:
- Creates a build-and-validate job in the CI that builds, lints, and
unit tests code prior to running any other jobs.
- Creates unit-test job in CI config
- Creates integration-test job in CI config
- Removes redundant calls to compile workspace packages. These
are now built up front, cached, and restored as needed for future
runs.
- Extends the create-lists script functionality to generate commands
that can be executed with the parallel command.
- Removes unnecessary yarn install operations. Invoking yarn workspace
focus results in a yarn install. In the case of running tests this is largely
unnecessary, because we already do a yarn install in the base-install
step.
- Make sure test results are exported as junit xml so the CI can report
back on tests that were failing. This was done for a couple workspace
packages, but many were lacking the capability. All test:unit and
test:integration npm scripts now export this data.
- Fixes the following issues encountered along the way:
- Adds logs to monitor heap usage of jest tests. Some
jest tests are still using a lot of memory.
- Moves a few slow / long running tests from unit test to
integration tests.
- Ensures that jest.transform for ts-jest is always instructed
to have the config option isolateModules is set to true. This
definitely decreases memory overhead and resolves some
of the OOM errors we were hitting. It was configured in
some places but not everywhere.
- Exports test results files for all tests
- Exports all test artifacts
- Uses gnu parallel to run tests in parallel. Turns out yarn
workspaces foreach would give a false positive when an OOM
was encountered. Fortunately, the parallel command offered an
acceptable work around, and even offers some nice features
like the load argument, which allows to control test execution a
bit more efficiently.
2023-01-10 23:52:01 +03:00
|
|
|
"mocha-junit-reporter": "^2.2.0",
|
|
|
|
"mocha-multi": "^1.1.7",
|
2023-09-26 22:09:09 +03:00
|
|
|
"nx": "^16.9.1",
|
2023-09-08 10:09:17 +03:00
|
|
|
"nx-cloud": "16.4.0",
|
2023-07-18 15:54:28 +03:00
|
|
|
"persistgraphql": "^0.3.11",
|
2023-10-04 03:26:24 +03:00
|
|
|
"postcss": "^8.4.31",
|
2023-07-10 20:55:22 +03:00
|
|
|
"react-test-renderer": "^18.2.0",
|
2023-09-07 03:07:43 +03:00
|
|
|
"reflect-metadata": "^0.1.13",
|
2023-07-08 01:29:29 +03:00
|
|
|
"stylelint": "^15.10.1",
|
2022-10-12 09:23:29 +03:00
|
|
|
"stylelint-config-prettier": "^9.0.3",
|
2023-05-24 10:05:46 +03:00
|
|
|
"stylelint-config-recommended-scss": "^12.0.0",
|
2023-06-14 21:42:07 +03:00
|
|
|
"tailwindcss": "^3.3.3",
|
2023-06-01 23:21:44 +03:00
|
|
|
"ts-jest": "29.1.0",
|
2023-04-27 19:56:10 +03:00
|
|
|
"ts-node": "^10.9.1",
|
2023-08-28 23:36:17 +03:00
|
|
|
"typescript": "^5.2.2"
|
2020-05-15 03:48:39 +03:00
|
|
|
},
|
|
|
|
"workspaces": [
|
|
|
|
"packages/*"
|
|
|
|
],
|
|
|
|
"resolutions": {
|
2023-06-23 21:31:01 +03:00
|
|
|
"@babel/core": "^7.22.5",
|
|
|
|
"@babel/helper-module-imports": "^7.22.5",
|
|
|
|
"@babel/types": "^7.22.5",
|
2022-11-11 00:44:15 +03:00
|
|
|
"@grpc/grpc-js": "~1.6.0",
|
2021-11-19 10:25:28 +03:00
|
|
|
"@nestjs/cli/typescript": "^4.5.2",
|
2023-06-23 21:31:01 +03:00
|
|
|
"@svgr/webpack": "^8.0.1",
|
2023-10-14 00:29:13 +03:00
|
|
|
"@types/node": "^18.18.2",
|
2023-07-10 20:55:22 +03:00
|
|
|
"@types/react": "^18",
|
2022-01-11 20:21:56 +03:00
|
|
|
"browserid-crypto": "https://github.com/mozilla-fxa/browserid-crypto.git#5979544d13eeb15a02d0b9a6a7a08a698d54d37d",
|
2023-06-23 21:31:01 +03:00
|
|
|
"css-minimizer-webpack-plugin": ">=4 <5",
|
2022-11-17 00:29:33 +03:00
|
|
|
"elliptic": ">=6.5.4",
|
2022-04-12 01:37:28 +03:00
|
|
|
"eslint-plugin-import": "^2.25.2",
|
2022-11-11 00:44:15 +03:00
|
|
|
"fbjs/isomorphic-fetch": "^3.0.0",
|
2023-08-10 20:03:49 +03:00
|
|
|
"flat": ">=5.0.2",
|
2022-11-11 00:44:15 +03:00
|
|
|
"gobbledygook": "https://github.com/mozilla-fxa/gobbledygook.git#354042684056e57ca77f036989e907707a36cff2",
|
2022-09-03 03:54:41 +03:00
|
|
|
"google-gax": "2.30.5",
|
2022-11-11 00:44:15 +03:00
|
|
|
"http-proxy": "^1.18.1",
|
|
|
|
"minimist": "^1.2.6",
|
|
|
|
"moment:>2.0.0 <3": ">=2.29.4",
|
2022-11-16 21:49:54 +03:00
|
|
|
"node-forge": ">=1.3.0",
|
2022-11-16 00:27:41 +03:00
|
|
|
"plist": "^3.0.6",
|
2023-09-11 00:20:09 +03:00
|
|
|
"protobufjs:>6.0.0 <7": ">=6.11.4",
|
2022-11-11 00:44:15 +03:00
|
|
|
"tap/typescript": "^4.5.2",
|
2022-11-16 00:11:29 +03:00
|
|
|
"terser:>4.0.0 <5": ">=4.8.1",
|
|
|
|
"terser:>5 <6": ">=5.14.2",
|
2022-11-14 19:33:37 +03:00
|
|
|
"underscore": ">=1.13.2",
|
2022-11-11 00:44:15 +03:00
|
|
|
"url-parse": "^1.5.8"
|
2021-10-07 19:57:36 +03:00
|
|
|
},
|
2022-12-16 02:48:16 +03:00
|
|
|
"packageManager": "yarn@3.3.0"
|
2014-11-05 04:38:23 +03:00
|
|
|
}
|