Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: rails/rails
...
head fork: rails/rails
This comparison is big! We're only showing the most recent 250 commits
Commits on May 19, 2012
@rafaelfranca rafaelfranca Merge pull request #6396 from kennyj/dont_use_assert_block
Don't use assert_block method. It will be removed.
777d539
@kennyj kennyj Fix a problem of translate_exception method in Japanese. 2fe2813
@pmahoney pmahoney Synchronize read and modification of @reserved_connections hash to av…
…oid concurrency error.
c2d416f
@oscardelben oscardelben Getting started guide has been completely rewritten and edited. 05fdb31
@oscardelben oscardelben Typo fae4a26
@oscardelben oscardelben Revert typo ba896d3
@tenderlove tenderlove Merge pull request #6398 from pmahoney/threadsafe-connection-pool
Synchronize read and modification of @reserved_connections
23fad29
@tenderlove tenderlove Merge pull request #6397 from kennyj/fix_translate_exception
Fix a problem of translate_exception method in a Japanese (non English) environment.
fa41c92
Francesco Rodriguez add CollectionProxy#find documentation 952737a
Francesco Rodriguez add CollectionProxy#select documentation a6940f2
@henrikhodne henrikhodne Update documentation for AbstractController::Base 7eb09ae
@henrikhodne henrikhodne Remove blank trailing comments
For future reference, this is the regex I used: ^\s*#\s*\n(?!\s*#). Replace
with the first match, and voilà! Note that the regex matches a little bit too
much, so you probably want to `git add -i .` and go through every single diff
to check if it actually should be changed.
fa6d921
Commits on May 20, 2012
@drogus drogus Merge pull request #5631 from avakhov/ac-log-subsriber-small-refac
Make AC::LogSubscriber#send_file like #send_data
da97cf0
@route route Show in log correct wrapped keys 32a433e
@drogus drogus Merge pull request #5702 from oscardelben/patch-4
Call undefine_attribute_methods only when defining new attributes
cae1ca7
@drogus drogus Improve docs for `try` by adding note on `BasicObject`
[ci skip] closes #5790
2575508
@josevalim josevalim Merge pull request #6050 from route/wrapped_keys_in_log
Show in log correct wrapped keys
3655d66
@dchelimsky dchelimsky Raise Assertion instead of RoutingError for routing assertion failures.
Before this change, assert_recognizes, assert_generates, and
assert_routing raised ActionController::RoutingError when they failed to
recognize the route.

This commit changes them to raise Assertion instead. This aligns with
convention for logical failures, and supports reporting tools that care
about the difference between logical failures and errors e.g. the
summary at the end of a test run.

- Fixes #5899
dcce011
@josevalim josevalim Merge pull request #6399 from dchelimsky/issue-5899
Raise Assertion instead of RoutingError for routing assertion failures.
ed024f6
@vijaydev vijaydev fix closing tag [ci skip] ad3f47d
@pixeltrix pixeltrix Correct order of expected and actual arguments 972376a
@pixeltrix pixeltrix Raise ActionController::BadRequest for malformed parameter hashes.
Currently Rack raises a TypeError when it encounters a malformed or
ambiguous hash like `foo[]=bar&foo[4]=bar`. Rather than pass this
through to the application this commit captures the exception and
re-raises it using a new ActionController::BadRequest exception.

The new ActionController::BadRequest exception returns a 400 error
instead of the 500 error that would've been returned by the original
TypeError. This allows exception notification libraries to ignore
these errors if so desired.

Closes #3051
66eb3f0
@pixeltrix pixeltrix Return 400 Bad Request for URL paths with invalid encoding.
Passing path parameters with invalid encoding is likely to trigger errors
further on like `ArgumentError (invalid byte sequence in UTF-8)`. This will
result in a 500 error whereas the better error to return is a 400 error which
allows exception notification libraries to filter it out if they wish.

Closes #4450
3fc561a
@pixeltrix pixeltrix Escape the extension when normalizing the action cache path.
Although no recognized formats use non-ASCII characters, sometimes they
can be included in the :format parameter because of invalid URLS. To
prevent encoding incompatibility errors we need to escape them before
passing the path to URI.unescape.

Closes #4379
79b38c3
@drogus drogus Revert "Merge pull request #5702 from oscardelben/patch-4"
This reverts commit cae1ca7, reversing
changes made to da97cf0.

These changes break the build, it needs more investigation.
08a5b10
@ivankukobko ivankukobko fixed typo in word finiding 45d059b
@carlosantoniodasilva carlosantoniodasilva Merge pull request #6408 from ivankukobko/master
Fixed typo in AR test name
46fcce9
Francesco Rodriguez update CollectionProxy#destroy_all documentation 03402d2
@rafaelfranca rafaelfranca Fix CHANGELOG order and add a brief description of the changes in the
Action Pack in the upgrading guide. [ci skip]
a78ee05
@josevalim josevalim Merge pull request #6407 from pinetops/565c1b0a0772ac6cf91c77e9285806…
…f7b028614c

Template concurrency fixes
Conflicts:

	actionpack/lib/action_view/template.rb
74c4e7b
@drogus drogus Fix generators to help with ambiguous `ApplicationController` issue
In development mode, dependencies are loaded dynamically at runtime,
using `const_missing`. Because of that, when one of the constants is
already loaded and `const_missing` is not triggered, user can end up
with unexpected results.

Given such file in an Engine:

```ruby
module Blog
  class PostsController < ApplicationController
  end
end
```

If you load it first, before loading any application files, it will
correctly load `Blog::ApplicationController`, because second line will
hit `const_missing`. However if you load `ApplicationController` first,
the constant will be loaded already, `const_missing` hook will not be
fired and in result `PostsController` will inherit from
`ApplicationController` instead of `Blog::ApplicationController`.

Since it can't be fixed in `AS::Dependencies`, the easiest fix is to
just explicitly load application controller.

closes #6413
7c95be5
Commits on May 21, 2012
@pmahoney pmahoney Make connection pool fair with respect to waiting threads. d06674d
@drogus drogus More info on commit messages in contributing guide
Add more info on how to write a good commit messages along with
example showing nicely formatted commit message.

Rails git history does not look too well when you try to figure out why
particular changes were introduced. We can do much better than that and
it's never too late to start.
ae8b09c
Francesco Rodriguez add CollectionProxy#destroy documentation d831734
@avakarev avakarev Refactoring: turn unless/else into if/else ff83df3
@jeremy jeremy Merge pull request #6424 from avakarev/refactoring_unless-else
Refactoring: just turn unless/else into if/else
9c3cd9c
@tenderlove tenderlove Merge pull request #6143 from senny/composed_of_converter_returns_nil
allow the :converter Proc form composed_of to return nil
525839f
Francesco Rodriguez improve CollectionProxy#destroy documentation 1f5c1a1
Francesco Rodriguez add CollectionProxy#reload documentation 158a71b
Francesco Rodriguez fix CollectionProxy documentation markup ab2e2a9
@tenderlove tenderlove Merge pull request #6416 from pmahoney/threadsafe-connection-pool
Make connection pool fair with respect to waiting threads.
d2901f0
@tenderlove tenderlove Merge pull request #2549 from trek/RoutingErrorForMissingControllers
When a route references a missing controller, raise ActionController::RoutingError with clearer message
513a052
@pinetops pinetops Make the Resolver template cache threadsafe - closes #6404
The Template cache in the Resolver can be accessed by multiple threads
similtaneously in multi-threaded environments. The cache is implemented
using a Hash, which isn't threadsafe in all VMs (notably JRuby).

This commit extracts the cache to a new Cache class and adds mutexes to
prevent concurrent access.
685192b
@pinetops pinetops More granular locking of the Resolver template cache
In order to avoid holding a global lock when doing template
resolution, instead add individual locks on a per cache entry
basis. The global lock is now only used for manipulation of the main
cache data structure.
719b008
@tenderlove tenderlove Merge pull request #6425 from pinetops/resolver_concurrency_fix
Resolver concurrency fix
254c042
@josevalim josevalim Revert "Merge pull request #6425 from pinetops/resolver_concurrency_fix"
This reverts commit 254c042, reversing
changes made to 513a052.
776ea10
@marcandre marcandre Fix bug when Rails.application is defined but is nil. See #881 89ebd28
@carlosgaldino carlosgaldino Add HTML5 input[type="color"] helper 1ce4b5b
@carlosgaldino carlosgaldino Add several HTML5 input helpers
The input types added are:

- input[type="month"]

- input[type="week"]

- input[type="datetime"]

- input[type="datetime-local"]
b02d14a
@avakhov avakhov Add instance_accessor option to class_attribute e4569b5
@carlosantoniodasilva carlosantoniodasilva Merge pull request #5156 from avakhov/class-attribute-instance-accessor
Add instance_accessor option to class_attribute
f260dc5
@carlosantoniodasilva carlosantoniodasilva Refactor aggregation writer method
Only constantize class_name once.
d5d9a28
@carlosantoniodasilva carlosantoniodasilva Remove not used variables from connection poll test
These variables were issuing some "not used" warnings.
03886d8
@avakhov avakhov Fix AR preloader example 5b7b705
@chancancode chancancode Restore the frozen state on rollback. Fixes #6417.
Currently, when saving a frozen record, an exception would be thrown
which causes a rollback. However, there is a bug in active record that
"defrost" the record as a side effect:

    >> t = Topic.new
    => #<Topic id: nil, ...>
    >> t.freeze
    => #<Topic id: nil, ...>
    >> t.save
    RuntimeError: can't modify a frozen Hash
    >> t.frozen?
    => false
    >> t.save
    => true

This patch fixes the bug by explictly restoring the frozen state on the
attributes Hash after every rollback.
cb847b9
@carlosantoniodasilva carlosantoniodasilva Merge pull request #6429 from marcandre/fix_test_request
Fix bug when Rails.application is defined but is nil. See #881
c5fc159
@tenderlove tenderlove using __method__ for the command method calls edb87b1
Commits on May 22, 2012
@NZKoz NZKoz Merge pull request #5125 from winston/log_exception_when_cache_read_f…
…ails

#read_entry in ActiveSupport::Cache::FileStore should log details of the exception when an exception is thrown
e44009a
@drogus drogus Merge pull request #6420 from chancancode/master_restore_frozen_state…
…_on_rollback

Restore frozen state on rollback, fixes #6417
1447aca
Francesco Rodriguez add CollectionProxy#delete_all documentation f9a718e
Francesco Rodriguez update CollectionProxy#delete_all documentation 1bcd5e4
Francesco Rodriguez update CollectionProxy#clear documentation 8281194
@avakhov avakhov Use relative path to sqlite3 db in `rails db` command
Rails uses sqlit3 db file with a path relative to the rails root. It
allows to execute server not from rails root only. For example you
can fire `./spec/dummy/script/rails s` to start dummy application
server if you develop some engine gem.

Now the `rails db` command uses relative paths also and you can explore
your dummy db via `./spec/dummy/script/rails db` command.
a060c41
@avakhov avakhov Fix `rails db -h` and cosmetic fixes in usage banners
Ruby tries to use '-h' as short version of '--header' by default
https://github.com/ruby/ruby/blob/trunk/lib/optparse.rb#L1372-1381.
To force `rails db -h` prints an usage message we should add the `-h`
options explicitly.
1fed1f1
@gaurish gaurish Fix broken link 4220290
@drogus drogus Merge pull request #6150 from avakhov/dbconsole-fixes
Rails db console improvements
d22859e
@avakhov avakhov Remove obsolete comment from generator gem method
This comment about :env option for gem method was actual for rails 2.3
without bundler. Now bundler uses grups for this goal.
09be692
@janx janx remove useless require 3ed92c8
@drogus drogus Use require_dependency in generated controllers
Using require in development mode will prevent required files from
reloading, even if they're changed. In order to keep namespaced
application_controller reloadable, we need to use require_dependency
instead of require.
29d17d3
@drogus drogus Merge pull request #6435 from janx/remove_useless_require
remove useless require
0638e6b
@avakhov avakhov Use new hash syntax for generators gem method
The Gemfile of new application uses ruby 1.9 hashes. Gem method of
generators should use them too. It prevents from mixing two kinds of
syntax in one file.
fe7038e
@josevalim josevalim Merge pull request #6437 from avakhov/gen-gem-method
Use new hash syntax for generators gem method
f909e14
@janx janx refactor lazy_load_hooks load position a807db9
@josevalim josevalim Merge pull request #6439 from janx/remove_useless_require
refactor lazy_load_hooks load position, fix #6435
6b9f077
@gaurish gaurish Remove Obsolute root specifiying short syntax
This syntax does not seem to work. Throws the error
  "can't convert String into Hash (TypeError)"

Tested on:
* Ruby 1.9.3
* Rails 3.2.3
feaa7b3
Andrey Voronkov Convert Hash to HashWithIndifferentAccess in ActiveRecord::Store.
In order to make migration from 3.x apps easier, we should try to
convert
Hash instances to HashWithIndifferentAccess, to allow accessing values
with both symbol and a string. This is follow up to changes in 3c0bf04.
940c135
@gaurish gaurish Move root method at TOP of routes file
Made the change as per the following text in routing guide:-
"You should put the root route at the top of the file,
because it is the most popular route and should be matched first."

However, if root is best left at bottom. We will change to fix that text
43fa48e
@jeremy jeremy Merge pull request #6368 from Antiarchitect/store-indifferent-access
Support migrating from Hash to HashWithIndifferentAccess for accessing attributes.
d3ee0a2
@spastorino spastorino require active_support/lazy_load_hooks where is needed 38293ea
@jeremy jeremy Merge pull request #6440 from gaurish/route_move_top
Move root method at TOP of routes file
1d4d731
Francesco Rodriguez remove repeated documentation in CollectionProxy#clear d1cab8e
@spastorino spastorino Fix the build 344ea04
@oscardelben oscardelben The initialization guide will cover Rails 4 acdf8ac
@oscardelben oscardelben [Guides] change rails bin section d4d8794
@oscardelben oscardelben [Guides] Review bin/rails section 987a74d
@oscardelben oscardelben [Guides] Change bundler section ba55dd5
@oscardelben oscardelben [Guides] Update rails commands section 63f094b
Francesco Rodriguez add CollectionProxy#build documentation 2c62dd6
Francesco Rodriguez adding :call-seq: to CollectionProxy methods 21f4c2e
Francesco Rodriguez add more examples to CollectionProxy#find e0859e5
Francesco Rodriguez add CollectionProxy#create documentation 9c38cfc
Francesco Rodriguez add CollectionProxy#create! documentation 7e5beca
Francesco Rodriguez add :call-seq: to +first+ and +last+ CollectionProxy methods 3e847af
Francesco Rodriguez add CollectionProxy#size documentation f539d98
Francesco Rodriguez add CollectionProxy#length documentation eb2c0a4
@rafaelfranca rafaelfranca Revert "Merge pull request #6416 from pmahoney/threadsafe-connection-…
…pool"

This reverts commit d2901f0, reversing
changes made to 525839f.

Conflicts:
	activerecord/test/cases/connection_pool_test.rb

Reason: This change broke the build (http://travis-ci.org/#!/rails/rails/builds/1391490)
and we don't have any solution until now. I asked the author to try to
fix it and open a new pull request.
7c69e2d
@roryokane roryokane clarified how file naming affects load order of initializers f09c84c
@parndt parndt Fixed typo new_defautls -> new_defaults.
* Added tests for 'else' case in ActionView::Helpers::TranslationHelper#wrap_translate_defaults
* Also updated the testing syntax of translation.html_safe? asserts to provide better output upon failure.
40c0b3a
@rafaelfranca rafaelfranca Merge pull request #6433 from parndt/fix_typo
Fixed typo new_defautls -> new_defaults.
5089d65
@jeremy jeremy Merge pull request #6359 from carlosgaldino/add-html5-inputs
Add HTML5 color and date/time inputs
65d2a60
@tenderlove tenderlove initialize our instance variables 8662722
@tenderlove tenderlove initialize instance variables 580333f
@tenderlove tenderlove use RUBY_PLATFORM in case of cross compiled ruby 1ca1b1a
Commits on May 23, 2012
@tenderlove tenderlove use File.realpath and avoid making Pathname objects 3f870f6
@tenderlove tenderlove I guess we have to return a pathname object. o_O d7de7a7
@carlosgaldino carlosgaldino Refactor date related helpers a9a9e8a
@carlosgaldino carlosgaldino Add tests for time_field and date_field helpers
These tests check the values of 'min' and 'max' input attrs
30847b4
@rafmagana rafmagana use ApplicationName::Application instead of ActionController::Dispatc…
…her.new since Dispatcher class no longer exists
83f62a0
@rafaelfranca rafaelfranca Merge pull request #6452 from carlosgaldino/refactor-date-helpers
Refactor date related input helpers
41cfe17
@parndt parndt Added ActionDispatch::Request::Session#keys and ActionDispatch::Reque…
…st::Session#values
6ac458d
@dgm dgm Fix incorrect example for fields_for - without the '=' it will not ou…
…tput anything.
2227064
@rafmagana rafmagana update loaded middlewares and use of Rack::Server instead of Rack::Bu…
…ilder
56ad6ca
@rafmagana rafmagana use ActionDispatch::MiddlewareStack instead of ActionController::Midd…
…lewareStack
7cabb57
@josevalim josevalim Merge pull request #6453 from parndt/session_keys
Added session.keys and session.values back to ActionDispatch::Request::Session
cb92efb
@ugisozols ugisozols Remove unnecessary comment. bd9953f
@carlosantoniodasilva carlosantoniodasilva Merge pull request #6455 from ugisozols/master
Remove unnecessary comment.
90d8c8a
@acapilleri acapilleri changed xml type datetime to dateTime, fixes #6328
XmlMini define the xml 'datatime', but according to
http://www.w3.org/TR/xmlschema-2/#dateTime could be better
change this to 'dateTime' with upper case letter 'T.
So 'DateTime' and 'Time' are redefined from 'datetime' to 'dateTime'

add the changing to the changelog
5646d65
@carlosantoniodasilva carlosantoniodasilva Merge pull request #6446 from acapilleri/mini_xml_4
Change xml type datetime to dateTime
a6d0e37
@markmcspadden markmcspadden Add Hash#transform_keys and Hash#transform_keys! and refactor *_keys …
…methods to use them.
6ff8873
@rafaelfranca rafaelfranca Merge pull request #6259 from markmcspadden/hash_transform_keys
Add Hash#transform_keys and Hash#transform_keys!
c1487f6
@lucashungaro lucashungaro Adding deep versions of stringify_keys and symbolize_keys (plain and …
…bang) for nested hashes
a4bb195
@oscardelben oscardelben [Guides] Rewrite server start section 05a4d8b
@oscardelben oscardelben [Guides] Rewrite server start section 13612ae
@oscardelben oscardelben [Guides] Fix sample code 07f7321
@jrochkind jrochkind ConnectionPool wait_timeout no longer used for different types of tim…
…eouts. #6441

An AR ConnectionSpec `wait_timeout` is pre-patch used for three
different things:

* mysql2 uses it for MySQL's own wait_timeout (how long MySQL
  should allow an idle connection before closing it), and
  defaults to 2592000 seconds.
* ConnectionPool uses it for "number of seconds to block and
  wait for a connection before giving up and raising a timeout error",
  default 5 seconds.
* ConnectionPool uses it for the Reaper, for deciding if a 'dead'
  connection can be reaped. Default 5 seconds.

Previously, if you want to change these from defaults, you need
to change them all together. This is problematic _especially_
for the mysql2/ConnectionPool conflict, you will generally _not_
want them to be the same, as evidenced by their wildly different
defaults. This has caused real problems for people #6441 #2894

But as long as we're changing this, forcing renaming the
ConnectionPool key to be more specific, it made sense
to seperate the two ConnectionPool uses too -- these two
types of ConnectionPool timeouts ought to be able to be
changed independently, you won't neccesarily want them
to be the same, even though the defaults are (currently)
the same.
cb6f839
@carlosantoniodasilva carlosantoniodasilva Merge pull request #6060 from lucashungaro/master
Adding deep versions of stringify_keys and symbolize_keys (plain and bang) for nested hashes
541429f
@betamatt betamatt Add license field to gemspecs, by Matt Griffin 6c7b250
@tenderlove tenderlove Merge pull request #6463 from jrochkind/connection_pool_timeout_keys
ConnectionPool wait_timeout no longer used for different types of timeouts. #6441
43893f3
@vijaydev vijaydev copy edit[ci skip] 2642c29
@vijaydev vijaydev Revert "Remove blank trailing comments"
This reverts commit fa6d921.

Reason: Not a fan of such massive changes. We usually close such changes
if made to Rails master as a pull request. Following the same principle
here and reverting.

[ci skip]
1ad0b37
@vijaydev vijaydev Revert "Remove Obsolute root specifiying short syntax"
This reverts commit feaa7b3.

Reason: Incorrect change. That's a Rails 4 feature and will not
obviously work in 3.2.3.

[ci skip]
d31b765
@josevalim josevalim Merge pull request #6462 from grosser/feature/licenses
Add license field to gemspecs, by Matt Griffin
92fd212
@vijaydev vijaydev copy edits in collection proxy docs [ci skip] 1c94868
@vijaydev vijaydev Merge pull request #6194 from ayrton/optimized_images
Optimizing all images used in the guides
030e04f
@vijaydev vijaydev Merge pull request #6383 from oscardelben/add_oscardelben_to_authors
Add oscardelben to authors
9ae0c66
@vijaydev vijaydev Merge branch 'master' of github.com:lifo/docrails 91305ad
@chancancode chancancode Added instructions for backporting changes to guides.
I was looking for instructions on backporting changes the other day and
wasn't able to find it anywhere. I updated the contrib guides based on
the disccusion in #6420, #6215 and #6447.
c97fb88
@markmcspadden markmcspadden Add Hash#deep_transform_keys and Hash#deep_transform_keys! Also conve…
…rt deep_*_keys to use deep_transform_keys.
2b5b60f
@rafaelfranca rafaelfranca PGconn doesn't accepts :checkout_timeout option.
This option was added on cb6f839
renaming the :wait_timeout option.

Fix build http://travis-ci.org/#!/rails/rails/jobs/1413405
925f6bd
@rafaelfranca rafaelfranca Whitespaces :scissors: 82b05fb
@rafaelfranca rafaelfranca Merge pull request #6466 from markmcspadden/hash_deep_transform_keys
Add Hash#deep_transform_keys and Hash#deep_transform_keys! Also convert ...
7a23ada
@Mik-die Mik-die typos 03fa708
@tenderlove tenderlove use File.join to decrease dependencies on Pathname 4e5175e
@tenderlove tenderlove removing more pathnameisms 4001835
@tenderlove tenderlove require the constants we use. ensure that root always returns a Pathname d77b576
@tenderlove tenderlove Revert "require the constants we use. ensure that root always returns…
… a Pathname"

This reverts commit d77b576.
9875574
@tenderlove tenderlove use File.join rather than depend on Pathname 880481a
Commits on May 24, 2012
@parndt parndt Fixed backward incompatibility for engines.
- Many engines rely on being able to join directories to the Rails root:

    Rails.root.join('somedir')

- This was now impossible because Rails.root returned a String:

    NoMethodError: undefined method `join' for "/code/myrailsapp":String

- This was broken in 4001835
66db0b9
@drogus drogus Merge pull request #6447 from chancancode/add_backporting_instruction…
…s_to_contrib_guides

Added instructions for backporting changes to guides.
95c49f2
@josevalim josevalim Merge pull request #6471 from parndt/rails_root_should_be_join_able
Fixes possible backward incompatibility
abccf82
@roryokane roryokane grammar fixes in a tip in Rails routing guide aa54d29
@roryokane roryokane capitalize HTML5 in Getting Started Guide f1c2727
@oscardelben oscardelben [Guides] Add sprockets to list of loaded frameworks f2c60c7
@oscardelben oscardelben [Guides] Update ruby version check f819b90
@oscardelben oscardelben [Guides] Add extract_options section 27874a8
@oscardelben oscardelben [Guides] Rewrite Rails application section cd6aa9f
@oscardelben oscardelben [Guides] Add core_ext/object section 2ccc210
@oscardelben oscardelben [Guides] Update rack example 0b11840
@schneems schneems /rails/info/routes path shows routing information
Will show similar contents to the output of `$ rake routes` in the browser in development. This speeds the time required to generate routes, since the application is already initialized.
cb44e0f
@schneems schneems Rails::InfoController tests passing
This includes new tests for /rails/info/routes
c3e3102
@pixeltrix pixeltrix Merge pull request #6461 from schneems/schneems/sextant-routes
View your Routes without waiting on Rake
8186754
@rafaelfranca rafaelfranca Use deep_dup in the deep_transform_keys tests.
Using only dup make some tests to not catch up an implementation error
because the methods were changing the nested hashes.

Related to:
541429f#L1R96
b0ebdf3
@carlosantoniodasilva carlosantoniodasilva Merge pull request #5925 from Juanmcuello/pg_structure_dump
Quote arguments in db:structure:dump for PostgreSQL.
6775ad8
@carlosantoniodasilva carlosantoniodasilva Add missing requires for deep_dup and hash ext test 317f494
@tenderlove tenderlove `name` should be public. d5dc462
@tenderlove tenderlove do not set the ENGINE_PATH to nil d476129
Commits on May 25, 2012
@schneems schneems remove unnecessary test from route_inspect_test 4459125
@rafaelfranca rafaelfranca Merge pull request #6481 from schneems/schneems/sextant-routes
Remove Unnecessary Test from route_inspect_test
641ab7c
@waseem waseem Fixes build 4008.1
This fixex build 4008.1[1] because of the changes made in

4001835

[1] http://travis-ci.org/#!/rails/rails/jobs/1429671
baa3363
@josevalim josevalim Merge pull request #6482 from waseem/fix_build_4008
Fixes build 4008.1
ec8c4b5
@avakhov avakhov Fix ActiveSupport Cache decrement method description 05ae220
@josevalim josevalim Remove implicit dependency on pathname 73db73f
@josevalim josevalim Merge pull request #4785 from ayamomiji/add-self-to-allow-method-name…
…-using-ruby-keyword

add `self.` to allow method name using ruby keyword
56417b4
@avakhov avakhov Update examples of Array #in_groups and #in_groups_of
Examples should be not square to visually underline a difference between
Array#in_groups and Array#in_groups_of.
d834111
@Vaysman Vaysman references to the old behavior removed 17eedd8
@Vaysman Vaysman Merge branch 'master' of github.com:lifo/docrails 852ff78
@avakhov avakhov Clean Date#beginning_of_month description
Unnecessary peace of text was injected at
507da04 by mistake.
a1a16de
@avakhov avakhov Fix Range#sum optimized version
At 1bd4d1c was added Range#sum
optimized version for arithmetic progressions. This improvment injected
a defect with not integer range boundaries. The defect was fixed by
e0adfa8. The second commit really
disabled optimization at all because in Ruby integer-valued numbers are
instances of Fixnum and Bignum classes. We should #use is_a?
(#kind_of?) method instead #instance_of? to check if value is numerical:

    1.class                 # => Fixnum
    1.instance_of?(Integer) # => false
    1.is_a?(Integer)        # => true

    -100_000_000_000.class                 # => Bignum
    -100_000_000_000.instance_of?(Integer) # => false
    -100_000_000_000.is_a?(Integer)        # => true

Moreover original implementation of Range#sum has a defect with reverse
range boundaries. If the first boundary is less than the second range is
empty. Current commit fixes and tests this case too.
b4167d3
@rafaelfranca rafaelfranca Merge pull request #6487 from avakhov/range-sum-optimization
Fix Range#sum optimized version
8e1d46c
@avakhov avakhov Fix unbalanced braces in Hash#typecast_xml_value internal comment cb25bce
@edtsech edtsech Add comment for attr_accessible/attr_protected :as option. [ci skip] b98a343
@rafaelfranca rafaelfranca Merge pull request #5244 from fotos/myqsl2_wait_timeout
Maximum wait_timeout on Windows is 2147483
1c3469b
@rafmagana rafmagana [getting started] specify that rails new blog executes bundle install 470c151
@rafmagana rafmagana [getting started] specify what # and $ denotes in the prompt in unix-…
…like OSs
3e7d43b
@oscardelben oscardelben [Guides] Add inflector example 2614926
@oscardelben oscardelben [Guides] Add missing file descriptions 4ce51e3
@rafmagana rafmagana [getting started] specify which kind of temporary files are stored in…
… the /tmp folder
10f16e6
@rafmagana rafmagana [getting started] Update Setting the Application Home Page to show th…
…e get "welcome/index" route
12111e2
@tadast tadast Update paths in action_view_overview raislguide to reflect asset pipe…
…line conventions.
096cc0e
@tenderlove tenderlove Merge pull request #5872 from evtuhovich/prepared_statement_fix
Remove prepared statement from system query in postgresql adapter
0777773
@markmcspadden markmcspadden Reorder deep_symbolize_keys methods 1d485d5
@rafaelfranca rafaelfranca Merge pull request #6493 from markmcspadden/hash_keys_order_methods
Reorder deep_symbolize_keys methods
85c56b0
Commits on May 26, 2012
@tenderlove tenderlove Merge pull request #4132 from Juanmcuello/clone_structure
Reset postgreSQL search path in db:test:clone_structure.
1ca3133
Francesco Rodriguez add CollectionProxy#delete documentation 29463aa
Francesco Rodriguez add CollectionProxy#to_ary documentation 390d86a
Francesco Rodriguez add CollectionProxy#count documentation f81798d
Francesco Rodriguez add CollectionProxy#== documentation bb55f52
Francesco Rodriguez add :nodoc: to CollectionProxy#initialize 7a323e2
@radar radar [routing guide] Add mention of get '/:username' route
This is fairly common in Rails applications and is requested a lot of the time on Stack Overflow and #rubyonrails
9122143
@vijaydev vijaydev Merge pull request #6491 from rafmagana/getting_started_update_settin…
…g_app_home_page

[getting started] Update Setting the Application Home Page to show the generated get "welcome/index" route
4b91183
@vijaydev vijaydev Merge pull request #6454 from rafmagana/guides_rails_on_rack
[guides] Update rails on rack
e8cac28
@vijaydev vijaydev make it explicit that bundle install at the time of app creation
installs only the gems that are already in the gemfile

[ci skip]
6999b36
@vijaydev vijaydev fix mention of ruby versions that rails 4 won't run on [ci skip] 0673153
@vijaydev vijaydev Merge branch 'master' of github.com:lifo/docrails 575e77b
@vijaydev vijaydev some small corrections & wrapping changes in the initialization guide
This guide is currently a wip and pending reviews. [ci skip]
2114e21
@lellisga lellisga Truncate now has the ability to receive a html option that allows it …
…to call rails helpers.

This way if my text is long I don't have to do something like this:

.text
= truncate(@text, :length => 27)

 if @text.size >= 27
    = link_to "continue", notes_path, ....."")
38813da
@rafaelfranca rafaelfranca Merge pull request #6031 from lellisga/truncate_readme
Truncate now has the ability to receive a html option that allows it to call rails helpers.
9c8132c
@rafaelfranca rafaelfranca Test that the block used in truncate is escaped if it is not HTML safe
Refactoring the truncate method to not do a sort-circuit return
4ce3b5d
@deepak deepak Small correction to contributing_to_rails in the section for testing …
…ActiveRecord


Initially the guide suggests to install gems via "bundle install --without db" 
But tests for ActiveRecord need to install the gems in db group also, like mysql.
The patch clears the bundler options in ".bundle/config" and installs all the gems in Gemfile
0cfbaa0
@rafaelfranca rafaelfranca Update the documentation and add CHANGELOG entry eedc513
@rafaelfranca rafaelfranca Add `:escape` option for `truncate`
This options can be used to not escape the result by default.
2c2b0be
@deepak deepak Revert "Small correction to contributing_to_rails in the section for …
…testing ActiveRecord
" This reverts commit 0cfbaa0.
Sorry did not see the section on MySql and PostgreSQL

# Please enter the commit message for your changes. Lines starting
# with '#' will be ignored, and an empty message aborts the commit.
# On branch master
# Changes to be committed:
#   (use "git reset HEAD <file>..." to unstage)
#
#	modified:   guides/source/contributing_to_ruby_on_rails.textile
#
ef4b3ee
@vijaydev vijaydev Update initialization guide [ci skip]
* update rails versions
* remove outdated code snippets
* few more corrections
4c34cb3
Erich Menge Add some information about handle_unverified_request to guides. 7d8474e
Commits on May 27, 2012
Francesco Rodriguez add examples to Hash#deep_stringify_keys and Hash#deep_symbolize_keys…
… [ci skip]
ac50b63
Francesco Rodriguez update Hash documentation with 1.9 syntax [ci skip] 29713d7
Francesco Rodriguez add CollectionProxy#uniq documentation 55c0527
Francesco Rodriguez remove unnecessary ruby 1.8 reference from active_record/core [ci skip] 4df16f3
Francesco Rodriguez update Module#mattr_accessor documentation [ci skip] 4f031c8
@drogus drogus Fix railties_order when application object is passed
railites_order method, introduced in 40b19e0, had a bug that was causing
loading application instance twice in initializers if railties_order
already included application instance. So for example

    railties_order = [Foo::Engine, :main_app, Bar::Engine]

would result in such railties array:

    [MyApp::Application, Foo::Engine, MyAppApplication, Bar::Engine]

In order to fix it, we need to check for existence of application in
both railties_order and railties arrays.
cf992fb
@vijaydev vijaydev copy edits [ci skip] 903a9d5
@vijaydev vijaydev Merge branch 'master' of github.com:lifo/docrails 523d0f0
Commits on May 28, 2012
@amutz amutz Moving NumberHelpers from ActionView to ActiveSupport 155cd5e
@drogus drogus Fix sorting of helpers from different paths
When more than one directory for helpers is provided to a controller, it
should preserver the order of directories. Given 2 paths:

    MyController.helpers_paths = ["dir1/helpers", "dir2/helpers"]

helpers from dir1 should be loaded first. Before this commit, all
helpers were mixed and then sorted alphabetically, which essentially
would require to rename helpers to get desired order.

This is a problem especially for engines, where you would like to be
able to predict accurately which engine helpers will load first.

(closes #6496)
e4aaac1
@josevalim josevalim Merge pull request #6315 from appfolio/moving_number_helper_methods_t…
…o_active_support

Moving number helper from ActionView to Active Support
135f620
@jaredbeck jaredbeck Fix handling of negative zero in number_to_currency 371508c
@josevalim josevalim Merge pull request #6512 from jaredbeck/fix_number_to_currency_neg_fo…
…rmat

Fix handling of negative zero in number_to_currency
5acb10d
@purcell purcell Don't enable validations when passing false hash values to ActiveMode…
…l.validates

Passing a falsey option value for a validator currently causes that validator to
be enabled, just like "true":

    ActiveModel.validates :foo, :presence => false

This is rather counterintuitive, and makes it inconvenient to wrap `validates` in
methods which may conditionally enable different validators.

As an example, one is currently forced to write:

      def has_slug(source_field, options={:unique => true})
        slugger = Proc.new { |r| r[:slug] = self.class.sluggify(r[source_field]) if r[:slug].blank? }
        before_validation slugger
        validations = { :presence => true, :slug => true }
        if options[:unique]
          validations[:uniqueness] = true
        end
        validates :slug, validations
      end

because the following reasonable-looking alternative fails to work as expected:

      def has_slug(source_field, options={:unique => true})
        slugger = Proc.new { |r| r[:slug] = self.class.sluggify(r[source_field]) if r[:slug].blank? }
        before_validation slugger
        validates :slug, :presence => true, :slug => true, :uniqueness => options[:unique]
      end

(This commit includes a test, and all activemodel and activerecord tests pass as before.)
b3ccd7b
@josevalim josevalim Merge pull request #6517 from purcell/validates-false-value
Don't enable validations when passing false hash values to ActiveModel.validates
f5e26bc
@lest lest remove unnecessary require
AS::Multibyte are no longer required by access and filters string
core extensions.
7dd80d6
@lest lest make AS::Multibyte::Chars work w/o multibyte core ext
Use ActiveSupport::Multibyte::Chars.new instead of String#mb_chars.
It allows to use ActiveSupport::Multibyte::Chars without requiring
String multibyte core extension.
d64b254
@josevalim josevalim Merge pull request #6522 from lest/patch-1
ActiveSupport require and dependencies
68f23be
@floehopper floehopper Exceptions like Interrupt should not be rescued.
Neither Test::Unit nor MiniTest rescue exceptions like Interrupt or
NoMemoryError, but ActiveSupport::Testing::SetupAndTeardown#run which
overrides MiniTest::Unit::TestCase#run rescues them.

Rescuing an Interrupt exception is annoying, because it means when you
are running a lot of tests e.g. when running one of the rake test tasks,
you cannot break out using ctrl-C.

Rescuing exceptions like NoMemoryError is foolish, because the most
sensible thing to happen is for the process to terminate as soon as
possible.

This solution probably needs some finessing e.g. I'm not clear whether
the assumption is that only MiniTest is supported. Also early versions
of MiniTest did not have this behaviour. However, hopefully it's a
start.

Integrating with Test::Unit & MiniTest has always been a pain. It would
be great if both of them provided sensible extension points for the kind
of things that both Rails and Mocha want to do.
b057fab
Commits on May 29, 2012
Francesco Rodriguez Add support for CollectionAssociation#delete by Fixnum or String
I found the next issue between CollectionAssociation `delete`
and `destroy`.

    class Person < ActiveRecord::Base
      has_many :pets
    end

    person.pets.destroy(1)
    # => OK, returns the destroyed object

    person.pets.destroy("2")
    # => OK, returns the destroyed object

    person.pets.delete(1)
    # => ActiveRecord::AssociationTypeMismatch

    person.pets.delete("2")
    # => ActiveRecord::AssociationTypeMismatch

Adding support for deleting with a fixnum or string like
`destroy` method.
39f0698
@carlosantoniodasilva carlosantoniodasilva Parse float value only once in number helpers
Refactor number helpers output with safety handling to call float
parsing only once. Also remove 'erb' require.
ef3e696
@carlosantoniodasilva carlosantoniodasilva Merge pull request #6511 from frodsan/add_fixnum_string_support_for_d…
…elete

Add support for CollectionAssociation#delete by Fixnum or String
6f1d9d0
@chrisfinne chrisfinne Allow blocks for count with ActiveRecord::Relation. Document and test…
… that sum allows blocks
9cc2bf6
@carlosantoniodasilva carlosantoniodasilva Yield only one argument instead of splatting.
Add Changelog entry. Closes #4003
f9cb645
@carlosantoniodasilva carlosantoniodasilva Review requires from number helper
Some of these requires are now only necessary in
ActiveSupport::NumberHelper. Add hash/keys require due to symbolize_keys
usage in number helpers. Also remove some whitespaces.

Closes #6414
400c5fe
@carlosantoniodasilva carlosantoniodasilva Fix failing build related to change in CollectionAssociation#delete
Merge commit 6f1d9d0
18af5da
@carlosantoniodasilva carlosantoniodasilva Add note about CollectionAssociation#delete change to upgrading guide…
… [ci skip]
8795ac5
Francesco Rodriguez Add tests to delete by fixnum or string id with has many through asso…
…ciations
b89553c
@carlosantoniodasilva carlosantoniodasilva Merge pull request #6527 from frodsan/add_test_to_delete_by_fixnum_or…
…_string

Add tests to delete by fixnum or string id with has many through associations
3d4ede2
@amutz amutz decoupling activesupport performance testing from actionview and addi…
…ng tests
598f8bd
@carlosantoniodasilva carlosantoniodasilva Merge pull request #6526 from appfolio/decoupling_activesupport_from_…
…actionivew

Decoupling ActiveSupport from ActionView
d4a7dee
Francesco Rodriguez update Gemfile template to 1.9 hash syntax 5db367a
@josevalim josevalim Merge pull request #6528 from frodsan/update_hash_syntax_gemfile_temp…
…late

update Gemfile template to 1.9 hash syntax
2d898cd
@floehopper floehopper Avoid dependency on MiniTest::Unit::TestCase::PASSTHROUGH_EXCEPTIONS. 7d8e5fa
@josevalim josevalim Merge pull request #6525 from freerange/minitest-passthrough-exceptions
Exceptions like Interrupt & NoMemoryError should not be rescued in tests.
6ba93ac
@drogus drogus `cat Gemfile.lock` after installing gems on travis
It may be useful to view Gemfile.lock. If the build fails we can inspect
it locally with exactly the same environment.
73cf866