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

fix: setting up linter engine after consolidated API is finished #33049

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions app/client/src/ce/constants/ReduxActionConstants.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -933,6 +933,7 @@ const ActionTypes = {
SET_BUILDING_BLOCK_DRAG_START_TIME: "SET_BUILDING_BLOCK_DRAG_START_TIME",
RESET_BUILDING_BLOCK_DRAG_START_TIME: "RESET_BUILDING_BLOCK_DRAG_START_TIME",
CLOSE_QUERY_ACTION_TAB_SUCCESS: "CLOSE_QUERY_ACTION_TAB_SUCCESS",
LINT_SETUP: "LINT_SETUP",
};

export const ReduxActionTypes = {
Expand Down
1 change: 1 addition & 0 deletions app/client/src/sagas/InitSagas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,7 @@ export function* startAppEngine(action: ReduxAction<AppEnginePayload>) {
const allResponses: InitConsolidatedApi = yield call(getInitResponses, {
...action.payload,
});
yield put({ type: ReduxActionTypes.LINT_SETUP });
const { applicationId, toLoadPageId } = yield call(
engine.loadAppData,
action.payload,
Expand Down
2 changes: 1 addition & 1 deletion app/client/src/sagas/LintingSagas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ export function* initiateLinting(

export default function* lintTreeSagaWatcher() {
yield takeEvery(ReduxActionTypes.UPDATE_LINT_GLOBALS, updateLintGlobals);
yield takeEvery(ReduxActionTypes.START_EVALUATION, setupSaga);
yield takeEvery(ReduxActionTypes.LINT_SETUP, setupSaga);
}

export function* setupSaga(): any {
Expand Down
2 changes: 2 additions & 0 deletions app/client/src/sagas/__tests__/initSagas.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ describe("tests the sagas in initSagas", () => {
.next()
.call(getInitResponses, { ...action.payload })
.next(mockResponse.data)
.put({ type: ReduxActionTypes.LINT_SETUP })
.next()
.call(engine.loadAppData, action.payload, mockResponse.data)
.next({
applicationId: action.payload.applicationId,
Expand Down