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

Known issues (when importing fusion.js packages) #3

Open
lhorie opened this issue Jan 26, 2019 · 5 comments
Open

Known issues (when importing fusion.js packages) #3

lhorie opened this issue Jan 26, 2019 · 5 comments

Comments

@lhorie
Copy link
Owner

lhorie commented Jan 26, 2019

rush

  • eslint-config-fusion has a circular dependency on itself
    • workaround: modify lint script and remove dependency on itself
  • fusionjs.github.io depends on a different version of graphql than fusion-apollo and causes Gatsby to crap out under the monorepo
    • workaround: remove fusionjs.github.io from monorepo
    • alternative: migrate to latest gatsby (major upgrade)
  • fusion-plugin-service-worker tests hang
    • workaround: replace browser test w/ no-op test
  • fusion-plugin-font-loader-react tests complete with warning
    • workaround: ?
  • fusion-plugin-introspect test fails only in monorepo
    • workaround: change 'yarn' to 'none' in src/__tests__/collectMetadata.node.js:21
  • fusion-plugin-react-redux test fails only in monorepo
    • workaround: replace flow.node.js test w/ no-op test
  • fusion-plugin-error-handling test script calls transpile
    • solution: change to make it call build
  • fusion-plugin-rpc-redux-react browser tests fail due to module resolution error
    • workaround: refactor to use jest/jsdom?
  • fusion-tokens can't be linked w/ fusion-apollo-universal-client due to token registration error in test
    • workaround: rename fusion-apollo-universal-client/src/__tests__/index.js to fusion-apollo-universal-client/src/__tests__/index.node.js
  • fusion-scaffolder flow warning
    • solution: remove ./src from flowconfig
  • fusion-rpc-redux flow warning
    • solution: change ./node_modules/fusion-core/flow-typed to ../../common/temp/node_modules/fusion-core/flow-typed in flowconfig
  • adding fusion-core causes fusion-plugin-i18n-react tests to break / hang
    • workaround: remove fusion-plugin-i18n-react/src/__tests__/integration from dependencies
  • adding fusion-core causes fusion-apollo-universal-client tests to break
    • workaround: remove fusion-apollo-universal-client/src/__tests__/integration.node.js
  • adding fusion-core causes flow to break in fusion-plugin-i18n-react
    • workaround: change tape$TestCb to Function in src/tests/test-helper.js
  • fusion-cli tests break and hang
    • workaround: remove test/e2e/split-translations and test/e2e/dynamic-import-app
  • adding fusion-cli creates cyclical dep w/ fusion-plugin-i18n-react
    • workaround: remove fusion-plugin-i18n-react
  • adding create-fusion-app breaks
    • workaround: ?
  • adding fusion-plugin-rpc-redux-react breaks fusion-cli tests
    • workaround: remove lib/strip-prefix.spec.js and test/e2e/server-startup-control
  • flow error on fusion-plugin-rpc-redux-react from fusion-rpc-redux
    • workaround: remove fusion-rpc-redux/src/fixtures/failure
  • tests hang (seems to be due to too many chromium instances)
    • workaround: turn off parallelism in test script
    • alternative: refactor to use jest/jsdom?
  • flow errors about __DEV__
    • solution: add ./node_modules/fusion-core/flow-typed to the [libs] section of the package's .flowconfig file
  • flow crash (rare)
    • workaround: re-run rush flow

workspaces

  • fusion-rpc-redux flow error in fixture
    • workaround: remove failure fixture
@lhorie
Copy link
Owner Author

lhorie commented Feb 7, 2019

Issue: src/__tests__/integration.node.js hangs in fusion-apollo-universal-client when running yarn test individually
Cause: recent versions of yarn have a bug that prevents child processes from exiting
Resolution: Run ../../common/temp/yarn-local/node_modules/.bin/yarn test instead

@lhorie
Copy link
Owner Author

lhorie commented Feb 11, 2019

Some browser tests fail on token-related issues due to a jest bug: jestjs/jest#7840 (see also, browserify/browser-resolve#92)

@lhorie
Copy link
Owner Author

lhorie commented Feb 11, 2019

fusion-cli test-jest-app tests started timing out after importing a few more repos. Increasing timeout seems to fix the issue

@lhorie
Copy link
Owner Author

lhorie commented Feb 13, 2019

Several fusion-cli test failures were happening due to files that had not been copied correctly (due to using --exclude rules in rsync). The offending rules were --exclude node_modules and --exclude dist

Some other packages were getting test errors due to missing yarn.lock or package-lock.json files. To fix them, ensure rsync is used without --exclude yarn.lock and --exclude package-lock.json. Instead, rm -f yarn.lock from each package instead to ensure only the top-level lock file is removed in each project.

@lhorie
Copy link
Owner Author

lhorie commented Feb 19, 2019

Some test failures can appear if packages are not linked. This can happen if they are not included in the projects field in the rush.json file, or if their versions are not aligned. node scripts/verify-linking can detect whether project linking is setup correctly. node scripts/sync-versions ensures package versions are correct in the dependencies/devDependencies/peerDependencies fields of all packages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant