Skip to content

API stops working. #478

Description

@dzinks2009

Describe the bug
Basically, the bug happens when my PHP script is making a request to the TS3AB API and while doing it, I exit out of my script.

To Reproduce
Make a script that would connect to the TS3AB API and make a simple request; it can even be like getting bot list or instance info. Then try to turn off and on the script a few times and you should see in your debug window of TS3AB "WebServer has closed".

Version
Version: 0.9.1
Branch: master
CommitHash: 673e0af

Platform
Ubuntu 16.04

Log

05:11:01| INFO| xx.xx.xxx.xx Requested: /api/bot/use/0/(/bot/info
05:11:03| INFO| xx.xx.xxx.xx Requested: /api/bot/use/0/(/bot/info
05:11:04| INFO| xx.xx.xxx.xx Requested: /api/bot/use/0/(/bot/info
05:11:06| INFO| xx.xx.xxx.xx Requested: /api/bot/use/0/(/bot/info
05:11:07| INFO| xx.xx.xxx.xx Requested: /api/bot/use/0/(/bot/info
05:11:08| INFO| xx.xx.xxx.xx Requested: /api/bot/use/0/(/bot/info
05:11:09| INFO| xx.xx.xxx.xx Requested: /api/bot/use/0/(/bot/info
05:11:10| INFO| WebServer has closed
System.Net.HttpListenerException (0x80004005): Listener closed
  at System.Net.ListenerAsyncResult.GetContext () [0x0001c] in <eeec8e88b1fc462e84ade7bf334d0c97>:0 
  at System.Net.HttpListener.EndGetContext (System.IAsyncResult asyncResult) [0x00099] in <eeec8e88b1fc462e84ade7bf334d0c97>:0 
  at System.Net.HttpListener.GetContext () [0x0002d] in <eeec8e88b1fc462e84ade7bf334d0c97>:0 
  at TS3AudioBot.Web.WebServer.EnterWebLoop () [0x0004e] in <cbb5379733f744b5a926811d68f3b8b4>:0 
03:23:39| INFO|WebServer.EnterWebLoop WebServer has closed

Then after this, nothing from the API shows if I request anything else.

If fixing it is not possible, I think relaunching web-server would be fine I guess but I don't think that's a "professional" way of fixing it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions