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

[CRITICAL BUG] Mangled typing breaks numerous functions #23

Open
Funtime60 opened this issue Oct 20, 2024 · 1 comment
Open

[CRITICAL BUG] Mangled typing breaks numerous functions #23

Funtime60 opened this issue Oct 20, 2024 · 1 comment

Comments

@Funtime60
Copy link

Funtime60 commented Oct 20, 2024

At some point between the models in the src and those used by the NPM version, a number of types are being broken. I have noticed errors with the /library/onDeck endpoint yesterday and assumed it was my outdated plex server. My server returned integer strings instead of integers. Today I found it complaining that object.MediaContainer.Metadata[0].Media[0].Part[1].Stream[0].frameRate was NOT an integer. This prompted me to check the specs and find that the schema does NOT specify an integer.

upon examining the files provided by NPM for version 0.23.5 I found this file:
node_modules/@lukehagar/plexjs/sdk/models/operations/getmetadatabyratingkey.js
At line 70:
frameRate: z.number().int().optional(),
Clearly it's implying that the number is an int despite the the original schema. I'm not familiar enough with the workflow here to suggest a fix so for now I'm just going to manually patch this for my project.

@LukeHagar
Copy link
Owner

Hey @Funtime60!

Thank you for reporting this issue. I've forwarded it to the owners of the language generation and will let you know when I hear back.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Open Issues
Development

No branches or pull requests

2 participants