Jump to content

LSL HTTP requests don't redirect automatically


animats
 Share

You are about to reply to a thread that has been inactive for 1620 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

I have a script that makes HTTP requests to a server of mine. My demo and review bikes log region crossings. This has been working for over a year, but recently started failing. It makes them as HTTP requests, but the site now redirects them to the HTTPS port with a 301 Moved Permanently status. This is because Dreamhost made everything go through HTTPS, and is now redirecting all HTTP requests to the corresponding HTTPS URL.

So, my scripts print the error:

 Smooth Rider - V2.6.3 (DEMO): Logging request to http://███████████████████████████████████ failed. Status 301

The LSL HTTP interface doesn't automatically redirect in that situation. Most HTTP libraries handle this automatically, but LSL's does not.

So, if you're still using HTTP, not HTTPS, from LSL, you need to prepare for any "upgrades" from your hosting service.

Link to comment
Share on other sites

On 11/17/2019 at 3:00 PM, animats said:

The LSL HTTP interface doesn't automatically redirect in that situation. Most HTTP libraries handle this automatically, but LSL's does not.

LSL does do automatic redirection for GET (and HEAD) requests, but not for other HTTP methods.

  • Thanks 1
Link to comment
Share on other sites

1 hour ago, Oz Linden said:

LSL does do automatic redirection for GET (and HEAD) requests, but not for other HTTP methods.

That's what I figured. This is a  POST operation. The "user agent" is supposed to handle that redirection. Whether the LSL code or the underlying SL code is the "user agent" here is an interesting question. I'd argue that the underlying system should handle this, on the grounds that we can't afford to encapsulate HTTP requests in a library in LSL. Not in 64KB.

Link to comment
Share on other sites

1 hour ago, Rider Linden said:

Animats,  if you can open a feature request JIRA for following redirects on methods other than GET or HEAD so that it stays on our radar and we can take a bit of time to weigh the implications. 

I could, but I don't want to distract the Lindens from more serious problems. This is something users can easily work around, once they know it's there.

I  have 16 JIRAs on file. In two years, no feature request JIRA of mine has ever been implemented, and no bug report JIRA of mine has ever been fixed. I would rate the priority of this below anything I have pending, and don't want to distract staff from the big problems users can't work around, such as region crossing failures.

Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 1620 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...