Config File Corrupts itself?

CalegoCalego Join Date: 2013-01-24 Member: 181848Members, NS2 Map Tester
edited December 2014 in Server Discussion
Alright I made a panic post 2 days ago, then figured the problem was done, but the same thing happened again, on the same server.

http://pastebin.com/7jy9JUuk
I've got a log full of that.

Same error as when the config file had to be reset. Here's my config file at the moment:
{
  "tags":["Veteran"],
  "settings":{
    "end_round_on_team_unbalance_check_after_time":300,
    "rookie_friendly":false,
    "auto_kick_afk_capacity":0.5,
    "force_even_teams_on_join":false,
    "end_round_on_team_unbalance":false,
    "voting":{
      "voterandomizerr":false,
      "votechangemap":true,
      "votingforceeventeams":true,
      "voteresetgame":true,
      "votekickplayer":true
    },
    "pregamealltalk":false,
    "auto_team_balance":false,
    "jit_maxmcode":35000,
    "auto_kick_afk_time":300,
    "alltalk":false,
    "use_own_consistency_config":false,
    "end_round_on_team_unbalance_after_warning_time":30,
    "hiveranking":true,
    "jit_maxtrace":21000
  }
}

I'm going to delete and reboot server. And now it works again.

Here's the new config file:
{
  "tags":["rookie"],
  "settings":{
    "jit_maxtrace":20000,
    "rookie_friendly":true,
    "auto_kick_afk_capacity":0.5,
    "jit_maxmcode":35000,
    "end_round_on_team_unbalance":0.4,
    "force_even_teams_on_join":true,
    "pregamealltalk":false,
    "voting":{
      "voterandomizerr":true,
      "votechangemap":true,
      "votingforceeventeams":true,
      "voteresetgame":true,
      "votekickplayer":true
    },
    "auto_team_balance":{
      "enabled_after_seconds":10,
      "enabled_on_unbalance_amount":2
    },
    "auto_kick_afk_time":300,
    "alltalk":false,
    "use_own_consistency_config":false,
    "end_round_on_team_unbalance_after_warning_time":30,
    "hiveranking":true,
    "end_round_on_team_unbalance_check_after_time":300
  }
}

The only thing I change is the tag to "veteran", rookie_friendly to "false" (why is the default true?), force_even_teams_on_join: false, and voterandomizer: false.

I'll update you when this breaks spontaneously again.

Comments

  • Person8880Person8880 Join Date: 2013-01-02 Member: 177167Members, Squad Five Blue
    The problem is an oversight in the way the game's checking the config.

    Specifically:
    "auto_team_balance":false
    
    compared to the default:
    "auto_team_balance":{
          "enabled_after_seconds":10,
          "enabled_on_unbalance_amount":2
    }
    

    Basically, it's expecting a table value under auto_team_balance to check the values inside, but instead it's getting a boolean and of course it can't iterate that so it errors.

    Unfortunately, this means it's actually currently impossible to disable auto balance as if you omit the key it'll just add it back with the default settings, and similarly if you just pass in an empty table value.
  • CalegoCalego Join Date: 2013-01-24 Member: 181848Members, NS2 Map Tester
    Person8880 wrote: »
    The problem is an oversight in the way the game's checking the config.

    Specifically:
    "auto_team_balance":false
    
    compared to the default:
    "auto_team_balance":{
          "enabled_after_seconds":10,
          "enabled_on_unbalance_amount":2
    }
    

    Basically, it's expecting a table value under auto_team_balance to check the values inside, but instead it's getting a boolean and of course it can't iterate that so it errors.

    Unfortunately, this means it's actually currently impossible to disable auto balance as if you omit the key it'll just add it back with the default settings, and similarly if you just pass in an empty table value.

    What's weird to me is that I just recently reset the config file to the default, then made some tweaks (but not to the auto_team_balance setting). I must have accidentally saved back to an older version of the config, macs do strange things sometimes. Anyhow, thanks for pointing out the error. I'll make double sure of this if it happens again.
  • DC_DarklingDC_Darkling Join Date: 2003-07-10 Member: 18068Members, Constellation, Squad Five Blue, Squad Five Silver
    I recently also had the server config garbled up into pure nonsense.
    But I do not change the autobalance variable.

    Anyone have any other ideas?
    The garbled file contained nothing of value.
Sign In or Register to comment.