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 migration crash #1510

Merged
merged 1 commit into from
Nov 18, 2023
Merged

Fix migration crash #1510

merged 1 commit into from
Nov 18, 2023

Conversation

cewert
Copy link
Member

@cewert cewert commented Nov 16, 2023

I tracked this down to a bad line of code I wrote in migrations.bs. It's trying to use m.global.session.server.id but it will always be invalid at this point in the app when the function is called. We should just remove it instead of fixing it because what it's trying to do makes no sense anyway - the active server id is staying on the global "jellyfin" block and doesn't need to be migrated anywhere.

One bad thing about brighterscript is that the lines shown on error logs are for the transpiled files and not the source files. I forgot this and couldn't figure out how line 18 in migrations (from the error tracestack) was writing to the reg but when I checked build/staging/ the line number matched the right line of code: registry_write("serverId", m.global.session.server.id, savedUserId)

283579710-9fd4db77-36ce-4205-9873-bbdfd4da2e3b

@cewert cewert added the bug-fix This fixes a bug. label Nov 16, 2023
@cewert cewert requested a review from a team as a code owner November 16, 2023 23:22
Copy link
Member

@1hitsong 1hitsong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixes the 1.6.6 -> 2.0 start up crash I was having.

@1hitsong 1hitsong merged commit 1a470ed into jellyfin:unstable Nov 18, 2023
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug-fix This fixes a bug.
Projects
Development

Successfully merging this pull request may close these issues.

2 participants