Ctrlpanel-gg / panel

CtrlPanel offers an easy-to-use and free billing solution for all starting and experienced hosting providers that seamlessly integrates with the Pterodactyl panel.
https://ctrlpanel.gg/
MIT License
390 stars 141 forks source link

[Bug]: Servers can be made with no server ID #915

Open OddDevelopment opened 8 months ago

OddDevelopment commented 8 months ago

What is your request about?

When the panel is running kind of slow sometimes controlpanel will make a server in the database with no server ID instead of just giving an error, This gives users an error 500 on there servers page.

Error on servers page (after create): image

Showing it in DB: Screenshot 2023-11-01 071539

Branch

main

Solution idea

Make controlpanel make sure theres a server ID before adding the server to the database

Controlpanel Logs

No response

Additional Info

No response

Ferks-FK commented 8 months ago

Can you explain more about "when the dashboard is running a bit slow"? Are you talking about the Ptero API or CPGG? Is the slowness a test done on your browser, or is the server slow? We need these details.

OddDevelopment commented 8 months ago

I have a really bad network for my VPS hosting pterodactyl so it should have timed out but for some reason still made it on the DB.

Its the server that is slow not the browser

Ferks-FK commented 6 months ago

I have not been able to reproduce this problem, every time the code fails, either due to a lack of allocation or a connection error with pterodactyl, the server is always excluded from the DB.

LavishSphere commented 6 months ago

It could be due to the fact we have over 3,500 servers on the database, even syncing most of the time fails.

sybetjeh commented 4 months ago

i was able to replicate this today^^, you need really very specific requirements.

limit your VPS's speed, and when it's creating a server (so its loading) you need to navigate to somewhere else like the homepage of your dashboard.

usually though once you then navigate back you'll see "null" popup and the server is deleted by cpgg, but sometimes i also get an 500. hit or miss

1day2die commented 4 months ago

lol damn. thanks