Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 34 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,33 @@
## [Unreleased]


## [v287] - 2024-12-25

- Ruby 3.4.0 is now available (https://github.com/heroku/heroku-buildpack-ruby/pull/1531)
- Ruby 3.4.1 is now available (https://github.com/heroku/heroku-buildpack-ruby/pull/1531)

## [v286] - 2024-12-13

- Ruby 3.4.0-rc1 is now available (https://github.com/heroku/heroku-buildpack-ruby/pull/1528)

## [v285] - 2024-11-21

- Default `UV_USE_IO_URING=0` due to build timeouts [context](https://github.com/heroku/heroku-buildpack-nodejs/pull/1347) (https://github.com/heroku/heroku-buildpack-ruby/pull/1523)

## [v284] - 2024-11-15

- Default Node.js version now 22.11.0 (https://github.com/heroku/heroku-buildpack-ruby/pull/1503)
- Default Yarn version now 1.22.22 (https://github.com/heroku/heroku-buildpack-ruby/pull/1503)

## [v283] - 2024-11-14

- No customer facing changes

## [v282] - 2024-11-08

- [Rolled back] Default Node.js version now 22.11.0 (https://github.com/heroku/heroku-buildpack-ruby/pull/1503)
- [Rolled back] Default Yarn version now 1.22.22 (https://github.com/heroku/heroku-buildpack-ruby/pull/1503)

## [v281] - 2024-11-07

- Ruby 3.3.6 is now available (https://github.com/heroku/heroku-buildpack-ruby/pull/1511)
Expand Down Expand Up @@ -1584,7 +1611,13 @@ Bugfixes:
* Change gem detection to use lockfile parser
* use `$RACK_ENV` when thin is detected for rack apps

[unreleased]: https://github.com/heroku/heroku-buildpack-ruby/compare/v281...main
[unreleased]: https://github.com/heroku/heroku-buildpack-ruby/compare/v287...main
[v287]: https://github.com/heroku/heroku-buildpack-ruby/compare/v286...v287
[v286]: https://github.com/heroku/heroku-buildpack-ruby/compare/v285...v286
[v285]: https://github.com/heroku/heroku-buildpack-ruby/compare/v284...v285
[v284]: https://github.com/heroku/heroku-buildpack-ruby/compare/v283...v284
[v283]: https://github.com/heroku/heroku-buildpack-ruby/compare/v282...v283
[v282]: https://github.com/heroku/heroku-buildpack-ruby/compare/v281...v282
[v281]: https://github.com/heroku/heroku-buildpack-ruby/compare/v280...v281
[v280]: https://github.com/heroku/heroku-buildpack-ruby/compare/v279...v280
[v279]: https://github.com/heroku/heroku-buildpack-ruby/compare/v278...v279
Expand Down
6 changes: 4 additions & 2 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ GEM
remote: https://rubygems.org/
specs:
base64 (0.2.0)
ci-queue (0.55.0)
ci-queue (0.59.0)
logger
citrus (3.0.2)
connection_pool (2.4.1)
dead_end (4.0.0)
Expand All @@ -23,6 +24,7 @@ GEM
thor (~> 1)
threaded (~> 0)
json (2.7.2)
logger (1.6.2)
moneta (1.0.0)
multi_json (1.15.0)
parallel (1.25.1)
Expand All @@ -34,7 +36,7 @@ GEM
rate_throttle_client (~> 0.1.0)
rake (13.2.1)
rate_throttle_client (0.1.2)
redis (5.2.0)
redis (5.3.0)
redis-client (>= 0.22.0)
redis-client (0.22.2)
connection_pool
Expand Down
2 changes: 1 addition & 1 deletion app.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
},
"scripts": {
"test-setup": "bundle exec rake hatchet:setup_ci",
"test": "bundle exec rspec-queue --max-requeues=3 --timeout 180 --queue $REDIS_URL || { cat log/test_order.log; $(exit 1); }"
"test": "bundle exec rspec-queue --max-requeues=3 --timeout 180 --queue $REDIS_URL --format documentation || { cat log/test_order.log; $(exit 1); }"
},
"buildpacks": [
{
Expand Down
8 changes: 8 additions & 0 deletions changelogs/v284/node-yarn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
## Ruby apps now default to Node version 22.11.0 and Yarn version 1.22.22

Applications using the `heroku/ruby` buildpack that do not have a version of Node installed by another buildpack (such as the `heroku/nodejs` buildpack) will now receive:

- Node version 22.11.0
- Yarn version 1.22.22

These versions and instructions on how to specify a specific version of these binaries can be found on the [installed binaries section of the Heroku Ruby Support page](https://devcenter.heroku.com/articles/ruby-support#installed-binaries).
15 changes: 15 additions & 0 deletions changelogs/v286/3.4.0-rc1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
## Ruby version 3.4.0-rc1 is now available

[Ruby v3.4.0-rc1](/articles/ruby-support-reference#ruby-versions) is now available on Heroku. To run your app using this version of Ruby, add the following `ruby` directive to your Gemfile:

```ruby
ruby "3.4.0.rc1"
```

For more information on [Ruby 3.4.0-rc1, you can view the release announcement](https://www.ruby-lang.org/en/news/).

> Note
> This version of Ruby is not suitable for production applications.
> However, it can be used to test that your application is ready for
> the official release of Ruby 3.4.0 and
> to provide feedback to the Ruby core team.
9 changes: 9 additions & 0 deletions changelogs/v287/ruby_3.4.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
## Ruby version 3.4.0 is now available

[Ruby v3.4.0](/articles/ruby-support-reference#ruby-versions) is now available on Heroku. To run your app using this version of Ruby, add the following `ruby` directive to your Gemfile:

```ruby
ruby "3.4.0"
```

For more information on [Ruby 3.4.0, you can view the release announcement](https://www.ruby-lang.org/en/news/).
5 changes: 3 additions & 2 deletions lib/language_pack/fetcher.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,10 @@ def fetch(path)
run!(curl, error_class: FetchError)
end

def fetch_untar(path, files_to_extract = nil)
def fetch_untar(path, files_to_extract = nil, strip_components: 0)
curl = curl_command("#{@host_url.join(path)} -s -o")
run! "#{curl} - | tar zxf - #{files_to_extract}",
tar_cmd = ["tar zxf - #{files_to_extract}", "--strip #{strip_components}"]
run! "#{curl} - | #{tar_cmd.join(" ")}",
error_class: FetchError,
max_attempts: 3
end
Expand Down
4 changes: 2 additions & 2 deletions lib/language_pack/helpers/nodebin.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
require 'json'

class LanguagePack::Helpers::Nodebin
NODE_VERSION = "20.9.0"
YARN_VERSION = "1.22.19"
NODE_VERSION = "22.11.0"
YARN_VERSION = "1.22.22"

def self.hardcoded_node_lts(arch: )
arch = "x64" if arch == "amd64"
Expand Down
4 changes: 2 additions & 2 deletions lib/language_pack/helpers/yarn_installer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ def binary_path
def install
Dir.mktmpdir do |dir|
Dir.chdir(dir) do
@fetcher.fetch_untar(@url)
@fetcher.fetch_untar(@url, strip_components: 1)
end

FileUtils.mv(File.join(dir, name), name)
FileUtils.cp_r(dir, name)
end
end
end
10 changes: 10 additions & 0 deletions lib/language_pack/ruby.rb
Original file line number Diff line number Diff line change
Expand Up @@ -973,6 +973,11 @@ def add_node_js_binary
version = @node_installer.version
old_version = @metadata.fetch("default_node_version") { version }

# Make available for `rake assets:precompile` and other sub-shells
ENV["UV_USE_IO_URING"] ||= "0"
# Make available to future buildpacks (export), but not runtime (profile.d)
set_export_default "UV_USE_IO_URING", "0"

if version != version
warn(<<~WARNING, inline: true)
Default version of Node.js changed (#{old_version} to #{version})
Expand Down Expand Up @@ -1006,6 +1011,11 @@ def add_yarn_binary
version = @yarn_installer.version
old_version = @metadata.fetch("default_yarn_version") { version }

# Make available for `rake assets:precompile` and other sub-shells
ENV["UV_USE_IO_URING"] ||= "0"
# Make available to future buildpacks (export), but not runtime (profile.d)
set_export_default "UV_USE_IO_URING", "0"

if version != version
warn(<<~WARNING, inline: true)
Default version of Yarn changed (#{old_version} to #{version})
Expand Down
2 changes: 1 addition & 1 deletion lib/language_pack/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

module LanguagePack
class LanguagePack::Base
BUILDPACK_VERSION = "v281"
BUILDPACK_VERSION = "v287"
end
end
18 changes: 11 additions & 7 deletions spec/hatchet/rubies_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,26 +13,30 @@
end

describe "Ruby versions" do
it "should deploy jdk on heroku-20" do
Hatchet::Runner.new("default_ruby", stack: "heroku-20").tap do |app|
it "should deploy jdk on heroku-24" do
Hatchet::Runner.new("default_ruby", stack: "heroku-24").tap do |app|
app.before_deploy do |app|
Pathname("Gemfile.lock").write(<<~EOM)
GEM
remote: https://rubygems.org/
specs:
rack (2.2.2)
rake (13.0.1)
rack (3.1.8)
rake (13.2.1)
webrick (1.9.1)

PLATFORMS
java

DEPENDENCIES
rack
rake

webrick

RUBY VERSION
ruby 2.5.7p0 (jruby 9.2.13.0)
ruby 3.1.4p0 (jruby 9.4.8.0)

BUNDLED WITH
2.5.23
EOM

Pathname("Rakefile").write(<<~'EOM')
Expand All @@ -50,7 +54,7 @@
app.push!
expect(app.output).to match("JRUBY_OPTS is: --dev")

expect(app.run("ls .jdk/jre/lib/ext/")).to match("pgconfig.jar")
expect(app.run("ruby -v")).to match("jruby")
end
end
end
Expand Down
Loading