Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

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: pinetops/rails
...
head fork: pinetops/rails
Checking mergeability… Don't worry, you can still create the pull request.
Commits on Aug 16, 2011
@trek trek When a route references a missing controller, raise ActionController:…
…:RoutingError with a clearer message
dde5b87
Commits on Oct 18, 2011
@mrreynolds mrreynolds Fixed DataMapper namings in symbols and constants. 8d3cd53
Commits on Feb 01, 2012
@pacoguzman pacoguzman Refactor define_restrict_dependency_method using reflection 1596878
Commits on Mar 31, 2012
@troyk troyk Remove sort on attributes.keys cf833b9
Commits on May 03, 2012
@senny senny allow the :converter Proc form composed_of to return nil
This makes it possible to filter invalid input values before they are passed
into the value-object (like empty strings). This behaviour is only relevant
if the :allow_nil options is set to true. Otherwise you will get
the resulting NoMethodError.
fa5f037
Commits on May 17, 2012
@nashby nashby wrap time ranges with timezones, closes #6179 e2e5136
@frodsan frodsan Add docs to CollectionAssociation#replace cd840c3
@nashby nashby update AS docs a00bca6
@frodsan frodsan fix CollectionAssociation#replace docs ea1477f
@oscardelben oscardelben Add oscardelben to authors 3328401
@KL-7 KL-7 Render img tag with empty src if empty string is passed to image_tag. 3e9ec24
Commits on May 18, 2012
@radar radar [engines] initializer method call needs an argument for initializer name 2e2d381
@frodsan frodsan add docs to CollectionAssociation#many? 3c91c81
@frodsan frodsan add CollectionAssociation hierarchy e66c0fc
@frodsan frodsan add more explanation to CollectionAssociation docs c0c0ef5
@frodsan frodsan add example to CollectionAssociation#destroy_all fcc13f4
@soulim soulim Add HTML5 input[type="time"] helper 446940c
@frodsan frodsan fix CollectionAssociation docs 3ef1f94
@frodsan frodsan add examples to CollectionAssociation#concat 10d375e
@frodsan frodsan add docs to CollectionAssociation#any? d029d50
@frodsan frodsan add docs to CollectionAssociation#empty? bf55f28
@jeremy jeremy Merge pull request #5715 from soulim/add_time_input_control
Add HTML5 input[type="time"] helper
d8e8ab1
@frodsan frodsan remove incorrect example of CollectionAssociation#empty? 48acd29
@richo richo Add the #unshift method to the middleware stack
The docs suggest that the middleware stack is an Array, so I've added
the unshift method to it. Originally I added some more Array methods,
but it was agreed that they lacked usecases.
793205c
@josevalim josevalim Merge pull request #5020 from KL-7/fix-blank-image_tag-source
Render img tag with empty src if empty string is passed to image_tag.
6bb86e1
@josevalim josevalim Merge pull request #6372 from richo/bugs/middleware_stack_as_array
Add some common Array methods to the middleware stack
a6a8957
@bogdan bogdan AS::Callbacks: fix run_callbacks for objects with negative id 911a085
@richo richo The middleware stack is compliant with Enumarable and bits of Array
Try to clarify the docs so that it's more clear how the stack behaves.
21bff1d
@josevalim josevalim Merge pull request #6373 from bogdan/callbacks_fix
AS::Callbacks: fix run_callbacks for objects with negative id
88949f8
@nashby nashby respect nsec in TimeWithZone
when we pass fractional usec to Time methods we should use Rational
instead of Float because of accuracy problem

    Time.local(2011,6,12,23,59,59,999999.999).nsec
    # => 999999998

    Time.local(2011,6,12,23,59,59,Rational(999999999, 1000)).nsec
    # => 999999999
dcdde7d
@splattael splattael Fix typo. 83153c7
@jonleighton jonleighton quarantine deprecated tests ee16fea
@jonleighton jonleighton quarantine more deprecated stuff 62c6ac2
@jonleighton jonleighton add changelogs about deprecated stuff [ci skip] 103ce30
@nashby nashby doesn't modify params in SafeBuffer#% 3b1c30c
@jonleighton jonleighton fix typo [ci skip] 1ae68ea
@oscardelben oscardelben Revert "Add oscardelben to authors"
This reverts commit 3328401.

Reason: this change doesn't belong to DocRails.
b5e15f3
@oscardelben oscardelben Call undefine_attribute_methods only when defining new attributes 42d0b1c
@josevalim josevalim Merge pull request #6380 from nashby/output-safety-interpolation
doesn't modify params in SafeBuffer#%
fa561a5
@oscardelben oscardelben Refactor migration generator 925f2e9
@josevalim josevalim Merge pull request #6382 from oscardelben/refactor_migration_generator
Refactor migration generator
f491c6a
@tenderlove tenderlove port some mocha to minitest/mock 476ef2d
@amutz amutz reverting decoupling of NumberHelper from safe_join and adding tests …
…for escaping of delimiters and separators
2c423b3
@rafaelfranca rafaelfranca Merge pull request #6355 from amutz/fix_number_with_delimiter_escaping
NumberHelper.number_with_delimiter should html_escape both delimiters and separators
a6dbc3f
@jonleighton jonleighton Perf: Don't load the association for #delete_all.
Bug #6289
80f1694
@frodsan frodsan add explanation of raising errors when a limit scope is supplied in R…
…elation#delete_all
db77b16
@jonleighton jonleighton no longer need #delete_all_on_destroy a1dd008
@jonleighton jonleighton fix #delete_all with habtm with :delete_sql dcc576d
@kennyj kennyj Fix build: can't convert Regexp to String 130b0d2
@rafaelfranca rafaelfranca Merge pull request #6387 from kennyj/fix_test_20120519
Fix build: can't convert Regexp to String
906009c
@frodsan frodsan move docs from CollectionAssociation to CollectionProxy 1b5c775
@kennyj kennyj Fix warning: possibly useless use of % in void context 5c02e30
@rafaelfranca rafaelfranca Merge pull request #6388 from kennyj/fix_warning_20120519
Fix warning: possibly useless use of % in void context
8b4ecbe
@jeremy jeremy Merge pull request #6183 from nashby/fix-issue-6179
wrap time ranges with timezones
40bdf55
@KensoDev KensoDev Added wrapper tag documentation to the simple_format method ede5e9b
@KensoDev KensoDev Merge branch 'master' of github.com:lifo/docrails 7827920
@KensoDev KensoDev Minor fix to the wrapper tag documentation, the options hash is the l…
…ast one, added blank hash before that in the args list
90a2438
@KensoDev KensoDev You can add a custom primary key to a table 23a98ff
@strzalek strzalek More DRY route inspect tests 61fc10d
@strzalek strzalek Fix inspecting route redirections, closes #6369
This commit fixes route inspection in `rake routes`

Before:

  foo  /foo(.:format) :controller#:action"

After:

  foo  /foo(.:format)  Redirect (301)
5f7bfb7
@drogus drogus Merge pull request #6391 from strzalek/redirect_route_inspect
Redirect route inspect
6f0c9cd
@iHiD iHiD Tidied and standardised text_helper implementations. 7e82ebd
Commits on May 19, 2012
@frodsan frodsan minor fix wrapper tag documentation ec430d4
@jeremy jeremy Merge pull request #6384 from ihid/tidy_text_helpers
Tidied and standardised text_helper implementations.
49b72fa
@jgaskins jgaskins Increase `AR#cache_key` precision to nanoseconds 900dbc5
@frodsan frodsan add CollectionProxy#include? documentation 5111ec4
@jeremy jeremy Merge pull request #6376 from jgaskins/timestamp-microseconds
Increase numeric-timestamp precision to nanoseconds
98657ad
@frodsan frodsan add CollectionProxy#clear documentation 3f46f73
@frodsan frodsan add CollectionProxy#<< documentation bb887b9
@avakhov avakhov Make AC::LogSubscriber#send_file like #send_data 117382f
@frodsan frodsan fix CollectionProxy#<< documentation 970a146
@frodsan frodsan improve CollectionProxy#concat documentation bc8b7e0
@dmathieu dmathieu fix typo. probem => problem 12b6307
@pixeltrix pixeltrix Improve `rake routes` output for redirects - closes #6369. ec77498
@drogus drogus Ensure that CollectionAssociation#replace returns proper target
The fix commited in e2a070c was returning the `new_target`, as
a try to return whatever user replaced association with. The
problem is, the resulting association target may be ordered
differently. In such case we want to return the target that
will be later used for that association.
099bb5d
@drogus drogus Fix railties tests
Minitest uses different signature for assert_no_match, so we have to
swap arguments.
bd838c0
@vijaydev vijaydev Revert "You can add a custom primary key to a table"
This reverts commit 23a98ff.

[ci skip]
6c7c997
@vijaydev vijaydev copy edits [ci skip] d0a3be3
@carlosantoniodasilva carlosantoniodasilva Remove warning in namespaced generator test 573448f
@carlosantoniodasilva carlosantoniodasilva Remove delegated methods from generators test case
`class_attribute` already generates instance readers/writers by default,
so there's no need to add delegation methods.

Removes some "method redefined" warnings.
3e70706
@carlosantoniodasilva carlosantoniodasilva Clarify grouped_options_for_select method API, add changelog entry
Make the method API more clear by explicitly showing the expected
arguments. This means that the options cannot be passed as second
argument because we are not relying on extract_options! anymore,
you are expected to give a selected key or `nil` if you want to pass
options, as it is the last argument.

Notice that this does not change the current method arguments contract
available in 3.2, it just brings back the same functionality with the
divider addition.
0e207a4
@carlosantoniodasilva carlosantoniodasilva Merge pull request #5678 from troyk/patch-1
Remove sort on attributes.keys
f20032f
@frodsan frodsan add CollectionProxy#first documentation 75d7101
@carlosantoniodasilva carlosantoniodasilva Merge pull request #4835 from pacoguzman/refactor_define_restrict_dep…
…endency_method

Refactor define_restrict_dependency_method using reflection
8405aad
@pixeltrix pixeltrix Add CHANGELOG entry for #6369 & #6391 71a83a9
@frodsan frodsan add CollectionProxy#last documentation b0f55c6
@vijaydev vijaydev copy edits [ci skip] 4adfd8e
@vijaydev vijaydev Merge branch 'master' of github.com:lifo/docrails 1551de3
@marcandre marcandre Make constantize look down the ancestor chain (excluding Object) 99e9a73
@marcandre marcandre Fix constantize so top level constants are looked up properly. eb09411
@pixeltrix pixeltrix Handle case where ancestor is not the end of the chain 3d0e489
@pixeltrix pixeltrix Add CHANGELOG entry for constantize - closes #6165. 329a5a4
@kennyj kennyj Fix warning: shadowing outer local variable - constant. 3f1caaf
@rafaelfranca rafaelfranca Merge pull request #6395 from kennyj/fix_warning_20120519-2
Fix warning: shadowing outer local variable - constant.
26bdcf7
@kennyj kennyj Don't use assert_block method. It will be deprecated. e5e2ba1
@rafaelfranca rafaelfranca Merge pull request #3359 from mrreynolds/datamapper_naming_fix
Fixed DataMapper namings in symbols and constants.
6df96c9
@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
@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
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
@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
@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
@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
@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
@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.
2a12187
@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.
63f3393