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: wait for concurrent operations to finish in initNewAndShutdownOld #239

Closed

Conversation

i-fix-retarded-bugs
Copy link

This PR

  • This PR fixes panic during library initialization by waiting for provider initialization to finish.

Related Issues

Fixes #238

How to test

Check that the panicking code listed in the issue no longer panics. It does not.

@i-fix-retarded-bugs i-fix-retarded-bugs requested a review from a team as a code owner December 13, 2023 14:28
@i-fix-retarded-bugs i-fix-retarded-bugs changed the title wait for concurrent operations to finish in initNewAndShutdownOld fix: wait for concurrent operations to finish in initNewAndShutdownOld Dec 13, 2023
@toddbaert
Copy link
Member

toddbaert commented Dec 13, 2023

Hey @i-fix-retarded-bugs , please see my comment here.

We definitely have some doc shortcomings here, and we certainly wouldn't expect any panics, so there may be a bug somewhere here. Additionally, we would expect the usage of a READY handler here to make sure the provider has initialized (that's the shortcoming in our tutorial).

However, we can't make this function sync. We could add a new function that behaves this way though (we have something similar in other SDKs). If you'd like to implement that, we'd accept that change (pending that you update all references to your username as mentioned).

@toddbaert
Copy link
Member

toddbaert commented Dec 13, 2023

Indeed, the panic here is the result of a bug in the flagd provider. I've opened an issue for that: open-feature/go-sdk-contrib#407.

Here is an issue to create a blocking version of this method, which you are free to help with if you're interested: #240

@toddbaert
Copy link
Member

Closing. See #238 (comment) and linked issues.

@toddbaert toddbaert closed this Dec 14, 2023
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

Successfully merging this pull request may close these issues.

[BUG] Panic when following getting started tutorial
2 participants