1. 25 12月, 2018 1 次提交
  2. 24 12月, 2018 3 次提交
  3. 23 12月, 2018 2 次提交
  4. 22 12月, 2018 4 次提交
    • E
      Merge pull request #34774 from rails/fix-app-boot-for-ruby-2-4 · 2bb71a5e
      Eileen M. Uchitelle 提交于
      Fix app boot for Ruby 2.4
      2bb71a5e
    • E
      Fix app boot for Ruby 2.4 · 555c1a3a
      Eileen Uchitelle 提交于
      I have a test app that was on Ruby 2.4. When I pulled Rails master the
      app no longer would boot because of this change and I saw the following
      error:
      
      ```
      SyntaxError:
      /Users/eileencodes/open_source/real_rails/railties/lib/rails/all.rb:18:
      syntax error, unexpected keyword_rescue, expecting keyword_end
      rescue LoadError
            ^
      ```
      
      Ruby 2.4 doesn't support removing redundant begins so the real issue is
      that this app is on Ruby 2.4 and not on Ruby 2.5. But it's super
      confusing for a user to understand the reason the app is failing to boot
      is because we need Ruby 2.5.
      
      I added this redundant begin back because we need to give a clearer
      error message.
      555c1a3a
    • E
      Merge pull request #34753 from eileencodes/raise-less-confusing-error-if-handler-doesnt-exist · b00e46bd
      Eileen M. Uchitelle 提交于
      Raise helpful error when role doesn't exist
      b00e46bd
    • E
      Raise helpful error when role doesn't exist · 22a12658
      Eileen Uchitelle 提交于
      If you try to call `connected_to` with a role that doesn't have an
      established connection you used to get an error that said:
      
      ```
      >> ActiveRecord::Base.connected_to(role: :i_dont_exist) { Home.first }
      
      ActiveRecord::ConnectionNotEstablished Exception: No connection pool
      with 'primary' found.
      ```
      
      This is confusing because the connection could be established but we
      spelled the role wrong.
      
      I've changed this to raise if the `role` used in `connected_to` doesn't
      have an associated handler. Users who encounter this should either check
      that the role is spelled correctly (writin -> writing), establish a
      connection to that role in the model with connects_to, or use the
      `database` keyword for the `role`.
      
      I think this will provide a less confusing error message for those
      starting out with multiple databases.
      22a12658
  5. 21 12月, 2018 17 次提交
  6. 20 12月, 2018 9 次提交
  7. 19 12月, 2018 4 次提交
    • Y
      Pass the correct value as JSON · e7a7e174
      yuuji.yaginuma 提交于
      This takes away the following log.
      
      ```
      Error occurred while parsing request parameters.
      Contents:
      
      {:foo=>"heyo"}
      ```
      Pass the correct value as JSON
      e7a7e174
    • R
      MySQL: `ROW_FORMAT=DYNAMIC` create table option by default · a1652c19
      Ryuta Kamizono 提交于
      Since MySQL 5.7.9, the `innodb_default_row_format` option defines the
      default row format for InnoDB tables. The default setting is `DYNAMIC`.
      
      The row format is required for indexing on `varchar(255)` with `utf8mb4`
      columns.
      
      As long as using MySQL 5.6, CI won't be passed even if MySQL server
      setting is properly configured the same as MySQL 5.7
      (`innodb_file_per_table = 1`, `innodb_file_format = 'Barracuda'`, and
      `innodb_large_prefix = 1`) since InnoDB table is created as the row
      format `COMPACT` by default on MySQL 5.6, therefore indexing on string
      with `utf8mb4` columns aren't succeeded.
      
      Making `ROW_FORMAT=DYNAMIC` create table option by default for legacy
      MySQL version would mitigate the indexing issue on the user side, and it
      makes CI would be passed on MySQL 5.6 which is configured properly.
      a1652c19
    • R
      Use `utf8mb4` charset for internal tables if the row format `DYNAMIC` by default · 0fa5b551
      Ryuta Kamizono 提交于
      The indexing issue on `utf8mb4` columns is resolved since MySQL 5.7.9.
      0fa5b551
    • K
      Merge pull request #34739 from sambostock/correct-nested-config-documentation · 5b531941
      Kasper Timm Hansen 提交于
      Single nest config in configuration guides
      5b531941