Issue upgrading to Prettier 3
envgap__prettier__eslint-plugin-prettier-562
01 / FAILURE SIGNATURE
As reported upstream
TypeError: prettier.resolveConfig.sync is not a function
Not a benchmark task.
- The project already builds and runs before the fix, so there is nothing to repair.
02 / ENVIRONMENT RECIPE
- Base commit
370e88fd9c43716658c7be5576ee57f3235778cb- Manifest
package.json- Reproduce
Awaiting issue-specific recipe- Run under trace
Awaiting a meaningful runtime command
03 / ORIGINAL ISSUE TEXT
prettier/eslint-plugin-prettier #562 · read the original issue
**What version of `eslint` are you using?**
8.44.0
**What version of `prettier` are you using?**
3.0.0
**What version of `eslint-plugin-prettier` are you using?**
4.2.1
**Please paste any applicable config files that you're using (e.g. `.prettierrc` or `.eslintrc` files)**
```
/* eslint-env node */
module.exports = {
plugins: ["@typescript-eslint", "prettier"],
extends: [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
],
rules: {
"prettier/prettier": "error",
},
settings: {
"import/resolver": {
typescript: {
alwaysTryTypes: true,
},
},
},
};
```
**What source code are you linting?**
private source code
**What did you expect to happen?**
Can run with prettier 3 like with prettier 2
**What actually happened?**
```
✖ eslint --quiet --fix:
Oops! Something went wrong! :(
ESLint: 8.44.0
TypeError: prettier.resolveConfig.sync is not a function
Occurred while linting REDACTED
Rule: "prettier/prettier"
at Program (/Users/REDACTED/REDACTED/REDACTED/node_modules/eslint-plugin-prettier/eslint-plugin-prettier.js:138:40)
at ruleErrorHandler (/Users/REDACTED/REDACTED/REDACTED/node_modules/eslint/lib/linter/linter.js:1050:28)
at /Users/REDACTED/REDACTED/REDACTED/node_modules/eslint/lib/linter/safe-emitter.js:45:58
at Array.forEach (<anonymous>)
at Object.emit (/Users/REDACTED/REDACTED/REDACTED/node_modules/eslint/lib/linter/safe-emitter.js:45:38)
at NodeEventGenerator.applySelector (/Users/REDACTED/REDACTED/REDACTED/node_modules/eslint/lib/linter/node-event-generator.js:297:26)
at NodeEventGenerator.applySelectors (/Users/REDACTED/REDACTED/REDACTED/node_modules/eslint/lib/linter/node-event-generator.js:326:22)
at NodeEventGenerator.enterNode (/Users/REDACTED/REDACTED/REDACTED/node_modules/eslint/lib/linter/node-event-generator.js:340:14)
at CodePathAnalyzer.enterNode (/Users/REDACTED/REDACTED/REDACTED/node_modules/eslint/lib/linter/code-path-analysis/code-path-analyzer.js:795:23)
at /Users/REDACTED/REDACTED/REDACTED/node_modules/eslint/lib/linter/linter.js:1085:32
```04 / LABELS
Labels from the report text only; not yet run
No supported category has been assigned.
Label rules and the text that matched
[]