firefighter-incident 0.0.4__py3-none-any.whl → 0.0.6__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- firefighter/_version.py +2 -2
- firefighter/incidents/forms/close_incident.py +1 -1
- firefighter/incidents/forms/create_incident.py +1 -1
- firefighter/incidents/forms/update_status.py +1 -1
- firefighter/incidents/migrations/0010_update_components.py +102 -0
- firefighter/incidents/migrations/0011_update_incidents.py +87 -0
- firefighter/incidents/migrations/0012_alter_impactlevel.py +42 -0
- firefighter/incidents/migrations/0013_add_missing_component.py +61 -0
- firefighter/incidents/migrations/0014_update_components_slack_groups.py +177 -0
- firefighter/incidents/models/incident.py +1 -1
- firefighter/incidents/templates/pages/component_detail.html +1 -1
- firefighter/incidents/views/components/list.py +1 -1
- firefighter/slack/migrations/0004_alter_usergroup_components.py +24 -0
- firefighter/slack/models/user_group.py +1 -1
- firefighter/slack/views/modals/opening/details/critical.py +1 -1
- firefighter/slack/views/modals/update_status.py +1 -1
- {firefighter_incident-0.0.4.dist-info → firefighter_incident-0.0.6.dist-info}/METADATA +1 -1
- {firefighter_incident-0.0.4.dist-info → firefighter_incident-0.0.6.dist-info}/RECORD +24 -18
- firefighter_tests/test_incidents/test_forms/test_form_utils.py +2 -2
- firefighter_tests/test_slack/views/modals/test_close.py +2 -2
- firefighter_tests/test_slack/views/modals/test_update_status.py +2 -2
- {firefighter_incident-0.0.4.dist-info → firefighter_incident-0.0.6.dist-info}/WHEEL +0 -0
- {firefighter_incident-0.0.4.dist-info → firefighter_incident-0.0.6.dist-info}/entry_points.txt +0 -0
- {firefighter_incident-0.0.4.dist-info → firefighter_incident-0.0.6.dist-info}/licenses/LICENSE +0 -0
firefighter/_version.py
CHANGED
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
|
|
2
|
+
import logging
|
|
3
|
+
|
|
4
|
+
from django.db import migrations
|
|
5
|
+
|
|
6
|
+
logger = logging.getLogger(__name__)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
def get_component_mappings() -> list:
|
|
10
|
+
"""
|
|
11
|
+
Returns a list of tuples for updating existing component names and their attributes.
|
|
12
|
+
|
|
13
|
+
Each tuple contains:
|
|
14
|
+
- old_name (str): The current name of the component.
|
|
15
|
+
- new_name (str): The new name to assign to the component.
|
|
16
|
+
- slack_channel (str): The associated Slack channel for the component.
|
|
17
|
+
- group_name (str): The name of the group to which the component belongs.
|
|
18
|
+
|
|
19
|
+
Returns:
|
|
20
|
+
list: A list of tuples, each representing the details for a component update.
|
|
21
|
+
"""
|
|
22
|
+
return [
|
|
23
|
+
# Marketplace
|
|
24
|
+
("Product Discovery", "Navigation & Product discovery", "impact-nav-product-discovery", "Marketplace"),
|
|
25
|
+
("User & Purchase", "Cart & funnel", "impact-cart-funnel", "Marketplace"),
|
|
26
|
+
("Customer Management", "Customer login & signup", "impact-customer-login-signup", "Marketplace"),
|
|
27
|
+
("Performance", "Web performance", "impact-web-performance", "Marketplace"),
|
|
28
|
+
# Catalog
|
|
29
|
+
("Product Information", "Product Management", "impact-product-management", "Catalog"),
|
|
30
|
+
("Taxonomy", "Product Structure", "impact-product-structure", "Catalog"),
|
|
31
|
+
("Publication on website", "Catalog Exposition", "impact-catalog-exposition", "Catalog"),
|
|
32
|
+
# Payment Operations
|
|
33
|
+
("Payment", "Payment", "impact-payment", "Payment Operations"),
|
|
34
|
+
# Operations
|
|
35
|
+
("ManoFulfillment OPS", "MM Fulfillment", "impact-mm-fulfillment", "Operations"),
|
|
36
|
+
("Helpcenter", "Helpcenter after sales", "impact-helpcenter-after-sales", "Operations"),
|
|
37
|
+
# Finance
|
|
38
|
+
("Finance Operations", "Controlling", "impact-controlling", "Finance"),
|
|
39
|
+
# Platform
|
|
40
|
+
("Spinak", "Spinak", "impact-spinak", "Platform"),
|
|
41
|
+
("CDN", "CDN", "impact-cdn", "Platform"),
|
|
42
|
+
("Gitlab", "Gitlab", "impact-gitlab", "Platform"),
|
|
43
|
+
# Data
|
|
44
|
+
("data-platform", "Data Ingestion", "impact-data-ingestion", "Data"),
|
|
45
|
+
("data-specialist-offer", "Data Warehouse", "impact-data-warehouse", "Data"),
|
|
46
|
+
("data-wbr", "Data Analytics", "impact-data-analytics", "Data"),
|
|
47
|
+
# Security
|
|
48
|
+
("Security Misc", "Bot management & rate limiting & WAF", "impact-bot-management-rate-limiting-waf", "Security"),
|
|
49
|
+
("Attack", "Data leak", "impact-data-leak", "Security"),
|
|
50
|
+
("System Compromise", "Exploited vulnerability", "impact-exploited-vulnerability", "Security"),
|
|
51
|
+
("Personal Data Breach", "Stolen account(s) or IT materials", "impact-stolen-accounts-it-materials", "Security"),
|
|
52
|
+
]
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
def update_component_names(apps, schema_editor):
|
|
56
|
+
Component = apps.get_model("incidents", "Component")
|
|
57
|
+
Group = apps.get_model("incidents", "Group")
|
|
58
|
+
component_mappings = get_component_mappings()
|
|
59
|
+
|
|
60
|
+
updated_count = 0
|
|
61
|
+
|
|
62
|
+
for old_name, new_name, _slack_channel, group_name in component_mappings:
|
|
63
|
+
try:
|
|
64
|
+
component = Component.objects.get(name=old_name)
|
|
65
|
+
logger.info(f"Updating: '{old_name}' to '{new_name}'")
|
|
66
|
+
component.name = new_name
|
|
67
|
+
|
|
68
|
+
group_instance = Group.objects.get(name=group_name)
|
|
69
|
+
component.group = group_instance
|
|
70
|
+
component.save()
|
|
71
|
+
updated_count += 1
|
|
72
|
+
except Exception:
|
|
73
|
+
logger.exception(f"Component '{old_name}' does not exist, cannot proceed with updates.")
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
def revert_component_names(apps, schema_editor):
|
|
77
|
+
Component = apps.get_model("incidents", "Component")
|
|
78
|
+
reverse_mappings = {new_name: old_name for old_name, new_name, _, _ in get_component_mappings()}
|
|
79
|
+
|
|
80
|
+
updated_count = 0
|
|
81
|
+
|
|
82
|
+
for new_name, old_name in reverse_mappings.items():
|
|
83
|
+
|
|
84
|
+
try:
|
|
85
|
+
component = Component.objects.get(name=new_name)
|
|
86
|
+
logger.info(f"Restoring '{new_name}' back to '{old_name}'")
|
|
87
|
+
component.name = old_name
|
|
88
|
+
component.save()
|
|
89
|
+
updated_count += 1
|
|
90
|
+
except Exception:
|
|
91
|
+
logger.exception(f"Component '{new_name}' does not exist, skipping restoration.")
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
class Migration(migrations.Migration):
|
|
95
|
+
|
|
96
|
+
dependencies = [
|
|
97
|
+
("incidents", "0009_update_sla"),
|
|
98
|
+
]
|
|
99
|
+
|
|
100
|
+
operations = [
|
|
101
|
+
migrations.RunPython(update_component_names, revert_component_names),
|
|
102
|
+
]
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import logging
|
|
2
|
+
|
|
3
|
+
from django.db import migrations, transaction
|
|
4
|
+
|
|
5
|
+
logger = logging.getLogger(__name__)
|
|
6
|
+
|
|
7
|
+
COMPONENT_MAPPING = {
|
|
8
|
+
"Internal Messaging": "Helpcenter after sales",
|
|
9
|
+
"Crisis Communication Room": "Other",
|
|
10
|
+
"data-visitors": "Data Ingestion",
|
|
11
|
+
"data-buyers": "Data Ingestion",
|
|
12
|
+
"Seller Order": "Seller Admin and Experience",
|
|
13
|
+
"Legacy": "Other",
|
|
14
|
+
"Authentification": "Customer login & signup",
|
|
15
|
+
"data-operations": "Data Ingestion",
|
|
16
|
+
"Test Incident": "Other",
|
|
17
|
+
"Legal": "Other",
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
# Global variable to store incidents with the previous component
|
|
21
|
+
# This will be used to restore the original component in case of rollback
|
|
22
|
+
INCIDENTS_BACKUP = {}
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
def forwards_func(apps, _schema_editor):
|
|
26
|
+
Incident = apps.get_model("incidents", "Incident")
|
|
27
|
+
Component = apps.get_model("incidents", "Component")
|
|
28
|
+
with transaction.atomic():
|
|
29
|
+
for old_component_name, new_component_name in COMPONENT_MAPPING.items():
|
|
30
|
+
old_component = Component.objects.filter(name=old_component_name).first()
|
|
31
|
+
if not old_component:
|
|
32
|
+
logger.error(f"Failed to find component {old_component_name}.")
|
|
33
|
+
continue
|
|
34
|
+
incidents = Incident.objects.filter(component=old_component)
|
|
35
|
+
ids = list(incidents.values_list("id", flat=True))
|
|
36
|
+
if ids:
|
|
37
|
+
INCIDENTS_BACKUP[old_component_name] = ids
|
|
38
|
+
new_component = Component.objects.filter(name=new_component_name).first()
|
|
39
|
+
if not new_component:
|
|
40
|
+
logger.error(f"Failed to find component {new_component_name}.")
|
|
41
|
+
continue
|
|
42
|
+
incidents.update(component=new_component)
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
def backwards_func(apps, _schema_editor):
|
|
46
|
+
Incident = apps.get_model("incidents", "Incident")
|
|
47
|
+
Component = apps.get_model("incidents", "Component")
|
|
48
|
+
with transaction.atomic():
|
|
49
|
+
for old_component_name, ids in INCIDENTS_BACKUP.items():
|
|
50
|
+
old_component = Component.objects.filter(name=old_component_name).first()
|
|
51
|
+
if not old_component:
|
|
52
|
+
logger.error(f"Failed to find component {old_component_name}.")
|
|
53
|
+
continue
|
|
54
|
+
Incident.objects.filter(id__in=ids).update(component=old_component)
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
def delete_old_components(apps, _schema_editor):
|
|
58
|
+
Component = apps.get_model("incidents", "Component")
|
|
59
|
+
try:
|
|
60
|
+
for old_name in COMPONENT_MAPPING:
|
|
61
|
+
Component.objects.filter(name=old_name).delete()
|
|
62
|
+
except Exception:
|
|
63
|
+
logger.exception(f"Failed to delete old components {old_name}.")
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
def recreate_old_components(apps, _schema_editor):
|
|
67
|
+
Component = apps.get_model("incidents", "Component")
|
|
68
|
+
try:
|
|
69
|
+
for old_name in COMPONENT_MAPPING:
|
|
70
|
+
Component.objects.get_or_create(name=old_name)
|
|
71
|
+
except Exception:
|
|
72
|
+
logger.exception(f"Failed to recreate old components {old_name}.")
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
class Migration(migrations.Migration):
|
|
76
|
+
|
|
77
|
+
dependencies = [
|
|
78
|
+
("incidents", "0010_update_components"),
|
|
79
|
+
]
|
|
80
|
+
|
|
81
|
+
operations = [
|
|
82
|
+
migrations.RunPython(forwards_func, backwards_func),
|
|
83
|
+
migrations.RunPython(
|
|
84
|
+
delete_old_components,
|
|
85
|
+
recreate_old_components,
|
|
86
|
+
),
|
|
87
|
+
]
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# Generated by Django 4.2.21 on 2025-06-02 16:29
|
|
2
|
+
import uuid
|
|
3
|
+
|
|
4
|
+
from django.db import migrations, models
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class Migration(migrations.Migration):
|
|
8
|
+
|
|
9
|
+
dependencies = [
|
|
10
|
+
("incidents", "0011_update_incidents"),
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
operations = [
|
|
14
|
+
migrations.AlterField(
|
|
15
|
+
model_name="impactlevel",
|
|
16
|
+
name="id",
|
|
17
|
+
field=models.UUIDField(
|
|
18
|
+
default=uuid.uuid4, editable=False, primary_key=True, serialize=False
|
|
19
|
+
),
|
|
20
|
+
),
|
|
21
|
+
migrations.AlterField(
|
|
22
|
+
model_name="impactlevel",
|
|
23
|
+
name="value",
|
|
24
|
+
field=models.CharField(
|
|
25
|
+
choices=[
|
|
26
|
+
("HT", "Highest"),
|
|
27
|
+
("HI", "High"),
|
|
28
|
+
("MD", "Medium"),
|
|
29
|
+
("LO", "Low"),
|
|
30
|
+
("LT", "Lowest"),
|
|
31
|
+
("NO", "N/A"),
|
|
32
|
+
],
|
|
33
|
+
default="LT",
|
|
34
|
+
max_length=2,
|
|
35
|
+
),
|
|
36
|
+
),
|
|
37
|
+
migrations.AlterField(
|
|
38
|
+
model_name="impacttype",
|
|
39
|
+
name="emoji",
|
|
40
|
+
field=models.CharField(default="▶", max_length=5),
|
|
41
|
+
),
|
|
42
|
+
]
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import logging
|
|
2
|
+
|
|
3
|
+
from django.db import migrations
|
|
4
|
+
|
|
5
|
+
logger = logging.getLogger(__name__)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
def get_new_components() -> dict:
|
|
9
|
+
"""
|
|
10
|
+
Returns a dictionary of new components to be created.
|
|
11
|
+
|
|
12
|
+
Each entry in the dictionary maps a component name to a tuple containing:
|
|
13
|
+
- group_name: The name of the group the component belongs to.
|
|
14
|
+
- slack_channel: The associated Slack channel for the component.
|
|
15
|
+
|
|
16
|
+
Returns:
|
|
17
|
+
dict: A mapping of component names to (group name, slack channel) tuples.
|
|
18
|
+
"""
|
|
19
|
+
return {
|
|
20
|
+
"Data Tools": ("Data", "impact-data-tools"),
|
|
21
|
+
"Catalog Access": ("Catalog", "impact-catalog-access"),
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
def add_new_components(apps, schema_editor):
|
|
26
|
+
Component = apps.get_model("incidents", "Component")
|
|
27
|
+
Group = apps.get_model("incidents", "Group")
|
|
28
|
+
new_components = get_new_components()
|
|
29
|
+
|
|
30
|
+
for name, (group_name, _slack) in new_components.items():
|
|
31
|
+
logger.info(f"Creating new component: '{name}' belonging to group '{group_name}'")
|
|
32
|
+
try:
|
|
33
|
+
group_instance = Group.objects.get(name=group_name)
|
|
34
|
+
new_component = Component(name=name, group=group_instance)
|
|
35
|
+
new_component.save()
|
|
36
|
+
except Exception:
|
|
37
|
+
logger.exception(f"Failed to create new group: '{group_name}'.")
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
def remove_new_components(apps, schema_editor):
|
|
41
|
+
Component = apps.get_model("incidents", "Component")
|
|
42
|
+
new_component_names = get_new_components().keys()
|
|
43
|
+
|
|
44
|
+
for name in new_component_names:
|
|
45
|
+
try:
|
|
46
|
+
component = Component.objects.get(name=name)
|
|
47
|
+
logger.info(f"Removing component: '{name}'")
|
|
48
|
+
component.delete()
|
|
49
|
+
except Exception:
|
|
50
|
+
logger.exception(f"Component '{name}' does not exist, skipping removal.")
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
class Migration(migrations.Migration):
|
|
54
|
+
|
|
55
|
+
dependencies = [
|
|
56
|
+
("incidents", "0012_alter_impactlevel"),
|
|
57
|
+
]
|
|
58
|
+
|
|
59
|
+
operations = [
|
|
60
|
+
migrations.RunPython(add_new_components, remove_new_components),
|
|
61
|
+
]
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
import logging
|
|
2
|
+
|
|
3
|
+
from django.db import migrations, transaction
|
|
4
|
+
|
|
5
|
+
logger = logging.getLogger(__name__)
|
|
6
|
+
|
|
7
|
+
COMPONENT_SLACK_GROUPS = {
|
|
8
|
+
"Controlling": ("S08UYJGJ9HB", "finance-controlling"),
|
|
9
|
+
"Applications": ("S08V22ZJ6DQ", "corporate-it-applications"),
|
|
10
|
+
"Gitlab": ("S090A6LQ0U8", "platform-gitlab"),
|
|
11
|
+
"Seller Admin and Experience": ("S08UV261ZRU", "seller-seller-admin-and-experience"),
|
|
12
|
+
"Revenue": ("S08V22ZPBBL", "finance-revenue"),
|
|
13
|
+
"Catalog Exposition": ("S08VD2WE5ND", "catalog-catalog-exposition"),
|
|
14
|
+
"Company reputation": ("S090A63V7FS", "marketing-communication-company-reputation"),
|
|
15
|
+
"BO Catalog - Master Experience": ("S08VD2Y1DMF", "catalog-bo-catalog-master-experience"),
|
|
16
|
+
"Customer service": ("S08UV2GB7UN", "operations-customer-service"),
|
|
17
|
+
"Seller's invoices": ("S08VD38AFFB", "finance-sellers-invoices"),
|
|
18
|
+
"Cart & funnel": ("S08V2N7PRN0", "marketplace-cart-funnel"),
|
|
19
|
+
"Data Ingestion": ("S08UYJHEFEH", "data-data-ingestion"),
|
|
20
|
+
"Refunds": ("S08UM14D3LP", "payment-operations-refunds"),
|
|
21
|
+
"Data Analytics": ("S08V2NNDG9J", "data-data-analytics"),
|
|
22
|
+
"Mobile Apps": ("S08UV20CL6S", "marketplace-mobile-apps"),
|
|
23
|
+
"Navigation & Product discovery": ("S08UYHZFFD3", "marketplace-navigation-product-discovery"),
|
|
24
|
+
"Helpcenter after sales": ("S08UU3SHQTV", "operations-helpcenter-after-sales"),
|
|
25
|
+
"CDN": ("S08UM12RNTZ", "platform-cdn"),
|
|
26
|
+
"Customer's invoices": ("S08UYJGELJH", "finance-customers-invoices"),
|
|
27
|
+
"Returns": ("S08UYJHDNQM", "operations-returns"),
|
|
28
|
+
"Inventory": ("S08V2NNLW3W", "operations-inventory"),
|
|
29
|
+
"Loyalty and coupons": ("S08V230H1V0", "payment-operations-loyalty-and-coupons"),
|
|
30
|
+
"Seller Services": ("S08UM0SJ66T", "seller-seller-services"),
|
|
31
|
+
"Spinak": ("S08UYJGRTE1", "platform-spinak"),
|
|
32
|
+
"Data Tools": ("S08V2NPFDPE", "data-data-tools"),
|
|
33
|
+
"Product Management": ("S08UYJ5GU93", "catalog-product-management"),
|
|
34
|
+
"Compromised laptop / server": ("S08UU3T6H51", "security-compromised-laptop-server"),
|
|
35
|
+
"Catalog Performance": ("S08V22QDHJ6", "catalog-catalog-performance"),
|
|
36
|
+
"Spartacux Foundations": ("S08UYHZH97X", "marketplace-spartacux-foundations"),
|
|
37
|
+
"Stolen account(s) or IT materials": ("S08UU3TFJ3D", "security-stolen-accounts-or-it-materials"),
|
|
38
|
+
"MM Fulfillment": ("S08VD371F0R", "operations-mm-fulfillment"),
|
|
39
|
+
"HUB Integrators": ("S08UM0SSNNB", "seller-hub-integrators"),
|
|
40
|
+
"Exploited vulnerability": ("S08V2NPD084", "security-exploited-vulnerability"),
|
|
41
|
+
"Commercial Animation": ("S08V2N6UA3E", "marketplace-commercial-animation"),
|
|
42
|
+
"Cloud Infrastructure": ("S08UYJJ01HB", "platform-cloud-infrastructure"),
|
|
43
|
+
"Tracking": ("S08UYHZPSTX", "marketplace-tracking"),
|
|
44
|
+
"Data Warehouse": ("S08UYJHRWQ5", "data-data-warehouse"),
|
|
45
|
+
"Infra - System": ("S08UV2H5WDC", "corporate-it-infra-system"),
|
|
46
|
+
"VAT": ("S090A6LGGV6", "finance-vat"),
|
|
47
|
+
"Web performance": ("S090A63K124", "marketplace-web-performance"),
|
|
48
|
+
"Payouts to seller": ("S090A6M61A4", "payment-operations-payouts-to-seller"),
|
|
49
|
+
"Seller Catalog and Offer Management": ("S08UV261CHL", "seller-seller-catalog-and-offer-management"),
|
|
50
|
+
"Other": ("S08V22Z8S58", "other-other"),
|
|
51
|
+
"Network": ("S090A6M3B7S", "corporate-it-network"),
|
|
52
|
+
"Bot management & rate limiting & WAF": ("S090A6M8740", "security-bot-management-rate-limiting-waf"),
|
|
53
|
+
"Customer login & signup": ("S08V22H38AE", "marketplace-customer-login-signup"),
|
|
54
|
+
"Delivery experience": ("S08V2NP1E5A", "operations-delivery-experience"),
|
|
55
|
+
"Accounting": ("S08VD37CJBT", "finance-accounting"),
|
|
56
|
+
"Traffic acquisition": ("S08UU3BNPPV", "marketing-communication-traffic-acquisition"),
|
|
57
|
+
"Payment": ("S08UM13DTFH", "payment-operations-payment"),
|
|
58
|
+
"Data leak": ("S08UYJHBJPP", "security-data-leak"),
|
|
59
|
+
"Offer (Price & Stock)": ("S08V2NCSPJ8", "catalog-offer-price-stock"),
|
|
60
|
+
"Product Structure": ("S08V2NCNFV2", "catalog-product-structure"),
|
|
61
|
+
"Catalog Access": ("S090A69J064", "catalog-catalog-access"),
|
|
62
|
+
"Order management": ("S08UU3TRGJF", "operations-order-management"),
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
def update_components_slack_groups(apps, _):
|
|
67
|
+
try:
|
|
68
|
+
Component = apps.get_model("incidents", "Component")
|
|
69
|
+
UserGroup = apps.get_model("slack", "UserGroup")
|
|
70
|
+
except LookupError:
|
|
71
|
+
logger.exception("The 'slack' app is not installed. Skipping migration.")
|
|
72
|
+
return
|
|
73
|
+
|
|
74
|
+
with transaction.atomic():
|
|
75
|
+
for component_name, (user_group_id, user_group_name) in COMPONENT_SLACK_GROUPS.items():
|
|
76
|
+
try:
|
|
77
|
+
# Vérifier/créer le SlackUserGroup
|
|
78
|
+
user_group, _ = UserGroup.objects.get_or_create(
|
|
79
|
+
name=user_group_name
|
|
80
|
+
)
|
|
81
|
+
# Si le slack_group_id a changé, le mettre à jour
|
|
82
|
+
if user_group.usergroup_id != user_group_id:
|
|
83
|
+
user_group.usergroup_id = user_group_id
|
|
84
|
+
user_group.handle = user_group_name
|
|
85
|
+
user_group.save()
|
|
86
|
+
|
|
87
|
+
# Vérifier/créer le Component
|
|
88
|
+
component = Component.objects.get(name=component_name)
|
|
89
|
+
if not component:
|
|
90
|
+
logger.error(f"Component '{component_name}' n'existe pas.")
|
|
91
|
+
continue
|
|
92
|
+
|
|
93
|
+
# Lier le Component au SlackUserGroup via la relation du UserGroup
|
|
94
|
+
if not hasattr(user_group, "components"):
|
|
95
|
+
logger.error(f"UserGroup '{user_group_name}' n'a pas d'attribut 'components'.")
|
|
96
|
+
continue
|
|
97
|
+
|
|
98
|
+
if not user_group.components.filter(id=component.id).exists():
|
|
99
|
+
user_group.components.add(component)
|
|
100
|
+
logger.info(f"Component '{component_name}' ajouté au SlackUserGroup '{user_group_name}'")
|
|
101
|
+
except Exception:
|
|
102
|
+
logger.exception(f"Failed to update component: '{component_name}'.")
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
def ensure_firefighters_user_group(apps, _):
|
|
106
|
+
try:
|
|
107
|
+
Component = apps.get_model("incidents", "Component")
|
|
108
|
+
UserGroup = apps.get_model("slack", "UserGroup")
|
|
109
|
+
except LookupError:
|
|
110
|
+
logger.exception("The 'slack' app is not installed. Skipping Firefighters user group check.")
|
|
111
|
+
return
|
|
112
|
+
|
|
113
|
+
try:
|
|
114
|
+
firefighters_group = UserGroup.objects.get(name="firefighters")
|
|
115
|
+
except UserGroup.DoesNotExist:
|
|
116
|
+
logger.exception("UserGroup 'firefighters' does not exist.")
|
|
117
|
+
return
|
|
118
|
+
|
|
119
|
+
for component in Component.objects.all():
|
|
120
|
+
if not hasattr(firefighters_group, "components"):
|
|
121
|
+
logger.error("UserGroup 'firefighters' n'a pas d'attribut 'components'.")
|
|
122
|
+
break
|
|
123
|
+
if not firefighters_group.components.filter(id=component.id).exists():
|
|
124
|
+
firefighters_group.components.add(component)
|
|
125
|
+
logger.info(f"Component '{component.name}' ajouté au SlackUserGroup 'firefighters'.")
|
|
126
|
+
|
|
127
|
+
|
|
128
|
+
def cleanup_unused_slack_user_groups(apps, _):
|
|
129
|
+
try:
|
|
130
|
+
UserGroup = apps.get_model("slack", "UserGroup")
|
|
131
|
+
except LookupError:
|
|
132
|
+
logger.exception("The 'slack' app is not installed. Skipping user groups cleanup.")
|
|
133
|
+
return
|
|
134
|
+
|
|
135
|
+
valid_usergroup_ids = {v[0] for v in COMPONENT_SLACK_GROUPS.values()}
|
|
136
|
+
|
|
137
|
+
for user_group in UserGroup.objects.all():
|
|
138
|
+
if (
|
|
139
|
+
user_group.usergroup_id not in valid_usergroup_ids
|
|
140
|
+
and "firefighter" not in user_group.name.lower()
|
|
141
|
+
and hasattr(user_group, "components")
|
|
142
|
+
):
|
|
143
|
+
components_to_remove = list(user_group.components.all())
|
|
144
|
+
if components_to_remove:
|
|
145
|
+
user_group.components.clear()
|
|
146
|
+
logger.info(
|
|
147
|
+
f"Removed components {[c.name for c in components_to_remove]} from SlackUserGroup '{user_group.name}'"
|
|
148
|
+
)
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
def delete_unused_slack_user_groups(apps, _):
|
|
152
|
+
try:
|
|
153
|
+
UserGroup = apps.get_model("slack", "UserGroup")
|
|
154
|
+
except LookupError:
|
|
155
|
+
logger.exception("The 'slack' app is not installed. Skipping user groups deletion.")
|
|
156
|
+
return
|
|
157
|
+
|
|
158
|
+
for user_group in UserGroup.objects.all():
|
|
159
|
+
if "firefighters" in user_group.name.lower():
|
|
160
|
+
continue
|
|
161
|
+
if hasattr(user_group, "components") and user_group.components.count() == 0:
|
|
162
|
+
logger.info(f"Deleting SlackUserGroup '{user_group.name}' (ID: {user_group.usergroup_id}) as it has no components.")
|
|
163
|
+
user_group.delete()
|
|
164
|
+
|
|
165
|
+
|
|
166
|
+
class Migration(migrations.Migration):
|
|
167
|
+
|
|
168
|
+
dependencies = [
|
|
169
|
+
("incidents", "0013_add_missing_component"),
|
|
170
|
+
]
|
|
171
|
+
|
|
172
|
+
operations = [
|
|
173
|
+
migrations.RunPython(update_components_slack_groups),
|
|
174
|
+
migrations.RunPython(ensure_firefighters_user_group),
|
|
175
|
+
migrations.RunPython(cleanup_unused_slack_user_groups),
|
|
176
|
+
migrations.RunPython(delete_unused_slack_user_groups),
|
|
177
|
+
]
|
|
@@ -667,7 +667,7 @@ class IncidentFilterSet(django_filters.FilterSet):
|
|
|
667
667
|
)
|
|
668
668
|
component = ModelMultipleChoiceFilter(
|
|
669
669
|
queryset=component_filter_choices_queryset,
|
|
670
|
-
label="
|
|
670
|
+
label="Issue category",
|
|
671
671
|
widget=GroupedCheckboxSelectMultiple,
|
|
672
672
|
)
|
|
673
673
|
created_at = FFDateRangeSingleFilter(field_name="created_at")
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
|
|
28
28
|
<div class="mt-8 max-w-3xl mx-auto grid grid-cols-1 gap-6 sm:px-6 lg:max-w-7xl lg:grid-flow-col-dense lg:grid-cols-12">
|
|
29
29
|
<div class="space-y-6 lg:col-start-1 lg:col-span-7">
|
|
30
|
-
{% component "card" card_title="
|
|
30
|
+
{% component "card" card_title="Issue category information" id="component-information" %}
|
|
31
31
|
{% fill "card_content" %}
|
|
32
32
|
<dl class="grid grid-cols-1 gap-x-4 gap-y-8 sm:grid-cols-2">
|
|
33
33
|
{% if component.description %}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# Generated by Django 4.2.21 on 2025-06-03 15:03
|
|
2
|
+
|
|
3
|
+
from django.db import migrations, models
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class Migration(migrations.Migration):
|
|
7
|
+
|
|
8
|
+
dependencies = [
|
|
9
|
+
("incidents", "0014_update_components_slack_groups"),
|
|
10
|
+
("slack", "0003_alter_usergroup_tag"),
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
operations = [
|
|
14
|
+
migrations.AlterField(
|
|
15
|
+
model_name="usergroup",
|
|
16
|
+
name="components",
|
|
17
|
+
field=models.ManyToManyField(
|
|
18
|
+
blank=True,
|
|
19
|
+
help_text="Incident created with this usergroup automatically add the group members to these issue categories.",
|
|
20
|
+
related_name="usergroups",
|
|
21
|
+
to="incidents.component",
|
|
22
|
+
),
|
|
23
|
+
),
|
|
24
|
+
]
|
|
@@ -171,7 +171,7 @@ class UserGroup(models.Model):
|
|
|
171
171
|
Component,
|
|
172
172
|
related_name="usergroups",
|
|
173
173
|
blank=True,
|
|
174
|
-
help_text="Incident created with this usergroup automatically add the group members to these
|
|
174
|
+
help_text="Incident created with this usergroup automatically add the group members to these issue categories.",
|
|
175
175
|
)
|
|
176
176
|
|
|
177
177
|
tag = models.CharField(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: firefighter-incident
|
|
3
|
-
Version: 0.0.
|
|
3
|
+
Version: 0.0.6
|
|
4
4
|
Summary: Incident Management tool made for Slack using Django
|
|
5
5
|
Project-URL: Repository, https://github.com/ManoManoTech/firefighter-incident
|
|
6
6
|
Project-URL: Documentation, https://manomanotech.github.io/firefighter-incident/latest/
|
|
@@ -6,7 +6,7 @@ gunicorn.conf.py,sha256=vHsTGjaKOr8FDMp6fTKYTX4AtokmPgYvvt5Mr0Q6APc,273
|
|
|
6
6
|
main.py,sha256=CsbprHoOYhjCLpTJmq9Z_aRYFoFgWxoz2pDLuwm8Eqg,1558
|
|
7
7
|
manage.py,sha256=5ivHGD13C6nJ8QvltKsJ9T9akA5he8da70HLWaEP3k8,689
|
|
8
8
|
firefighter/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
9
|
-
firefighter/_version.py,sha256=
|
|
9
|
+
firefighter/_version.py,sha256=juzdq-mLyQD1MXj2IU1nbwqAl0oOYH7zZ9BDjNsqyB0,511
|
|
10
10
|
firefighter/api/__init__.py,sha256=JQW0Bv6xwGqy7ioxx3h6UGMzkkJ4DntDpbvV1Ncgi8k,136
|
|
11
11
|
firefighter/api/admin.py,sha256=x9Ysy-GiYjb0rynmFdS9g56e6n24fkN0ouGy5QD9Yrc,4629
|
|
12
12
|
firefighter/api/apps.py,sha256=P5uU1_gMrDfzurdMbfqw1Bnb2uNKKcMq17WBPg2sLhc,204
|
|
@@ -137,13 +137,13 @@ firefighter/incidents/signals.py,sha256=hUlPVVKSi9zuL4gz_Sa-HrDleYCASeMqKqA-kkHC
|
|
|
137
137
|
firefighter/incidents/tables.py,sha256=SH-ScSw7SkwbdiAIApHn1eYfOuj7CRy__jY9gDadenk,3324
|
|
138
138
|
firefighter/incidents/urls.py,sha256=4QJAIjmyE90_j8HLNExa4UpjM2CgasBOlx_r07ucjiM,2059
|
|
139
139
|
firefighter/incidents/forms/__init__.py,sha256=OU0r5eZc2A0UJNsL83n8AI5EvwUvg4Yx0GyPBI7R73M,111
|
|
140
|
-
firefighter/incidents/forms/close_incident.py,sha256=
|
|
141
|
-
firefighter/incidents/forms/create_incident.py,sha256=
|
|
140
|
+
firefighter/incidents/forms/close_incident.py,sha256=syT5Lpr_WXNFT3KGCe1oy-FzOqMt98S7YEzovdnp7To,940
|
|
141
|
+
firefighter/incidents/forms/create_incident.py,sha256=Wpp0qqUJQs5-5BXrS-P5-dGvM5zgr9XqaEEl6tpNZi4,2739
|
|
142
142
|
firefighter/incidents/forms/edit.py,sha256=2rQkiKak-vac-K3cIsqlGv4R5nhI7JLxw3DhFMXbWms,956
|
|
143
143
|
firefighter/incidents/forms/select_impact.py,sha256=twgvfvyT6TL4yzv1dx7H6IWrncfGTeMf2Qg6x0hTWjw,4637
|
|
144
144
|
firefighter/incidents/forms/update_key_events.py,sha256=1Xmnxe5OgZqLFS2HmMzQm3VGFPQipsdrLgKSwdh-fKc,4441
|
|
145
145
|
firefighter/incidents/forms/update_roles.py,sha256=Q26UPfwAj-8N23RNZLQkvmHGnS1_j_X5KQWjJmPjMKY,3635
|
|
146
|
-
firefighter/incidents/forms/update_status.py,sha256=
|
|
146
|
+
firefighter/incidents/forms/update_status.py,sha256=QCRKfDhSYZhVsJ6oofQxOXGMWMDRQEDnH29y8YnFn_Y,1034
|
|
147
147
|
firefighter/incidents/forms/utils.py,sha256=g2azRXQE4GwBNvq47z_Q51yKcGYSBzFyITTDkLlC_Gk,3651
|
|
148
148
|
firefighter/incidents/migrations/0001_initial_oss.py,sha256=OCrPbxf90h3NW9xolGGcsAryHKptD1TtKj5FucjBjg8,60311
|
|
149
149
|
firefighter/incidents/migrations/0002_alter_severity_name_alter_user_password_featureteam.py,sha256=YfIJhw_-Yqm8qrkbp01461bkcUr7v5Zy90oHjkY3bSA,1113
|
|
@@ -154,13 +154,18 @@ firefighter/incidents/migrations/0006_update_group_names.py,sha256=RHWre_VrnBmlo
|
|
|
154
154
|
firefighter/incidents/migrations/0007_update_component_name.py,sha256=Al9k5Xx2_ea4u20MIp2blTErdv7jkGDYCLhGJ3P-gdw,6555
|
|
155
155
|
firefighter/incidents/migrations/0008_impact_level.py,sha256=ZPDTYbt3q0gSEjMC7Nhl7LND9g4J4Hu5n_BO44sKFuc,8852
|
|
156
156
|
firefighter/incidents/migrations/0009_update_sla.py,sha256=cLbDmOKrcQOa6lb1kMd-xPJC1w7iDJuEsDTKymEnUMw,849
|
|
157
|
+
firefighter/incidents/migrations/0010_update_components.py,sha256=IwAj3axIXM95DrQcAZ8NBe-3GgL4NPrZqyBMdVqA8Lo,4301
|
|
158
|
+
firefighter/incidents/migrations/0011_update_incidents.py,sha256=tV4MA5ZJcqiRPteOLxJNZuhj7q6ncWXjAklm_9IzLbo,3190
|
|
159
|
+
firefighter/incidents/migrations/0012_alter_impactlevel.py,sha256=fLMDjkYC8P2HffTRUJneMZlAiw1Z7trjXUZqSlEkAxM,1139
|
|
160
|
+
firefighter/incidents/migrations/0013_add_missing_component.py,sha256=qVLQEl-riFwYNCbhXM-9-GNCHE-bk9QhbVMKqqOL0Ag,1962
|
|
161
|
+
firefighter/incidents/migrations/0014_update_components_slack_groups.py,sha256=5tiQnrtOpYVUztFdvZ6xTUReuJfpDX0cOvqIvDZpBv0,8700
|
|
157
162
|
firefighter/incidents/migrations/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
158
163
|
firefighter/incidents/models/__init__.py,sha256=dCNP-zRYNNDOZB3JDDWp7vCl084Jh6RgDT_iP57RkOY,862
|
|
159
164
|
firefighter/incidents/models/component.py,sha256=7GyXKNFk1MZns6RUGLpkNw5u6He7H9N1LexzXbG4sBM,7445
|
|
160
165
|
firefighter/incidents/models/environment.py,sha256=51txwua3dCrWZ1iSG3ZA8rbDn9c00pyMAZujl9gwE5c,827
|
|
161
166
|
firefighter/incidents/models/group.py,sha256=MscG3IY5AdyJbmq8h4mMqEvLwmnJLor9rkd6CIycKho,685
|
|
162
167
|
firefighter/incidents/models/impact.py,sha256=KyIDFdAAdlNfX0aUF8mOY1ZjSqKNeefjPU-VLDGN5zs,4715
|
|
163
|
-
firefighter/incidents/models/incident.py,sha256=
|
|
168
|
+
firefighter/incidents/models/incident.py,sha256=aQUAboXmHH9DO1Nq6AbB4w17dPQqn5iMTwT2r4TeJrA,26129
|
|
164
169
|
firefighter/incidents/models/incident_cost.py,sha256=juwOfJKRaNQpOHkRUCHShDDba0FU98YjRPkU4I0ofAU,1346
|
|
165
170
|
firefighter/incidents/models/incident_cost_type.py,sha256=wm8diry_VySJzIjC9M3Yavv2tYbvJgpN9UDb2gFRuH4,845
|
|
166
171
|
firefighter/incidents/models/incident_membership.py,sha256=vvvBvYPxNlM98KdF81cMrDif8_Wl5TqqNkmf_z9lZO8,1745
|
|
@@ -219,7 +224,7 @@ firefighter/incidents/templates/layouts/partials/status_pill.html,sha256=D9V8bnO
|
|
|
219
224
|
firefighter/incidents/templates/layouts/partials/table.html,sha256=eZE4kh0nQwGik6qc7A0O_jHyZcg32uzHc1pkjJRt6hw,1567
|
|
220
225
|
firefighter/incidents/templates/layouts/partials/user_card.html,sha256=LgYHSpqC0BAhVENMSmLpow8jlPnh5uRvHzooJlJna6w,802
|
|
221
226
|
firefighter/incidents/templates/layouts/partials/user_tooltip.html,sha256=KkVPpoODXIzrm6iItTg5RQphBGruQw4dFdOgAuGRt1E,562
|
|
222
|
-
firefighter/incidents/templates/pages/component_detail.html,sha256=
|
|
227
|
+
firefighter/incidents/templates/pages/component_detail.html,sha256=WLO9zg8zDCUtINOHK9xP5dKd5WaB8UWT6JNjLjYSQKs,5277
|
|
223
228
|
firefighter/incidents/templates/pages/component_list.html,sha256=Dq7Fo-J-S7fM3v1ByiwAh8XH_f5LSpzXOKiujjRoVAY,1715
|
|
224
229
|
firefighter/incidents/templates/pages/dashboard.html,sha256=jGfTCTdyLt3fWtX66HVG1bNgpffV4J7jagVgksCGsSE,1743
|
|
225
230
|
firefighter/incidents/templates/pages/docs_metrics.html,sha256=q10CCPwjujuj9_h7Mj4-NgP6BMt4TJ6Z3D20W9qZbaQ,3744
|
|
@@ -240,7 +245,7 @@ firefighter/incidents/views/reports.py,sha256=4h9z1QIhnDkzEyqvi-GI_j9Oem2igvqTk0
|
|
|
240
245
|
firefighter/incidents/views/views.py,sha256=MPcrqtvA0_xoGX8Bw6v-uMBp6RiJY0-_HTQ-en-zJ8Q,10487
|
|
241
246
|
firefighter/incidents/views/components/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
242
247
|
firefighter/incidents/views/components/details.py,sha256=4pBCAS2gLYAm4CwTJ5mkw43dq8BkGknsAwrQgeMF21Q,942
|
|
243
|
-
firefighter/incidents/views/components/list.py,sha256=
|
|
248
|
+
firefighter/incidents/views/components/list.py,sha256=B4XRnNG2tcehKuTT4wznPcI93lkLxRyRNEXSOsFFiVo,2130
|
|
244
249
|
firefighter/incidents/views/docs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
245
250
|
firefighter/incidents/views/docs/metrics.py,sha256=n2-chgxTokOqCx-W5YZRHK3pYmzvz0b_RF6s1de2Fcw,1713
|
|
246
251
|
firefighter/incidents/views/docs/role_types.py,sha256=88dGBAL7NMC24lyqLDN0jGnh5-ILRI5afL2Wig7LrFs,1122
|
|
@@ -329,6 +334,7 @@ firefighter/slack/messages/slack_messages.py,sha256=8iYBfRDJw74wl_b5c5A-8_wJBNrT
|
|
|
329
334
|
firefighter/slack/migrations/0001_initial_oss.py,sha256=XmTPgq7zCME2xDwzRFoVi4OegSIG9eSKoyTNoW05Qtg,12933
|
|
330
335
|
firefighter/slack/migrations/0002_usergroup_tag.py,sha256=098tmGA81mT-R2uhb6uQfZ7gKiRG9bFhEwQ8rrp4SKM,583
|
|
331
336
|
firefighter/slack/migrations/0003_alter_usergroup_tag.py,sha256=ncH3KUWEPZHlbdcAtOJ0KGt5H6EX-cKspTGU3osrAhE,591
|
|
337
|
+
firefighter/slack/migrations/0004_alter_usergroup_components.py,sha256=uCp1bhjcHRHbxlc_oewY__r4FY7eRHcoLSltJWgJ5x0,703
|
|
332
338
|
firefighter/slack/migrations/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
333
339
|
firefighter/slack/models/__init__.py,sha256=MGc4yuDnVhmAiHy1-5rjaLIfVv9JOup5arRutcUs8Ak,332
|
|
334
340
|
firefighter/slack/models/conversation.py,sha256=euN3eS-9KUIxOErfxDhZ8nNdwkrp8JKefLJN6ypszXA,16190
|
|
@@ -336,7 +342,7 @@ firefighter/slack/models/incident_channel.py,sha256=MKzrGPDEz7CcumrnbWZBcKAHoScy
|
|
|
336
342
|
firefighter/slack/models/message.py,sha256=E1MQoZJz4MsgCeqgP94_jtSrz2RYuWdoys8tz4Tfboc,4727
|
|
337
343
|
firefighter/slack/models/sos.py,sha256=Sji-7DxgsrLs7vFRJKPw7nmYyo2tIjNwoTcmdCmzEvA,1418
|
|
338
344
|
firefighter/slack/models/user.py,sha256=744fulTB00UQzsZwxf8CiQNMfEKmYY6y37x6zm6g14I,17218
|
|
339
|
-
firefighter/slack/models/user_group.py,sha256=
|
|
345
|
+
firefighter/slack/models/user_group.py,sha256=NyqtC0C_Vur2xZ6t7T7d7Z30WZ8EEovczJ0uYZVDC7o,7104
|
|
340
346
|
firefighter/slack/signals/__init__.py,sha256=dqMf2x-PVKgmwzH2d9uHuQ8hZ4fbu74eRd4Ij2_dNSg,186
|
|
341
347
|
firefighter/slack/signals/create_incident_conversation.py,sha256=uybiqCgPlWYq2AA2FKNkEmqhDYxDy-h0ebT-RBVpx9I,4965
|
|
342
348
|
firefighter/slack/signals/get_users.py,sha256=_xPsZFgcxd87Vuhv6FttttrxnIb0z65-It8H3FZlHOM,2271
|
|
@@ -383,7 +389,7 @@ firefighter/slack/views/modals/status.py,sha256=C8-eJRtquSeaHe568SC7yCFef1k14m2_
|
|
|
383
389
|
firefighter/slack/views/modals/trigger_oncall.py,sha256=h_LAD5X5rjMFWiDYTEp5VB9OaF7sTvKZhNaW3KQkw5M,5065
|
|
384
390
|
firefighter/slack/views/modals/update.py,sha256=OF9sf-Z6IiviNmjN28MQNYiUbJ5tha0MdHUQyPpVFiY,2150
|
|
385
391
|
firefighter/slack/views/modals/update_roles.py,sha256=De3Gv67MZQHyNdonX3S99F5MtKF_Rj3y71gdWibxBaM,2419
|
|
386
|
-
firefighter/slack/views/modals/update_status.py,sha256=
|
|
392
|
+
firefighter/slack/views/modals/update_status.py,sha256=ao9ZPCw9tgxdbyLGXsXRLL-LRB1_bxaoaa1ORoh0-nA,4472
|
|
387
393
|
firefighter/slack/views/modals/base_modal/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
388
394
|
firefighter/slack/views/modals/base_modal/base.py,sha256=7mvOxZTtegSmitSMnDvu8BK0qLUXoudUsda6CaLjdkY,12479
|
|
389
395
|
firefighter/slack/views/modals/base_modal/base_mixins.py,sha256=Xl1koQsPpHO_kKIiuSSJHJnIBmytDXseI1KcAZQZC3M,230
|
|
@@ -396,7 +402,7 @@ firefighter/slack/views/modals/opening/select_impact.py,sha256=P38gsWJ2UmHG9quns
|
|
|
396
402
|
firefighter/slack/views/modals/opening/set_details.py,sha256=i6zQM2FYz3Z6s5AZH7lXgB2e8yjS0rDwgfMBZaiOqIw,5791
|
|
397
403
|
firefighter/slack/views/modals/opening/types.py,sha256=ETpp0DAz5OMI5h7iv62Of7yJCbI-Q4-3kKSS6msPQeY,563
|
|
398
404
|
firefighter/slack/views/modals/opening/details/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
399
|
-
firefighter/slack/views/modals/opening/details/critical.py,sha256
|
|
405
|
+
firefighter/slack/views/modals/opening/details/critical.py,sha256=-APRvkjopLwLPv3qPGTZfgS0d1bpb8NM0OXppRdUK94,2854
|
|
400
406
|
firefighter_fixtures/incidents/components.json,sha256=qVVG201I4V-9f4Z3ZB0n9C4yZOJ8Qkz9v9MNAlqT8L8,21229
|
|
401
407
|
firefighter_fixtures/incidents/environments.json,sha256=5H_F08x7moMKz-H6OIUVaJGtmyKEESXLlG5cfXX0IA4,1039
|
|
402
408
|
firefighter_fixtures/incidents/groups.json,sha256=mwrpUk9tvZa0RnT1T0aec_nnMsVZhR2GXS7pmrAK0y8,2555
|
|
@@ -418,7 +424,7 @@ firefighter_tests/test_firefighter/test_logging.py,sha256=4HUH73vLDwmOCpMiXwDasM
|
|
|
418
424
|
firefighter_tests/test_firefighter/test_urls.py,sha256=UMGx4oW98RoL0ceePkIIKEVjbHdFECvQuGNXYAJForQ,4839
|
|
419
425
|
firefighter_tests/test_incidents/test_incident_urls.py,sha256=vQy9f1ewJK3N9cjVQDBnLaZjhtiBv5TzoRiGUdV3u5E,3769
|
|
420
426
|
firefighter_tests/test_incidents/test_forms/test_form_select_impact.py,sha256=hcDqy3zXJ-klC0tYGWogxrDLDsaD5i4xNSejY0wBbHE,3210
|
|
421
|
-
firefighter_tests/test_incidents/test_forms/test_form_utils.py,sha256=
|
|
427
|
+
firefighter_tests/test_incidents/test_forms/test_form_utils.py,sha256=24ATxxAjkLlz7cj_jIQZvuQvtrfieeh4oaIM90yQrlc,2299
|
|
422
428
|
firefighter_tests/test_incidents/test_forms/test_update_key_events.py,sha256=rHRGRU9iFXDdMr_kK3pMB7gyeZuMf7Dyq8bRZkddBC4,1644
|
|
423
429
|
firefighter_tests/test_incidents/test_models/test_incident_model.py,sha256=Kl2dQ0P3qruAaQP5M8WRYJiff-4SpmxpFYHYmA9Xv3k,879
|
|
424
430
|
firefighter_tests/test_incidents/test_models/test_migrations/test_incident_migrations.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -433,13 +439,13 @@ firefighter_tests/test_slack/test_slack_utils.py,sha256=9PLobMNXh3xDyFuwzcQFpKJh
|
|
|
433
439
|
firefighter_tests/test_slack/test_models/test_conversations.py,sha256=t3ttmgwiu7c-N55iU3XZPmrkEhvkTzJoXszJncy4Bts,793
|
|
434
440
|
firefighter_tests/test_slack/test_models/test_incident_channel.py,sha256=qWoGe9iadmK6-R8usWvjH87AHRkvhG_dHQeC3kHeJrs,17487
|
|
435
441
|
firefighter_tests/test_slack/test_models/test_slack_user.py,sha256=uzur-Rf03I5dpUTO4ZI6O1arBUrAorg1Zvgshf8M-J4,7000
|
|
436
|
-
firefighter_tests/test_slack/views/modals/test_close.py,sha256=
|
|
442
|
+
firefighter_tests/test_slack/views/modals/test_close.py,sha256=kcwGwonjIiniGb5f78ZwlKjuvYB-xat-SrbouV9VCEc,42894
|
|
437
443
|
firefighter_tests/test_slack/views/modals/test_open.py,sha256=Iatphd7vnrEMrv8ysKxDVDAuZNEsVXBksIEpIaDHQss,4100
|
|
438
444
|
firefighter_tests/test_slack/views/modals/test_send_sos.py,sha256=_rE6jD-gOzcGyhlY0R9GzlGtPx65oOOguJYdENgxtLc,1289
|
|
439
445
|
firefighter_tests/test_slack/views/modals/test_status.py,sha256=oQzPfwdg2tkbo9nfkO1GfS3WydxqSC6vy1AZjZDKT30,2226
|
|
440
|
-
firefighter_tests/test_slack/views/modals/test_update_status.py,sha256=
|
|
441
|
-
firefighter_incident-0.0.
|
|
442
|
-
firefighter_incident-0.0.
|
|
443
|
-
firefighter_incident-0.0.
|
|
444
|
-
firefighter_incident-0.0.
|
|
445
|
-
firefighter_incident-0.0.
|
|
446
|
+
firefighter_tests/test_slack/views/modals/test_update_status.py,sha256=Y8Oa_fraj1vtaGig9Y28_6tOWvMrRPS-wyg3rY-DHBk,39380
|
|
447
|
+
firefighter_incident-0.0.6.dist-info/METADATA,sha256=nOfSjYKS60cgXoS8biKqN88DbhCpdAXuBfknqzCTEOA,5487
|
|
448
|
+
firefighter_incident-0.0.6.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
449
|
+
firefighter_incident-0.0.6.dist-info/entry_points.txt,sha256=c13meJbv7YNmYz7MipMOQwzQ5IeFOPXUBYAJ44XMQsM,61
|
|
450
|
+
firefighter_incident-0.0.6.dist-info/licenses/LICENSE,sha256=krRiGp-a9-1nH1bWpBEdxyTKLhjLmn6DMVVoIb0zF90,1087
|
|
451
|
+
firefighter_incident-0.0.6.dist-info/RECORD,,
|
|
@@ -28,8 +28,8 @@ def group() -> Group:
|
|
|
28
28
|
@pytest.fixture
|
|
29
29
|
def components(group: Group):
|
|
30
30
|
return [
|
|
31
|
-
Component.objects.create(name="
|
|
32
|
-
Component.objects.create(name="
|
|
31
|
+
Component.objects.create(name="Issue category 1", group=group, order=1),
|
|
32
|
+
Component.objects.create(name="Issue category 2", group=group, order=2),
|
|
33
33
|
]
|
|
34
34
|
|
|
35
35
|
|
|
@@ -221,7 +221,7 @@ valid_submission = {
|
|
|
221
221
|
{
|
|
222
222
|
"type": "input",
|
|
223
223
|
"block_id": "component",
|
|
224
|
-
"label": {"type": "plain_text", "text": "
|
|
224
|
+
"label": {"type": "plain_text", "text": "Issue category", "emoji": True},
|
|
225
225
|
"optional": False,
|
|
226
226
|
"dispatch_action": False,
|
|
227
227
|
"element": {
|
|
@@ -229,7 +229,7 @@ valid_submission = {
|
|
|
229
229
|
"action_id": "component",
|
|
230
230
|
"placeholder": {
|
|
231
231
|
"type": "plain_text",
|
|
232
|
-
"text": "Select affected
|
|
232
|
+
"text": "Select affected issue category",
|
|
233
233
|
"emoji": True,
|
|
234
234
|
},
|
|
235
235
|
"option_groups": [
|
|
@@ -251,7 +251,7 @@ valid_submission = {
|
|
|
251
251
|
{
|
|
252
252
|
"type": "input",
|
|
253
253
|
"block_id": "component",
|
|
254
|
-
"label": {"type": "plain_text", "text": "
|
|
254
|
+
"label": {"type": "plain_text", "text": "Issue category", "emoji": True},
|
|
255
255
|
"optional": False,
|
|
256
256
|
"dispatch_action": False,
|
|
257
257
|
"element": {
|
|
@@ -259,7 +259,7 @@ valid_submission = {
|
|
|
259
259
|
"action_id": "component",
|
|
260
260
|
"placeholder": {
|
|
261
261
|
"type": "plain_text",
|
|
262
|
-
"text": "Select affected
|
|
262
|
+
"text": "Select affected issue category",
|
|
263
263
|
"emoji": True,
|
|
264
264
|
},
|
|
265
265
|
"initial_option": {
|
|
File without changes
|
{firefighter_incident-0.0.4.dist-info → firefighter_incident-0.0.6.dist-info}/entry_points.txt
RENAMED
|
File without changes
|
{firefighter_incident-0.0.4.dist-info → firefighter_incident-0.0.6.dist-info}/licenses/LICENSE
RENAMED
|
File without changes
|