iteria-app / material-ui-starter

We are testing Iteria Lowcode using Material-UI components
https://demo.iteria.tech
MIT License
1 stars 18 forks source link

Build failed due to warnings #17

Open jozef-slezak opened 3 years ago

jozef-slezak commented 3 years ago

I have setup netlify to preview builds for example-material-ui and it is failing due to following compilation error:

6:22:51 AM: ────────────────────────────────────────────────────────────────
6:22:51 AM:   1. Build command from Netlify app                             
6:22:51 AM: ────────────────────────────────────────────────────────────────
6:22:51 AM: ​
6:22:51 AM: $ yarn build
6:22:51 AM: yarn run v1.22.4
6:22:51 AM: $ yarn generate && react-scripts build
6:22:52 AM: $ graphql-codegen --config codegen.yml
6:22:53 AM: [04:22:53] Parse configuration [started]
6:22:53 AM: [04:22:53] Parse configuration [completed]
6:22:53 AM: [04:22:53] Generate outputs [started]
6:22:53 AM: [04:22:53] Generate src/generated/graphql.ts [started]
6:22:53 AM: [04:22:53] Load GraphQL schemas [started]
6:23:00 AM: [04:23:00] Load GraphQL schemas [completed]
6:23:00 AM: [04:23:00] Load GraphQL documents [started]
6:23:00 AM: [04:23:00] Load GraphQL documents [completed]
6:23:00 AM: [04:23:00] Generate [started]
6:23:00 AM: [04:23:00] Generate [completed]
6:23:00 AM: [04:23:00] Generate src/generated/graphql.ts [completed]
6:23:00 AM: [04:23:00] Generate outputs [completed]
6:23:02 AM: Creating an optimized production build...
6:24:10 AM: 
6:24:10 AM: Treating warnings as errors because process.env.CI = true.
6:24:10 AM: Most CI servers set it automatically.
6:24:10 AM: 
6:24:10 AM: Failed to compile.
6:24:10 AM: 
6:24:10 AM: src/theme/shadows.ts
6:24:10 AM:   Line 1:1:  Assign array to a variable before exporting as module default  import/no-anonymous-default-export
6:24:10 AM: src/theme/typography.ts
6:24:10 AM:   Line 1:1:  Assign object to a variable before exporting as module default  import/no-anonymous-default-export
6:24:10 AM: src/utils/getInitials.ts
6:24:10 AM:   Line 1:1:  Assign arrow function to a variable before exporting as module default  import/no-anonymous-default-export
6:24:10 AM: src/views/customer/CustomerListView/UpdateCustomer.tsx
6:24:10 AM:   Line 34:10:  'state' is assigned a value but never used                                                                                                                                                                                                                                                                                                            @typescript-eslint/no-unused-vars
6:24:10 AM:   Line 44:6:   React Hook React.useCallback has missing dependencies: 'customer?.email', 'customer?.name', 'customer?.phone', 'handleClose', 'newEmail', 'newName', and 'newPhoneNumber'. Either include them or remove the dependency array. If 'handleClose' changes too often, find the parent component that defines it and wrap that definition in useCallback  react-hooks/exhaustive-deps
6:24:10 AM:   Line 47:5:   React Hook React.useCallback has a complex expression in the dependency array. Extract it to a separate variable so it can be statically checked                                                                                                                                                                                                      react-hooks/exhaustive-deps
6:24:10 AM:   Line 48:5:   React Hook React.useCallback has a complex expression in the dependency array. Extract it to a separate variable so it can be statically checked                                                                                                                                                                                                      react-hooks/exhaustive-deps
6:24:10 AM:   Line 49:5:   React Hook React.useCallback has a complex expression in the dependency array. Extract it to a separate variable so it can be statically checked                                                                                                                                                                                                      react-hooks/exhaustive-deps
6:24:10 AM: src/views/customer/CustomerListView/data.tsx
6:24:10 AM:   Line 3:1:  Assign array to a variable before exporting as module default  import/no-anonymous-default-export
6:24:10 AM: src/views/customer/CustomerListView/index.tsx
6:24:10 AM:   Line 26:18:  '_reexecuteQuery1' is assigned a value but never used  @typescript-eslint/no-unused-vars
6:24:10 AM: src/views/product/ProductListView/data.tsx
6:24:10 AM:   Line 3:1:  Assign array to a variable before exporting as module default  import/no-anonymous-default-export
6:24:10 AM: src/views/test/GeneratedCustomersTable.tsx
6:24:10 AM:   Line 2:28:  'DataGrid' is defined but never used          @typescript-eslint/no-unused-vars
6:24:10 AM:   Line 6:15:  'columns' is assigned a value but never used  @typescript-eslint/no-unused-vars
6:24:10 AM: error Command failed with exit code 1.
6:24:10 AM: info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
6:24:10 AM: ​
6:24:10 AM: ────────────────────────────────────────────────────────────────
6:24:10 AM:   "build.command" failed                                        
6:24:10 AM: ────────────────────────────────────────────────────────────────
6:24:10 AM: ​
6:24:10 AM:   Error message
6:24:10 AM:   Command failed with exit code 1: yarn build
6:24:10 AM: ​
6:24:10 AM:   Error location
6:24:10 AM:   In Build command from Netlify app:
6:24:10 AM:   yarn build
6:24:10 AM: ​
6:24:10 AM:   Resolved config
6:24:10 AM:   build:
6:24:10 AM:     command: yarn build
6:24:10 AM:     commandOrigin: ui
6:24:10 AM:     publish: /opt/build/repo/build
6:24:11 AM: Caching artifacts
6:24:11 AM: Started saving node modules
6:24:11 AM: Finished saving node modules
6:24:11 AM: Started saving build plugins
6:24:11 AM: Finished saving build plugins
6:24:11 AM: Started saving yarn cache
6:24:11 AM: Finished saving yarn cache
6:24:11 AM: Started saving pip cache
6:24:11 AM: Finished saving pip cache
6:24:11 AM: Started saving emacs cask dependencies
6:24:11 AM: Finished saving emacs cask dependencies
6:24:11 AM: Started saving maven dependencies
6:24:11 AM: Finished saving maven dependencies
6:24:11 AM: Started saving boot dependencies
6:24:11 AM: Finished saving boot dependencies
6:24:11 AM: Started saving rust rustup cache
6:24:11 AM: Finished saving rust rustup cache
6:24:11 AM: Started saving go dependencies
6:24:11 AM: Finished saving go dependencies
6:24:14 AM: Build failed due to a user error: Build script returned non-zero exit code: 2
6:24:14 AM: Creating deploy upload records
6:24:14 AM: Failing build: Failed to build site
6:24:14 AM: Failed during stage 'building site': Build script returned non-zero exit code: 2
6:24:14 AM: Finished processing build request in 2m41.932037701s
jozef-slezak commented 3 years ago

@msvoro, prosim pories aj tieto WARNINGs, aby netlify pull req preview nenadaval

1:47:16 PM: Treating warnings as errors because process.env.CI = true.
1:47:16 PM: Most CI servers set it automatically.
1:47:16 PM: 
1:47:16 PM: Failed to compile.
1:47:16 PM: 
1:47:16 PM: src/theme/shadows.ts
1:47:16 PM:   Line 1:1:  Assign array to a variable before exporting as module default  import/no-anonymous-default-export
1:47:16 PM: src/theme/typography.ts
1:47:16 PM:   Line 1:1:  Assign object to a variable before exporting as module default  import/no-anonymous-default-export
1:47:16 PM: src/utils/getInitials.ts
1:47:16 PM:   Line 1:1:  Assign arrow function to a variable before exporting as module default  import/no-anonymous-default-export
1:47:16 PM: src/views/customer/CustomerListView/UpdateCustomer.tsx
1:47:16 PM:   Line 34:10:  'state' is assigned a value but never used                                                                                                                                                                                                                                                                                                            @typescript-eslint/no-unused-vars
1:47:16 PM:   Line 44:6:   React Hook React.useCallback has missing dependencies: 'customer?.email', 'customer?.name', 'customer?.phone', 'handleClose', 'newEmail', 'newName', and 'newPhoneNumber'. Either include them or remove the dependency array. If 'handleClose' changes too often, find the parent component that defines it and wrap that definition in useCallback  react-hooks/exhaustive-deps
1:47:16 PM:   Line 47:5:   React Hook React.useCallback has a complex expression in the dependency array. Extract it to a separate variable so it can be statically checked                                                                                                                                                                                                      react-hooks/exhaustive-deps
1:47:16 PM:   Line 48:5:   React Hook React.useCallback has a complex expression in the dependency array. Extract it to a separate variable so it can be statically checked                                                                                                                                                                                                      react-hooks/exhaustive-deps
1:47:16 PM:   Line 49:5:   React Hook React.useCallback has a complex expression in the dependency array. Extract it to a separate variable so it can be statically checked                                                                                                                                                                                                      react-hooks/exhaustive-deps
1:47:16 PM: src/views/customer/CustomerListView/data.tsx
1:47:16 PM:   Line 3:1:  Assign array to a variable before exporting as module default  import/no-anonymous-default-export
1:47:16 PM: src/views/customer/CustomerListView/index.tsx
1:47:16 PM:   Line 26:18:  '_reexecuteQuery1' is assigned a value but never used  @typescript-eslint/no-unused-vars
1:47:16 PM: src/views/product/ProductListView/data.tsx
1:47:16 PM:   Line 3:1:  Assign array to a variable before exporting as module default  import/no-anonymous-default-export
1:47:16 PM: src/views/test/GeneratedCustomersTable.tsx
1:47:16 PM:   Line 2:28:  'DataGrid' is defined but never used          @typescript-eslint/no-unused-vars
1:47:16 PM:   Line 6:15:  'columns' is assigned a value but never used  @typescript-eslint/no-unused-vars
1:47:16 PM: error Command failed with exit code 1.
1:47:16 PM: info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
1:47:16 PM: