Skip to content
This repository has been archived by the owner on Dec 10, 2021. It is now read-only.

build: migrate to nimbus #281

Merged
merged 24 commits into from
Jan 28, 2020
Merged

build: migrate to nimbus #281

merged 24 commits into from
Jan 28, 2020

Conversation

kristw
Copy link
Contributor

@kristw kristw commented Jan 22, 2020

🏠 Internal

  • Fix Can not build in project with 0.12.1 #265
  • Use build configuration from nimbus, which is a shareable build config for jest, babel, eslint, prettier, and typescript on top of beemo.
  • Fix hundreds of new lint and ts issues. Disable some eslint rules for test files at the moment.

Notable overrides

  • Set timer to real (jest's default) instead of nimbus's default which uses fake timer. For unknown reason, jest.useRealTimers() has no effect if the default timer is fake. On the other hand, if the default timer is real, jest.useFakeTimers() works fine.
  • Stop eslint from auto-fixing the no-explicit-any rule and convert all any into (the) unknown. 🎶❄️

@kristw kristw requested a review from a team as a code owner January 22, 2020 08:45
package.json Outdated Show resolved Hide resolved
@netlify
Copy link

netlify bot commented Jan 22, 2020

Deploy preview for superset-ui ready!

Built with commit 5b3b321

https://deploy-preview-281--superset-ui.netlify.com

@netlify
Copy link

netlify bot commented Jan 22, 2020

Deploy preview for superset-ui ready!

Built with commit f950af6

https://deploy-preview-281--superset-ui.netlify.com

@codecov
Copy link

codecov bot commented Jan 24, 2020

Codecov Report

Merging #281 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@          Coverage Diff          @@
##           master   #281   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files         104    102    -2     
  Lines        1234   1212   -22     
  Branches      296    298    +2     
=====================================
- Hits         1234   1212   -22
Impacted Files Coverage Δ
packages/superset-ui-time-format/src/utils.ts 100% <ø> (ø) ⬆️
...kages/superset-ui-query/src/types/QueryFormData.ts 100% <ø> (ø) ⬆️
...ages/superset-ui-dimension/src/getTextDimension.ts 100% <ø> (ø) ⬆️
test/setup.ts 100% <ø> (ø)
...er-format/src/factories/createD3NumberFormatter.ts 100% <ø> (ø) ⬆️
...uperset-ui-color/src/colorSchemes/sequential/d3.ts 100% <ø> (ø) ⬆️
...set-ui-color/src/colorSchemes/sequential/common.ts 100% <ø> (ø) ⬆️
...s/superset-ui-translation/test/languagePacks/en.ts 100% <ø> (ø)
...et-ui-color/src/colorSchemes/categorical/google.ts 100% <ø> (ø) ⬆️
...rset-ui-chart/src/components/ChartDataProvider.tsx 100% <ø> (ø) ⬆️
... and 53 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0498386...f950af6. Read the comment docs.

@kristw
Copy link
Contributor Author

kristw commented Jan 28, 2020

cc @etr2460 finally got a green CI

@williaster
Copy link
Contributor

finally looking at this, thanks for all the effort/pain 🙏

Copy link
Contributor

@williaster williaster left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM overall, had a few thoughts that could be worth fixing before merge. thanks again! 💖

package.json Show resolved Hide resolved
@@ -35,8 +35,8 @@ export default class ChartFrame extends PureComponent<Props, {}> {
}}
>
{renderContent({
height: Math.max(contentHeight || 0, height),
width: Math.max(contentWidth || 0, width),
height: Math.max(contentHeight ?? 0, height),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yesssssss

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@etr2460 added these internally and although the build passed it threw errors in the app. might be worth testing (I guess if preview works it should be good)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This sounds scary. I checked the storybook previews and they work correctly.
What are the issues that appear in app? I could try to revert back to || and suppress eslint if it is risky.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you need to make sure that babel updated to handle the new syntax. babel 7.8.3 should do the trick.

packages/superset-ui-chart/package.json Show resolved Hide resolved
@kristw kristw merged commit dc804b7 into master Jan 28, 2020
@delete-merged-branch delete-merged-branch bot deleted the kristw--nimbus branch January 28, 2020 23:15
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can not build in project with 0.12.1
3 participants