Jump to content
Korean Random
Napalm

Bug in tankcarousel.py

Recommended Posts

Hello,
 
I think i found a bug in your code of tankcarousel.py.
 
My xvm.log contains the following message for multiple times:

2016-08-05 01:19:36: [ERROR] Traceback (most recent call last):
  File "xvm_tankcarousel/tankcarousel.py", line 110, in carousel_data_provider_vehicleComparisonKey
NameError: global name 'vehicles_stats' is not defined

 

I searched your repository for the file and found the following code in it:

            if sort_criterion == 'winRate':
                stats = vehicles_stats.get(vehicle.intCD)
                comparisonKey.append(factor if stats else 0)
                if stats:
                    winrate = float(stats.wins) / stats.battlesCount

 

The object vehicles_stats is not defined before using. The sorting critera "winrate" is without effect except a message in the log.

 

I posted here because I did not find a bugtracker. If there is any it would be nice if someone gives me the url.

 

Best regards

Napalm

Edited by Napalm

Share this post


Link to post

Short link
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...