Skip to content

Commit

Permalink
Merge pull request RazTamir#52 from RazTamir/add_board_configuration
Browse files Browse the repository at this point in the history
Many new feature and changes
  • Loading branch information
RazTamir authored Dec 5, 2019
2 parents 683672b + 227505e commit ecdc49f
Show file tree
Hide file tree
Showing 7 changed files with 32 additions and 27 deletions.
5 changes: 1 addition & 4 deletions arrivals_vs_resolved.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
#!/usr/bin/env python
import google_api as gapi
from helpers import *
from datetime import datetime, timedelta

now = datetime.today() - timedelta(days=1)
g = gapi.GoogleSpreadSheetAPI(
f'{PRODUCT} QE - Quality Dashboard', "arrivals_vs_resolved_data"
)
g = gapi.GoogleSpreadSheetAPI(SPREADSHEET_NAME, "arrivals_vs_resolved_data")

new_bugs = get_new_arrivals(
changed_from=now.strftime("%Y-%m-%d"), changed_to=now.strftime("%Y-%m-%d")
Expand Down
5 changes: 1 addition & 4 deletions avarage_qa_score.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#!/usr/bin/env python
import google_api as gapi
from helpers import *
from datetime import datetime

Expand All @@ -9,9 +8,7 @@


now = datetime.today()
g = gapi.GoogleSpreadSheetAPI(
f'{PRODUCT} QE - Quality Dashboard', "average_quality_score_data"
)
g = gapi.GoogleSpreadSheetAPI(SPREADSHEET_NAME, "average_quality_score_data")

all_bugs = get_overall_backlog()
if len(all_bugs) > 0:
Expand Down
2 changes: 1 addition & 1 deletion bugzilla_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import datetime

from helpers import *
from personal_config import *
from config import *
import sys

temp = sys.stdout
Expand Down
31 changes: 26 additions & 5 deletions config.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,35 @@
import bugzilla
from personal_config import *
import yaml
import sys
import os
import google_api as gapi

# [CHANGE NEEDED] Add the relevant information for you report
PRODUCT = 'OCS'
VERSION = "4.2"
BUGZILLA_PRODUCT = 'Red Hat OpenShift Container Storage'
cfg_path = os.path.expanduser('~/.gapi/personal_cfg.yml')

if len(sys.argv) != 2:
raise IndexError("You must provide the spreadsheet name to work with")

SPREADSHEET_NAME = sys.argv[1]
with open(cfg_path, 'r') as ymlfile:
cfg = yaml.full_load(ymlfile)
USER = cfg['bugzilla']['user']
PASSWORD = cfg['bugzilla']['password']

# For the Bugzilla reports
gmail_user = cfg['bugzilla_report']['gmail_address']
gmail_pwd = cfg['bugzilla_report']['gmail_pass']
mail_to = USER

g = gapi.GoogleSpreadSheetAPI(SPREADSHEET_NAME, "Dashboard configuration")

PRODUCT = g.get_cell_value(7, 3)
BUGZILLA_PRODUCT = g.get_cell_value(7, 4)
VERSION = g.get_cell_value(7, 6)
# The version flag should contain only x and y releases:
# ocs-4.2.0 --> ocs-x.y.z so you'll need to add only ocs-4.2 in order to see
# all bugs in version x.y
BUGZILLA_VERSION_FLAG = 'ocs-4.2'
BUGZILLA_VERSION_FLAG = g.get_cell_value(7, 5)

# [CHANGE NEEDED] List here all the teams you want to sample, for example:
team1 = "manage"
Expand Down
5 changes: 1 addition & 4 deletions release_readiness_criteria.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
#!/usr/bin/env python
import google_api as gapi
import time
from helpers import *
import datetime

now = datetime.datetime.now()
g = gapi.GoogleSpreadSheetAPI(
f'{PRODUCT} QE - Quality Dashboard', "Release Readiness Criteria"
)
g = gapi.GoogleSpreadSheetAPI(SPREADSHEET_NAME, "Release Readiness Criteria")


g.update_sheet(1, 1, f'Last update: {now.strftime("%Y-%m-%d %H:%M")}')
Expand Down
6 changes: 1 addition & 5 deletions scale_n_perf_defects.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
#!/usr/bin/env python
import time
import google_api as gapi
from helpers import *
import datetime

now = datetime.datetime.now()
g = gapi.GoogleSpreadSheetAPI(
f'{PRODUCT} QE - Quality Dashboard', "Performance & scale blockers"
)
g = gapi.GoogleSpreadSheetAPI(SPREADSHEET_NAME, "Performance & scale blockers")

g.update_sheet(1, 1, f'Last update: {now.strftime("%Y-%m-%d %H:%M")}')

Expand Down
5 changes: 1 addition & 4 deletions tracking_dashboard.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
#!/usr/bin/env python
import time
import google_api as gapi
from helpers import *
import datetime

now = datetime.datetime.now()
g = gapi.GoogleSpreadSheetAPI(
f'{PRODUCT} QE - Quality Dashboard', "QE tracking dashboard"
)
g = gapi.GoogleSpreadSheetAPI(SPREADSHEET_NAME, "QE tracking dashboard")

g.update_sheet(1, 1, f'Last update: {now.strftime("%Y-%m-%d %H:%M")}')

Expand Down

0 comments on commit ecdc49f

Please sign in to comment.