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

TypeError: globalScope.__defineGeneric is not a function on define-flow-type #524

Open
maxdygaf opened this issue Jan 10, 2023 · 6 comments

Comments

@maxdygaf
Copy link

Es lint errors when there is not defined type

Oops! Something went wrong! :(

ESLint: 8.31.0

TypeError: globalScope.__defineGeneric is not a function
Occurred while linting /home/st.cremer/Сайты/flow/src/services/training/trainingTypes.js:7
Rule: "flowtype/define-flow-type"
    at makeDefined (/home/st.cremer/Сайты/flow/node_modules/eslint-plugin-flowtype/dist/rules/defineFlowType.js:21:21)
    at GenericTypeAnnotation (/home/st.cremer/Сайты/flow/node_modules/eslint-plugin-flowtype/dist/rules/defineFlowType.js:49:9)
    at ruleErrorHandler (/home/st.cremer/Сайты/flow/node_modules/eslint/lib/linter/linter.js:1115:28)
    at /home/st.cremer/Сайты/flow/node_modules/eslint/lib/linter/safe-emitter.js:45:58
    at Array.forEach (<anonymous>)
    at Object.emit (/home/st.cremer/Сайты/flow/node_modules/eslint/lib/linter/safe-emitter.js:45:38)
    at NodeEventGenerator.applySelector (/home/st.cremer/Сайты/flow/node_modules/eslint/lib/linter/node-event-generator.js:297:26)
    at NodeEventGenerator.applySelectors (/home/st.cremer/Сайты/flow/node_modules/eslint/lib/linter/node-event-generator.js:326:22)
    at NodeEventGenerator.enterNode (/home/st.cremer/Сайты/flow/node_modules/eslint/lib/linter/node-event-generator.js:340:14)
    at CodePathAnalyzer.enterNode (/home/st.cremer/Сайты/flow/node_modules/eslint/lib/linter/code-path-analysis/code-path-analyzer.js:795:23)
@ajmeese7
Copy link

I am running into a similar error on my end:

[eslint] Error while loading rule 'flowtype/define-flow-type': context.getAllComments is not a function

Any advice would be appreciated!

@chaitanya1248
Copy link

I am running into a similar error on my end:

[eslint] Error while loading rule 'flowtype/define-flow-type': context.getAllComments is not a function

Any advice would be appreciated!

Having the same issue. no clue on it

@TharunKumarSoppari
Copy link

TharunKumarSoppari commented Aug 14, 2024

ERROR in [eslint] Error while loading rule 'flowtype/define-flow-type': context.getAllComments is not a function

Occurred while linting

Any clue on it ?

@kien-qs
Copy link

kien-qs commented Aug 20, 2024

I am running into a similar error on my end:

[eslint] Error while loading rule 'flowtype/define-flow-type': context.getAllComments is not a function

Any advice would be appreciated!

I am having the same issue after I updated the "eslint" to the newest version (from 8.57.0 to 9.9.0)
I had also tried some others v9.x.x versions and it also ended up with this error
Is anyone have any solution for this, it is really annoyed 😔

@dennisat
Copy link

Same here

@dennisat
Copy link

This is 1,5yars open issue!!! Does anybody know a workaround???

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

No branches or pull requests

6 participants