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.

This project is archived and is in readonly mode.

Activity (RSS)

Saturday, May 03 2008
95 render_to_string changes Content_Type - regression? was updated
  • DHH
    • State changed from new to invalid
    by DHH at 5:01 PM

    Please update to edge and try again. Josh says its fixed in edge and there are tests to prove that. Reopen if you still have the problem on edge.

101 Custom rake task without desc not listed with rake --tasks was updated
  • Kyle Hargraves
    Kyle Hargraves commented at 3:19 PM

    This isn't a rails issue; it's just how rake works.

  • Sergey Vidyuk
    Sergey Vidyuk created the ticket at 3:12 PM

    Rake task without desc placed in lib/tasks/ not listed in rake --tasks output, but executes manually

100 Problem combining single table inheritance and a has_many relation was updated
  • Stefan Kroes
    Stefan Kroes commented at 2:24 PM
    Page.find(:all)
    

    should be

    Content.find(:all)
    

    Apologies.

  • Stefan Kroes
    Stefan Kroes created the ticket at 2:22 PM

    Hi all!

    I think I've found a bug that occurs when combining single table inheritance with a has_many relation.

    My models look something like this:

    class Con...
99 SQLite connection failing was updated
  • Jérôme
    • Assigned user set to Michael Koziarski
    by Jérôme at 12:13 PM
  • Jérôme
    Jérôme commented at 12:12 PM

    Since it work with 2.0-stable, could it be an issue with quoted table names ? As far as I can remember there are some recent commits related to that....

  • Jérôme
    Jérôme created the ticket at 12:05 PM

    Something's wrong with SQLite adapter:

    In rails edge console:

    >> Page.new
    ActiveRecord::StatementInvalid: Could not find table 'pages'
    	from /usr/home/www/...
98 [PATCH] h method is not aliased properly was updated
  • Aamer
    Aamer commented at 9:21 AM

    (Attaching patch)

  • Aamer
    Aamer created the ticket at 9:15 AM

    When you call html_escape(string) in a template, it will call the one defined in lib/action_view/template_handlers/erb.rb.

    However, if you call h instead of h...

Contributing to Rails was edited by Pratik in Ruby on Rails at 2:39 AM (+6 more edits)
90 Enhancement: Add support for named scopes with optional arguments was updated
  • duncanbeevers
    duncanbeevers commented at 2:06 AM

    No offense taken.

    I quite like the idea of having the scope itself emit its options, and I've realy come around on using class methods as scopes. Could be us...

  • MatthewRudy
    MatthewRudy commented at 1:00 AM

    btw...

    apologies if I seem harsh...

    I just love "named_scope"

    was playing with a similar idea a year ago,

    made my day seeing it in edge.

  • MatthewRudy
    MatthewRudy commented at 12:59 AM

    forgot to point out as well...

    Proc.new doesn't enforce the number of arguments,

    ends up the same as a lambda, but lambda will raise if it doesnt get its req...

  • MatthewRudy
    MatthewRudy commented at 12:58 AM

    I agree that the patch allows the (2nd argument == :symbol)

    but my feeling is that it isn't intuitive.

    (also, shouldn't it accept symbols and strings)

    if al...

  • duncanbeevers
    duncanbeevers commented at 12:52 AM

    Perhaps

    :scope_method
    
3 earlier changes…
  • MatthewRudy
    MatthewRudy commented at 12:50 AM

    can't think what the right name for the key to pass

    :scope_name doesnt feel right,

    as the "scope name" is the name we just gave it...

    so maybe :scope_option...

  • duncanbeevers
    duncanbeevers commented at 12:49 AM

    The provided patch allows for providing a method name as the scope using a symbol as the method name.

    def Topic < ActiveRecord::Base
      named_scope :written_b...
  • MatthewRudy
    MatthewRudy commented at 12:37 AM

    I don't know if I quite get the reason for this.

    and it seems less clear what's going on

    class Topic < ActiveRecord::Base
      named_scope :written_before, Pro...
97 Enhancement: Add scope_options inspection method to named_scope was created
  • duncanbeevers
    duncanbeevers created the ticket at 1:53 AM

    When generating complex options hashes for named scopes, it can be difficult to test that the scopes are generated correctly. By providing insight into the ge...

57 :through option for "named_scope" was updated
  • MatthewRudy
    MatthewRudy commented at 12:46 AM

    i think my current test example doesn't quite explain it well.

    the point is,

    why create a scope, just so you can combine it with another one.

    we want 1st co...

Friday, May 02 2008
96 Form helpers don't handle "question?" methods was created
  • Andrew Vit
    Andrew Vit created the ticket at 11:59 PM

    I'm carrying this forward from my Trac ticket (I rebased the changes to the current revision.)

    The form helpers currently don't account for boolean question m...

42 PostgreSQL: Use all config options in rake db:create was updated
  • Pete Deffendol
    Pete Deffendol commented at 11:58 PM

    Yes, but #86 deals with modifying rake db:test:purge to use the create_database method, and this one fixes rake db:create to pass all the database configuratio...

  • Michael Koziarski
    • State changed from new to resolved
    by Michael Koziarski at 11:45 PM

    This looks like #86

86 PostgreSQL: Use adapter's #create_database db:test:purge was updated
  • Michael Koziarski
    • Assigned user set to Michael Koziarski
    by Michael Koziarski at 11:43 PM

    Is there any reason this couldn't be extended to all the adapters and remove some of that heinous case code?

76 Review/reopen Ticket #9 and #10 please was updated
  • Michael Koziarski
    • State changed from new to invalid
    • Assigned user set to Rick
    by Michael Koziarski at 11:40 PM

    Done, sorry, we didn't realise you couldn't open them yourselves. Rick's having a think about the best way forward

10 Immediate flash values not accessible in tests was updated
9 Adding records to a has_many collection does not work on initialization was updated
57 :through option for "named_scope" was updated
  • duncanbeevers
    duncanbeevers commented at 11:02 PM

    I've been thinking about similar functionality, and thus far I've found it most flexible to simply specify composite scopes as proper methods.

    def self.writte...
  • MatthewRudy
    MatthewRudy commented at 8:43 PM

    thanks David,

    will get to that tomorrow.

82 Iterate over :has_many array with the join (:through) model was updated
  • Daniel Lunde
    Daniel Lunde commented at 4:42 PM

    Here's a real world example where I've needed to use each_with_join:

    class Feature < ActiveRecord::Base
      has_many :featured_items, :dependent => :destroy, :...
  • Daniel Lunde
    Daniel Lunde commented at 4:14 PM

    Pratik:

    It seems like the obvious thing to do, but there's a problem with it. Let me give a more complete example.

    >> pp frank.groups
    [#<Group id: 2, name:...
95 render_to_string changes Content_Type - regression? was created
  • Christian Seiler
    Christian Seiler created the ticket at 4:33 PM

    I'm using Rails 2.0.2. Th old trac ticket 6073 is closed (fixed) but I have exactly this problem (I can't see the proposed diff in base.rb, too)

    http://dev.ru...

Improve documentation coverage and ma... was committed by Repository at 3:23 PM
92 [FEATURE] More efficient session handling was updated
  • Andreas
    Andreas commented at 1:12 PM

    I know, there might be some problems depending on how you want the sessions to behave transaction-wise, but Rails sessions don't seem to have a defined behavio...

89 Errors in partials are reported as occurring in parent templates was updated
Capture view errors in ActionView::Te... was committed by Repository at 10:45 AM
Improve PartialTemplate tests http://... was committed by Repository at 10:45 AM
91 STI sub classes not loaded until parent is was updated
  • Frederick Cheung
    Frederick Cheung commented at 9:58 AM

    That will definitely be a problem. If they are both in container.rb, how can the dependencies mechanism know that if you hit const_missing for Doc you need to ...

  • Ian Ownbey
    Ian Ownbey commented at 2:51 AM

    ooooo all the STI are in the same file as the model. This could be creating the problem.

94 [FIX] quote_string don't work with some postgres drivers was created
  • Lars Kanis
    Lars Kanis created the ticket at 9:24 AM

    A special code path is used for postgres drivers that don't define PGconn.escape. This code path does not work and throws the following exception.

    Attached is...

78 Fixtures.identify should generate uniqueIDs was updated
  • vlad.zar (at gmail)
    vlad.zar (at gmail) commented at 8:06 AM

    String#hash doesn't need to generate unique value, it generates hash and do it pretty well :) Instead, if I see a method named *identify*, I expect unique valu...

71 [patch] change_table block was updated
  • Jeff Dean
    • Title changed from Add change_table to core? to [patch] change_table block
    by Jeff Dean at 4:58 AM

    Sorry to have taken your time with that - I've updated the patches to include tests that run in:

    • MySQL
    • PostgreSQL
    • SQLite3

    I don't have any of the other d...

93 Restore timestamps in model rollback was created
  • Xavier Noria
    Xavier Noria created the ticket at 3:12 AM

    The current implementation of rollback_active_record_state! does some housekeeping like restoring @new_record. If you rollback a model after it was once saved ...