microsoft / azure-boards-estimate

MIT License
34 stars 24 forks source link

Build fails when running locally: --npm start #40

Closed jonahsebright closed 2 years ago

jonahsebright commented 3 years ago

After cloning, download and installing dependencies, the build fails when trying to run and watch:

Failed to compile.

C:/repos/azure-boards-estimate/src/pages/create/createReducer.ts
Type error: Argument of type '(state: { session: ISession; teams: ITeam[] | null; iterations: IIteration[] | null; cardSets: ICardSet[] | null; team: string; iteration: string; queryId: string; isCreating: boolean; sourceLocked: boolean; }, name: string) => void' is not assignable to parameter of type '(state: { session: any; teams: any | null; iterations: any | null; cardSets: any | null; team: string; iteration: string; queryId: string; isCreating: boolean; sourceLocked: boolean; }, payload: string) => void'.
  Types of parameters 'state' and 'state' are incompatible.
    Type '{ session: any; teams: any | null; iterations: any | null; cardSets: any | null; team: string; iteration: string; queryId: string; isCreating: boolean; sourceLocked: boolean; }' is not assignable to type '{ session: ISession; teams: ITeam[] | null; iterations: IIteration[] | null; cardSets: ICardSet[] | null; team: string; iteration: string; queryId: string; isCreating: boolean; sourceLocked: boolean; }'.
      Types of property 'session' are incompatible.
        Type '{ id: string; name: string; mode: SessionMode; version: number; source: SessionSource; sourceData?: string | any | undefined; createdAt: Date; createdBy: string; cardSet: string; onlyCreatorCanSwitch?: boolean | undefined; isLegacy?: boolean | undefined; }' is not assignable to type 'ISession'.
          Types of property 'sourceData' are incompatible.
            Type 'string | { [x: number]: number; length: number; toString: () => string; toLocaleString: () => string; pop: () => number | undefined; push: (...items: number[]) => number; concat: { (...items: ConcatArray<number>[]): number[]; (...items: (number | ConcatArray<...>)[]): number[]; }; ... 25 more ...; flat: { ...; }; } ...' is not assignable to type 'string | number[] | undefined'.
              Type '{ [x: number]: number; length: number; toString: () => string; toLocaleString: () => string; pop: () => number | undefined; push: (...items: number[]) => number; concat: { (...items: ConcatArray<number>[]): number[]; (...items: (number | ConcatArray<...>)[]): number[]; }; ... 25 more ...; flat: { ...; }; }' is not assignable to type 'string | number[] | undefined'.
                Type '{ [x: number]: number; length: number; toString: () => string; toLocaleString: () => string; pop: () => number | undefined; push: (...items: number[]) => number; concat: { (...items: ConcatArray<number>[]): number[]; (...items: (number | ConcatArray<...>)[]): number[]; }; ... 25 more ...; flat: { ...; }; }' is not assignable to type 'number[]'.
                  Property '[Symbol.iterator]' is missing in type '{ [x: number]: number; length: number; toString: () => string; toLocaleString: () => string; pop: () => number | undefined; push: (...items: number[]) => number; concat: { (...items: ConcatArray<number>[]): number[]; (...items: (number | ConcatArray<...>)[]): number[]; }; ... 25 more ...; flat: { ...; }; }'.  TS2345

    37 | const setName = reducerAction(
    38 |     Actions.setName,
  > 39 |     (state: ICreateSessionState, name) => {
       |     ^
    40 |         state.session.name = name;
    41 |     }
    42 | );
MOlausson commented 3 years ago

@jonahsebright We're looking into this, it looks like a dependency version issue.

jonahsebright commented 3 years ago

Thank you for looking into the issue. Is it possible for you to recreate the problem? Would it be possible, if you could look into the issue soon, because I would like to address the feature about showing the acceptance criteria and create a PR for that?

MOlausson commented 2 years ago

@jonahsebright we had to revert some changes to resolve the build issue. PR #48 fixes the build problem.