Fix: https://github.com/rails/rails/issues/42983
The usefulness of these timestamps is a bit questionable,
but I suppose they could be useful for debugging, and
removing them would require to ship a migration etc.
Since `record_timestamps` is now a `class_attribute` we
can simply force it to `true` in just that class.
require_dependency has now one single definition, and its implementation
does not depend on Zeitwerk or even applications. It only depends on
having some autoload paths in place.
We can test that in the AS test suite.
* Sprockets shouldn't be in debug mode by default in development
As we move to separate files with ESM, we won't be concatenating or even preprocessing large JavaScript at all. Debug mode is thus irrelevant.
* Debug mode is no longer default
The concept of dependencies mechanism disappears.
We do not remove the attribute in AS::Dependencies itself here, that
class is going to have a lot of code delete later.
Without classic, this test would be testing that Zeitwerk works. That
belongs to the test suite of Zeitwerk.
Active Record has the class available, whether it was already loaded or
pending autoloading, is not AR's concern.
AJ infers adapater class names, and loads them. How are those classes made
available to AJ is a user's concern.
Perhaps they loaded the adapter with require, perhaps they have the class in the
autoload_once_paths. It does not matter, it is the user responsibility to make
the class available _somehow_, and AJ can assume that.
* Output Action Cable JS without transpiling and as ESM
* Retain umd version under the old name, generate ESM version + duplicate under new name
* Precompile JavaScripts for direct asset pipeline use
* We've dropped support for IE11
* Include deprecation notice for the old file reference
Thanks @rafaelfranca 👍
* Allow app to opt out of precompiling actioncable js assets
cc @rafaelfranca
* Add changelog entries
Without this fix, the delegation will raise the ArgumentError:
```
% bin/test -w test/per_thread_registry_test.rb
Running 1 tests in a single process (parallelization threshold is 50)
Run options: --seed 23992
# Running:
E
Error:
PerThreadRegistryTest#test_method_missing_with_kwargs:
ArgumentError: wrong number of arguments (given 1, expected 0; required keyword: x)
/Users/kamipo/src/github.com/rails/rails/activesupport/test/per_thread_registry_test.rb:9:in `foo'
/Users/kamipo/src/github.com/rails/rails/activesupport/lib/active_support/per_thread_registry.rb:55:in `foo'
/Users/kamipo/src/github.com/rails/rails/activesupport/lib/active_support/per_thread_registry.rb:57:in `method_missing'
/Users/kamipo/src/github.com/rails/rails/activesupport/test/per_thread_registry_test.rb:13:in `test_method_missing_with_kwargs'
```
commit 1dca99ad4f8082d8daaa17c6600f3036c25f8e50
Author: Tom Prats <tprats108@gmail.com>
Date: Thu Aug 5 18:07:00 2021 -0400
Moved header
commit 62201870ff5c4124d90912989745819b05d94516
Merge: 5fa3ecae74 c91a8135c7
Author: Tom Prats <tprats108@gmail.com>
Date: Thu Aug 5 14:41:22 2021 -0400
Merge branch 'main' into active-storage-byte-range
commit 5fa3ecae745b4f7c67a6b6b1b7ec420877c96fb8
Author: Tom Prats <tprats108@gmail.com>
Date: Thu Aug 5 14:39:53 2021 -0400
Apply suggestions from code review
Syntax updates
Co-authored-by: Rafael França <rafael@franca.dev>
commit b9553e3698a7af5105171f9d63bd7b89cbb7e2c3
Author: Tom Prats <tprats108@gmail.com>
Date: Wed Jun 23 17:36:26 2021 -0400
Added Active Storage support for byte ranges