Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

Valentin Mihov's latest activity

Friday, September 11 2009
2227 batches: :conditions for each are applied to each Model.find within the each ... was updated in Ruby on Rails
Tuesday, September 08 2009
2791 ActiveRecord::Base.find_in_batches puts a with_scope into the block that is e... was updated in Ruby on Rails
Wednesday, August 19 2009
2791 ActiveRecord::Base.find_in_batches puts a with_scope into the block that is e... was updated in Ruby on Rails
  • Valentin Mihov
    Valentin Mihov commented at 9:19 AM

    The problem here is that when you make additional queries into a find_each block, the queries are affected in an unexpected behavior.

    Have a look at the unit te...

Thursday, June 11 2009
2791 ActiveRecord::Base.find_in_batches puts a with_scope into the block that is e... was updated in Ruby on Rails
  • Valentin Mihov
    Valentin Mihov commented at 5:15 PM

    Here is another fix of the problem. This time the with_scope is removed from the yield and no with_exclusive_scope is used. This one should be a better solution...

  • Valentin Mihov
    Valentin Mihov commented at 3:34 PM

    Here is the fix with adding with_exclusive_scope around the yield statement

  • Valentin Mihov
    Valentin Mihov created the ticket at 3:32 PM

    When you use find_in_batches it turns out that there is a with_scope that gets executed, which could lead to unexpected behavior. See the attached unit test for...

Tuesday, May 26 2009
2720 Model updates not working correctly when used in a migration and a table with... was updated in Ruby on Rails
  • Valentin Mihov
    Valentin Mihov commented at 3:49 PM

    Yes. It applies fluently.

    I will look around the code later and try to figure out a fix for the problem.

  • Valentin Mihov
    Valentin Mihov commented at 3:19 PM

    Thanks for the help!

    The issue persists on the master branch and on 2-3-stable. Should I submit separate patches with the test for these?
    Any naming conventions...

  • Valentin Mihov
    Valentin Mihov commented at 2:25 PM

    A quite simple unit test for the described issue. It shows the issue in a much more simple way than I described ;-) The unit test is written on the origin/2-2-s...

  • Valentin Mihov
    Valentin Mihov commented at 1:46 PM

    Should it be just a diff or I can branch the code in github and write the test there?