Coder Social home page Coder Social logo

Comments (8)

cvincent avatar cvincent commented on June 14, 2024 1

👍 Just hit this issue upgrading from Rails 6.1 -> 7.0. For those Googling, the specific error message is: DescendantsTracker.clear was disabled because config.cache_classes = true.

from with_model.

nertzy avatar nertzy commented on June 14, 2024

There's no reason. I think your idea is a good one.

from with_model.

nertzy avatar nertzy commented on June 14, 2024

To give a little more context, we were running into issues years ago on an old project where with_model models would still exist in the descendants after a test was finished. We cleared the tracked descendants as a quick way to work around this problem.

from with_model.

kakuzei avatar kakuzei commented on June 14, 2024

Thank you for you answer.
How do you want to proceed to make this change available for everyone?

from with_model.

marcocarvalho avatar marcocarvalho commented on June 14, 2024

This is causing strange errors with STI.

image

I have one test that uses WithModel; after that test run, the next test that uses any STI will fail because one or more classes are not present on the descendants collection.

I was only able to spot this error because I turned on config.cache_classes

from with_model.

nertzy avatar nertzy commented on June 14, 2024

Fixed in #44

from with_model.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.