s3 urls get an additional "." appended to their url
tbhockey opened this issue · comments
In my email layout I have a very simple image tag which points to amazon s3.
<img src="http://s3.amazonaws.com/bucket/image.jpg">
When roadie is install this url gets converted to this:
<img src="http://s3.amazonaws..com/bucket/image.jpg">
[Note the additional "." before com]
I cannot replicate this.
rendering('<img src="http://s3.amazonaws.com/bucket/image.jpg">').should have_attribute('src' => 'http://s3.amazonaws.com/bucket/image.jpg')
This test passes. The implementation is also using the built-in URI
class to check that the URL is relative, and it should not be relative.
# Other details removed
uri = URI.parse(url)
if uri.relative? # should be false
make_uri_absolute
else
uri.to_s # should work
end
So unless URI is buggy in your Ruby (and either returns true on relative?
or generates an incorrect URL with to_s
), the fault lies somewhere else.
Which version of Ruby are you using? Does it happen for any http://s3.amazonaws.com
URL? Is there some funky characters in the true URL?
Closing this due to inactivity.