Bahn: aisupport, Analyse-O2C-C2S, awesome-bahn-mcp-servers, beam-mcp,
Confluence_Bot, db-planet-mcp-server, O2C-Harness, project-audit,
Projekt-KIQ-HP, teamlandkarte-mcp
Dhive: Jury-Voting
Privat: CV, NoteGraph (NOTE: NoteGraph needs complete redo after consolidation)
Shared: AI-Orchestrator, OrgMyLife, power_skills_and_more
Shared/references: symphony (read-only)
Bahn repos remain available as independent remotes - this monorepo
pulls them in via subtree, the originals are untouched.
77 lines
2.4 KiB
Python
77 lines
2.4 KiB
Python
"""Sucht offene Abrechnungs-Tickets in TTTSol/TTTI."""
|
|
import urllib.request, json, ssl, urllib.parse
|
|
|
|
secrets = {}
|
|
with open("project-audit/.secrets", "r", encoding="utf-8-sig") as f:
|
|
for line in f:
|
|
if "=" in line and not line.startswith("#"):
|
|
k, v = line.strip().split("=", 1)
|
|
secrets[k.strip()] = v.strip()
|
|
|
|
TOKEN = secrets.get("JIRA_TOKEN", "")
|
|
ctx = ssl.create_default_context()
|
|
ctx.check_hostname = False
|
|
ctx.verify_mode = ssl.CERT_NONE
|
|
|
|
def search(jql):
|
|
url = f"https://arija.jaas.service.deutschebahn.com/rest/api/2/search?jql={urllib.parse.quote(jql)}&maxResults=30&fields=key,summary,status,priority,assignee,updated,labels"
|
|
req = urllib.request.Request(url)
|
|
req.add_header("Authorization", f"Bearer {TOKEN}")
|
|
resp = urllib.request.urlopen(req, context=ctx, timeout=30)
|
|
return json.loads(resp.read().decode("utf-8"))
|
|
|
|
def print_issues(title, jql):
|
|
print(f"\n--- {title} ---")
|
|
r = search(jql)
|
|
total = r.get("total", 0)
|
|
print(f" Total: {total}")
|
|
for i in r.get("issues", [])[:20]:
|
|
f = i["fields"]
|
|
s = f["status"]["name"]
|
|
p = (f.get("priority") or {}).get("name", "?")
|
|
a = (f.get("assignee") or {}).get("displayName", "Unassigned")
|
|
labels = ", ".join(f.get("labels", []))
|
|
summary = f["summary"][:70]
|
|
print(f" {i['key']:<15} [{s:<14}] {p:<10} {summary}")
|
|
if a != "Unassigned" or labels:
|
|
extra = f"Assignee: {a}" if a != "Unassigned" else ""
|
|
if labels:
|
|
extra += f" Labels: {labels}"
|
|
print(f" {'':15} {extra}")
|
|
|
|
# Abrechnung offen
|
|
print_issues(
|
|
"Abrechnung (offen, TTTSol + TTTI)",
|
|
'text ~ "Abrechnung" AND (project = TTTSOL OR project = TTTI) AND statusCategory != Done ORDER BY priority DESC'
|
|
)
|
|
|
|
# AC Trasse
|
|
print_issues(
|
|
"AC Trasse (alle Projekte, offen)",
|
|
'text ~ "AC Trasse" AND statusCategory != Done ORDER BY priority DESC'
|
|
)
|
|
|
|
# O2CCIB-6931 direkt (implizite Annahme)
|
|
print_issues(
|
|
"O2CCIB-6931 - Implizite Annahme NAÄ",
|
|
'key = O2CCIB-6931'
|
|
)
|
|
|
|
# TTTSOL-2184 direkt (implizite Annahme Highest)
|
|
print_issues(
|
|
"TTTSOL-2184 - Umgang mit impliziter Annahme",
|
|
'key = TTTSOL-2184'
|
|
)
|
|
|
|
# TTTSOL-1677 (20h Tool)
|
|
print_issues(
|
|
"TTTSOL-1677 - 20h Tool",
|
|
'key = TTTSOL-1677'
|
|
)
|
|
|
|
# TTTSOL-2035 (Abrechnung Zugnummer Umleitungsfall)
|
|
print_issues(
|
|
"TTTSOL-2035 - Abrechnung Zugnummer Umleitungsfall",
|
|
'key = TTTSOL-2035'
|
|
)
|