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

React Query: Regression in 6.25.0 caused by #1207 #1227

Closed
melloware opened this issue Feb 18, 2024 · 5 comments · Fixed by #1228
Closed

React Query: Regression in 6.25.0 caused by #1207 #1227

melloware opened this issue Feb 18, 2024 · 5 comments · Fixed by #1228
Assignees
Labels
bug Something isn't working
Milestone

Comments

@melloware
Copy link
Collaborator

melloware commented Feb 18, 2024

Regression caused by #1207

@soartec-lab this broke React Query in 6.25.0 I now get these TypeScript errors.

  Line 26:40:  Don't use `{}` as a type. `{}` actually means "any non-nullish value".
- If you want a type meaning "any object", you probably want `object` instead.
- If you want a type meaning "any value", you probably want `unknown` instead.

in 6.24.0 code was this

export interface FilterConstraint {
	/** Filter match mode e.g. equals, notEquals, contains, notContains, gt, gte, lt, lte */
	matchMode?: string;
	/** Value to filter this column by */
	value?: unknown;
}

in 6.25.0 its this...

/**
 * Value to filter this column by
 */
export type FilterConstraintValue = {};

export interface FilterConstraint {
	/** Filter match mode e.g. equals, notEquals, contains, notContains, gt, gte, lt, lte */
	matchMode?: string;
	/** Value to filter this column by */
	value?: FilterConstraintValue;
}

Which is now broken.

@melloware melloware added the bug Something isn't working label Feb 18, 2024
@melloware melloware added this to the 6.26.0 milestone Feb 18, 2024
@soartec-lab
Copy link
Member

@melloware
Wow, the value of type is now {} instead of unknown. Could you please provide a schema that reproduces the problem?

@melloware
Copy link
Collaborator Author

melloware commented Feb 19, 2024

Attached in the zip file is my openapi.json and orval.ts config!
orval-1227.zip

@soartec-lab
Copy link
Member

thanks!

@melloware
Copy link
Collaborator Author

Just an FYI this is my public project where I use Orval and detected the issue: https://github.com/melloware/quarkus-primereact

@soartec-lab
Copy link
Member

Thank you. I haven't had time recently, but I think I'll be able to respond next week.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants