Details
-
Bug
-
Resolution: Won't Fix
-
Medium
Description
Hi,
Bitbucket incorrectly calculates the number of users to charge you for. This is happening for me; but I will give an example of how it can happen to anyone.
- I was invited to join a team, and then fork one of the repositories
- As part of the standard review process, I am required to add-in a group which that team controls. It contains 3 members (I am well within my 5 user count).
- work continues
- They add additional people, bringing the number in the team that they control to 3000.
Who should pay for those extra 3000 users? The currently bitbucket algorithm believes that I should.
I think the algorithm to determine users should be fairly simple:
def users_chargable_on_repo(repo): to_charge = count_direct_users(repo) to_charge += count_users_within_groups_created_by_repo_forker(repo)
And then obviously you would tally up all users across all repos and then put into a set (so they aren't duplicated), giving you a total number to charge.
In my case the number should be 2. Which is under the 5 free threshold.
If you are able to give me a (rough) outline of the current algorithm and
some test cases, I am sure I could easily come up with a correct solution
for you.
As you can imagine, I am highly motivated to fix this billing problem.
Thanks,
Anand