Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions grimoirelab_metrics/metrics.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,12 +301,12 @@ def get_recent_organizations(self):
return len(self.recent_organizations)

def get_recent_contributors(self):
"""Return the number of contributors from the last 90d."""
"""Return the number of contributors from the last 365d."""

return len(self.recent_contributors)

def get_recent_commits(self) -> int:
"""Return the number of commits in the last 90d."""
"""Return the number of commits in the last 365d."""

return self.recent_commits

Expand Down Expand Up @@ -417,7 +417,7 @@ def _update_commit_count(self, event_data):
except (ValueError, TypeError, InvalidDateError):
return

if days_interval <= 90:
if days_interval <= 365:
self.recent_commits += 1

# Update commits per month
Expand Down Expand Up @@ -448,7 +448,7 @@ def _update_contributors(self, event_data):
# Update contributors by period
if commit_date:
days_interval = (self.to_date - commit_date).days
if days_interval <= 90:
if days_interval <= 365:
self.recent_contributors.add(author)
self.returning_contributors["second_period"].add(author)
else:
Expand All @@ -470,7 +470,7 @@ def _update_organizations(self, event_data):
except (ValueError, TypeError, InvalidDateError):
pass
else:
if days_interval <= 90:
if days_interval <= 365:
self.recent_organizations.add(organization)

def _update_file_metrics(self, event):
Expand Down
Loading