load_from_file doesn't work on Windows
Reported by Neil Wilson | May 14th, 2008 @ 04:12 AM
Windows paths don't start with '/' so the guard in line 172 of 'loading.rb' fails on fully qualified paths and you get an erroneous exception raised in 'find_file_in_load_path'.
Comments and changes to this ticket
-
Jamis Buck May 14th, 2008 @ 04:56 PM
I don't really have a windows machine handy for testing or resolving this. Any chance you could provide a patch?
-
Neil Wilson May 15th, 2008 @ 02:15 AM
Any particular reason why you want to avoid testing the filesystem? If
not why not go for:
file = find_file_in_load_path(file) unless File.file?(file)
-
Neil Wilson May 25th, 2008 @ 09:07 PM
(from [c1e927989bccb4197f9877e2fa836a064712b5d7]) Fix load_from_file method for windows users [#19 tagged:committed state:resolved]
-
Jamis Buck May 25th, 2008 @ 09:08 PM
- → State changed from new to resolved
Thanks for the suggestion Neil, that's much cleaner.
Please Login or create a free account to add a new comment.
You can update this ticket by sending an email to from your email client. (help)
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
