
Issue #20730 has been updated by kddnewton (Kevin Newton). I have opened https://github.com/ruby/ruby/pull/11617 to fix this. ---------------------------------------- Bug #20730: LoadError if Rakefile has shebang https://bugs.ruby-lang.org/issues/20730#change-109754 * Author: watson1978 (Shizuo Fujita) * Status: Open * Target version: 3.4 * ruby -v: ruby 3.4.0dev (2024-09-12T20:03:28Z master 0fc8422a05) +PRISM [x86_64-linux] * Backport: 3.1: UNKNOWN, 3.2: UNKNOWN, 3.3: UNKNOWN ---------------------------------------- `LoadError` exception will be raised when invoke the rake task with latest ruby 3.4-dev. ### Reproduce code Here is example code. ```ruby #!/usr/bin/env rake p "Hello" ``` ### Result ``` $ ruby -v ruby 3.4.0dev (2024-09-12T20:03:28Z master 0fc8422a05) +PRISM [x86_64-linux] $ rake -f test.rake rake aborted! LoadError: no Ruby script found in input (LoadError) (See full trace by running task with --trace) ``` -- https://bugs.ruby-lang.org/