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

Dash monorepo #1679

Merged
merged 1,659 commits into from
Aug 20, 2021
Merged

Dash monorepo #1679

merged 1,659 commits into from
Aug 20, 2021

Conversation

HammadTheOne
Copy link
Contributor

@HammadTheOne HammadTheOne commented Jun 30, 2021

This PR is the initial monorepo implementation. It integrates the dash-core-components, dash-html-components, and dash-table component libraries and their dependencies within the Dash namespace, and adds some tools for maintaining the monorepo.

  • Add dcc, html, and dash_table to the Dash namespace
  • Add dash dependencies to the Dash namespace
  • Set up Lerna monorepo, and packages directory.
  • Added CLI script dash-update-components to access and update packages within Dash.
  • Update build process and Python package to include dcc, html, table dependencies.
  • Update linting to exclude html, dcc packages.
  • Integrate CI testing with dynamic configs with CircleCI (WIP)
  • Integrate dev branch git commits and histories with lerna import (must be done prior to merging the PR/updating components).
  • Possibly merge dash-table to dcc.
  • Update CHANGELOG
  • Remove test-app before merging.
  • Fix remaining test conflicts
  • Git rebase to clean up git history

A test app is present at test-app/test-dash.py to check that imports and dependencies are successfully imported through Dash.

Contributor Checklist

  • I have run the tests locally and they passed. (refer to testing section in contributing)
  • I have added tests, or extended existing tests, to cover any new features or bugs fixed in this PR

optionals

  • I have added entry in the CHANGELOG.md
  • If this PR needs a follow-up in dash docs, community thread, I have mentioned the relevant URLS as follows
    • this GitHub #PR number updates the dash docs
    • here is the show and tell thread in Plotly Dash community

Closes plotly/dash-core#323

chriddyp and others added 30 commits June 21, 2017 10:51
add `n_clicks` property to each component
… before 'import dash_html_components' (wrong-import-order). Standard import 'import sys as _sys' should be placed before 'import dash as _dash' (wrong-import-order).
… fix by changing the 'version' in version.py and then running from the command line: python3 setup.py --version
Replaced dash-core-components by dash-html-components
* Update generate-components to use prop-types for PropTypes (supporting React 16)
Update components to use prop-types
Move react (and react-dom) to peerDependencies to support multiple versions (15.4+ and 16.0+)
Add package-lock.json

* Update tests to include __init__ for finding tests package.

* 0.8.1

* 0.9.0

* Bump version to 0.9.0 and update CHANGELOG

* Remove mismatched components from previous release

* Add back Base.react.js

* integration tests

* rerun publish

* trigger ci build

* Update generate-components to use prop-types for PropTypes (supporting React 16)
Update components to use prop-types
Move react (and react-dom) to peerDependencies to support multiple versions (15.4+ and 16.0+)
Add package-lock.json

* Update tests to include __init__ for finding tests package.

* 0.8.1

* 0.9.0

* Bump version to 0.9.0 and update CHANGELOG

* Remove mismatched components from previous release

* Add back Base.react.js
…age if failed (#39)

* add check that dash was imported and exit with useful message if not

* don't add print_function to namespace

* added test to check for sys.exit(1) when dash.py present
* Add data-* and aria-* attributes

* added role attribute
* commit generated files to the repo

- This is another sanity check for prerelease checks
- Enables users to install directly from GitHub. For Python users,
installing from PyPI is still the recommended way to install the package

* let eslint ignore generated bundles
@HammadTheOne
Copy link
Contributor Author

@alexcjohnson I added a percy-tests workflow with the jobs that include Percy snapshots, tied together to a single percy-finalize call.

image

However, while the workflow seems correct on CircleCI, we still have 6 jobs generated still on Percy, 2 of which have snapshots (looks like test-39 and table-server-test. The PERCY_PARALLEL_TOTAL env key we have set is correct for parallel builds, but it doesn't seem like they're being combined into a single build on Percy's end as they should according to this.

Could it be that we're using a somewhat older docker image for Percy which doesn't support this, rather than the recommended percy-agent CI orb? Or is it maybe the parallelism key within the jobs themselves? Unfortunately the Percy docs don't cover this particular scenario in much detail.

@jonmmease
Copy link
Contributor

The slider dcc tests were failing because of an orjson encoding issue that's getting fixed in plotly/plotly.py#3351.

@jonmmease
Copy link
Contributor

jonmmease commented Aug 19, 2021

test_tdrp002_select_cell in the table component tests is also failing under orjson. I'm looking into it, but you might want to remove orjson for the table tests as well.

I take it back, it's actually flaky locally 🤔

@HammadTheOne
Copy link
Contributor Author

@alexcjohnson I split the dash-table ones which use percy storybook into a separate Percy build linked to the same repo, so they'll appear in the Github status, alongside the dash ones which would include dcc and html. The Dashboard Engine repo follows a similar pattern.

If that looks fine, we can look at merging this PR tomorrow morning.

@chriddyp chriddyp requested review from chriddyp and removed request for Marc-Andre-Rivet August 20, 2021 14:37
@chriddyp chriddyp merged commit 5c2f05e into dev Aug 20, 2021
@alexcjohnson alexcjohnson deleted the dash-monorepo branch August 23, 2021 01:08
This was referenced Aug 23, 2021
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

Successfully merging this pull request may close these issues.