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

Not compatible with strict loading by default #122

Open
joeldrapper opened this issue Jan 12, 2024 · 2 comments · May be fixed by #375
Open

Not compatible with strict loading by default #122

joeldrapper opened this issue Jan 12, 2024 · 2 comments · May be fixed by #375

Comments

@joeldrapper
Copy link

It looks like some of the queries aren't compatible with a strict_loading_by_default configuration.

With this configuration in application.rb, solid_queue doesn't work.

config.active_record.strict_loading_by_default = true

I will try to find some time to dig into his and open a fix.

@rosa
Copy link
Member

rosa commented Jan 17, 2024

Ooh, totally @joeldrapper! Thanks for pointing this out. I didn't think of strict_loading_by_default when I was working on this because we've never used that in our apps, so it didn't even cross my mind 😓 🤦‍♀️

If you have time to contribute a fix, that'd be incredible, but if not, we'll definitely tackle this down the road.

Thank you 🙏

JoeDupuis added a commit to JoeDupuis/solid_queue that referenced this issue Oct 7, 2024
Fixes rails#122

Allow an app to run in strict_loading_by_default mode by explicitly
turning off strict loading on all solid queue models.
@JoeDupuis JoeDupuis linked a pull request Oct 7, 2024 that will close this issue
@JoeDupuis
Copy link

JoeDupuis commented Oct 7, 2024

I spent an absurd amount of time trying to strict load the gem's models. 🤦
I don't think it's worth it. I opened a PR (#375) to turn strict loading off explicitly on the models. This will allow apps with strict_loading_by_default enabled to use the gem without crashing.

Here's the (WIP) patch to enable strict loading inside of the gem just to give an idea: JoeDupuis#1

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 a pull request may close this issue.

3 participants