Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RestInterfaceClient: 301 causes an Exception #3066

Open
Geod24 opened this issue Feb 17, 2022 · 1 comment
Open

RestInterfaceClient: 301 causes an Exception #3066

Geod24 opened this issue Feb 17, 2022 · 1 comment
Labels
type-bug Things don't work as they were intended to, or the way they were intended to work doesn't make sense
Milestone

Comments

@Geod24
Copy link
Collaborator

Geod24 commented Feb 17, 2022

Seen live:

2022-02-16 01:39:18,752 Info [agora.network.Manager] - Couldn't register our address: vibe.web.common.RestException@submodules/vibe.d/web/vibe/web/rest.d(2080): Moved Permanently
----------------
submodules/vibe.d/web/vibe/web/rest.d:2080 @safe vibe.http.client.HTTPClientResponse vibe.web.rest.request(vibe.inet.url.URL, void delegate(vibe.http.client.HTTPClientRequest) @safe, scope void delegate(vibe.http.client.HTTPClientRequest, scope vibe.core.stream.InputStream) @safe, vibe.http.common.HTTPMethod, immutable(char)[], scope ref const(vibe.utils.dictionarylist.DictionaryList!(immutable(char)[], false, 12uL, false).DictionaryList), immutable(char)[], immutable(char)[], ref vibe.utils.dictionarylist.DictionaryList!(immutable(char)[], false, 12uL, false).DictionaryList, ref vibe.utils.dictionarylist.DictionaryList!(immutable(char)[], false, 12uL, false).DictionaryList, in vibe.http.client.HTTPClientSettings) [0x55908f379e43]
source/agora/api/Admin.d:1945 @safe void vibe.web.rest.executeClientMethod!(agora.api.Registry.NameRegistryAPI, 1, vibe.web.rest.RestInterfaceClient!(agora.api.Registry.NameRegistryAPI).RestInterfaceClient.__mixin20.postValidator(agora.api.Registry.RegistryPayloadData, agora.crypto.Schnorr.Signature).data, vibe.web.rest.RestInterfaceClient!(agora.api.Registry.NameRegistryAPI).RestInterfaceClient.__mixin20.postValidator(agora.api.Registry.RegistryPayloadData, agora.crypto.Schnorr.Signature).sig).executeClientMethod(scope ref const(vibe.web.internal.rest.common.RestInterface!(agora.api.Registry.NameRegistryAPI).RestInterface), void delegate(vibe.http.client.HTTPClientRequest) @safe, scope void delegate(vibe.http.client.HTTPClientRequest, scope vibe.core.stream.InputStream) @safe) [0x55908ef63cd8]
submodules/vibe.d/utils/vibe/internal/meta/codegen.d-mixin-301:304 @safe void vibe.web.rest.RestInterfaceClient!(agora.api.Registry.NameRegistryAPI).RestInterfaceClient.__mixin20.postValidator(agora.api.Registry.RegistryPayloadData, agora.crypto.Schnorr.Signature) [0x55908ef6361b]
source/agora/network/Manager.d:735 @safe void agora.network.Manager.NetworkManager.onRegisterName() [0x55908eb0783e]
source/agora/common/Task.d:76 [0x55908ee4e367]
source/agora/common/Task.d:73 [0x55908ee4e34c]
submodules/vibe-core/source/vibe/core/core.d:1115 [0x55908f60029f]
submodules/vibe-core/source/vibe/core/task.d:721 nothrow void vibe.core.task.TaskFuncInfo.set!(void delegate(vibe.core.core.Timer) nothrow @safe, vibe.core.core.Timer).set(ref void delegate(vibe.core.core.Timer) nothrow @safe, ref vibe.core.core.Timer).callDelegate(ref vibe.core.task.TaskFuncInfo) [0x55908f6404f5]
submodules/vibe-core/source/vibe/core/task.d:739 void vibe.core.task.TaskFuncInfo.call() [0x55908f63de4b]
submodules/vibe-core/source/vibe/core/task.d:446 nothrow void vibe.core.task.TaskFiber.run() [0x55908f63d5a9]
??:? fiber_entryPoint [0x55908f7f764a]. Trying again later..

This happened because the endpoint was configured with http, and Nginx would redirect http to https, but 301 should just be followed IMO. Set as "Unbounded" as we can work around it for now.

@Geod24 Geod24 added the type-bug Things don't work as they were intended to, or the way they were intended to work doesn't make sense label Feb 17, 2022
@Geod24 Geod24 added this to the 99. Unbounded milestone Feb 17, 2022
@Geod24
Copy link
Collaborator Author

Geod24 commented Feb 18, 2022

Upstream: vibe-d/vibe.d#2642

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type-bug Things don't work as they were intended to, or the way they were intended to work doesn't make sense
Projects
None yet
Development

No branches or pull requests

2 participants
@Geod24 and others