Conversation
There's no real reason to hide the extra flags.
It looks awkward when the line is longer than the terminal and there is a leading `remote:` from a `git push` as the text does not stay in front of the `remote: ` it ends up looking something like this: ``` remote: ! Error: `Gemfile found with error remote: ! remote: ! There was an error trying to read the contents of the application's Gemfile. The buildpack cannot continue if the Gemfile is unreadable. remote: ! remote: ! Error info ``` We cannot prevent this from happening always, but we also don't have to purposefully have very long lines in our output.
This matches Ruby convention for Procs, lambdas, and service objects. Basically anything that has a generic execute this code" entrypoint usually uses `call`.
edmorley
approved these changes
May 1, 2025
Merged
heroku-linguist Bot
added a commit
to heroku/cnb-builder-images
that referenced
this pull request
May 5, 2025
## heroku/ruby ### Fixed - Internal API used for producing buildpack output updated. ([#419](heroku/buildpacks-ruby#419)) ### Changed - Removed support for Ubuntu 20.04 (and thus Heroku-20 / `heroku/builder:20`). ([#422](heroku/buildpacks-ruby#422))
heroku-linguist Bot
added a commit
to heroku/cnb-builder-images
that referenced
this pull request
May 5, 2025
## heroku/ruby ### Fixed - Internal API used for producing buildpack output updated. ([#419](heroku/buildpacks-ruby#419)) ### Changed - Removed support for Ubuntu 20.04 (and thus Heroku-20 / `heroku/builder:20`). ([#422](heroku/buildpacks-ruby#422)) Co-authored-by: heroku-linguist[bot] <136119646+heroku-linguist[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
bullet_streamglobal function interface was introduced in 0.4.0 https://github.com/heroku-buildpacks/bullet_stream/blob/ce8fd41c8886a8f0e2c5992f2bfa673838ad509a/CHANGELOG.md#v040---20250121This PR updates the Ruby buildpack to use the new style of printing interface over the heavier type-state interface.
A little history on why it took so long to introduce and adopt a function interface in a functional language:
The original design of the printing interface was a little bit functional with a light type-state pattern. You can see the original interface here #155.
Over many pairing sessions, the type-state design was emphasized and functional style interfaces de-emphasized. It's a good pattern, but in hind-site not a good fit for the work.
This work happened in:
After this point, there were now two interfaces:
We continued working on it, and in an attempt to get it into libcnb, this functional interface was removed to reduce the size of the PR that shipped: heroku/libcnb.rs@174fc02.
While the PR was technically merged into libcnb, it missed core functionality and was unusable. I ported the code over to a new repo,
heroku-buildpacks/bullet_stream,with only the type-state API, believing Manuel (who is a co-author of that commit) preferred it.I started sending PRs to other repos and got tired of the heavy interface with relatively minimal benefit, and released 0.4.0 with the functional interface. Since then, it's been shown to be a clear favorite for other buildpack maintainers who have chosen to use that library.