Commit graph

730 commits

Author SHA1 Message Date
Joey Orlando
44ec718d7c
Add ability to create an Outgoing Webhook with the PATCH HTTP method via the UI (#3604)
# What this PR does

Closes https://github.com/grafana/oncall/issues/3564

## TODO
- [ ] add e2e tests for creating Outgoing Webhooks

## Checklist

- [ ] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2024-01-02 13:04:06 -05:00
Matias Bordese
1fccef65fd
Handle telegram message to reply to not found on send log task (#3587)
Similar to https://github.com/grafana/oncall/pull/404
2024-01-02 16:42:19 +00:00
Joey Orlando
33fcb87c51
Update CHANGELOG.md 2023-12-28 09:36:26 -05:00
Joey Orlando
955261ffc0
Update CHANGELOG.md 2023-12-28 09:35:37 -05:00
Joey Orlando
9657533b5b
fix duplicate teams showing up in teams dropdown for /escalate slack command (#3590)
# Which issue(s) this PR fixes
- Closes https://github.com/grafana/support-escalations/issues/8763
- Closes https://github.com/grafana/oncall/issues/3388

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [ ] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-22 12:36:54 +00:00
Ravishankar
bcbca9d3b9
fix(3564) Support PATCH Method In Outgoing webhook (#3580)
# What this PR does
Adds PATCH method Support for outgoing webhook

## Which issue(s) this PR fixes
Fixes #3564 

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)

---------

Co-authored-by: Joey Orlando <joey.orlando@grafana.com>
2023-12-20 08:49:50 -05:00
Yulya Artyukhina
647d46294c
Fix inbound email integration endpoint (#3586)
# What this PR does
Handle exception on parsing sender email address from email message for
inbound email integration endpoint

## Which issue(s) this PR fixes
https://github.com/grafana/oncall-private/issues/2398
## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-20 08:40:47 -05:00
Joey Orlando
006682d0b7
fix PUT /api/v1/escalation_policies/<id> issue related to updating from_time and to_time (#3581)
# Which issue(s) this PR fixes

Closes https://github.com/grafana/oncall-private/issues/2373

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [ ] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-19 09:13:07 -05:00
Yulya Artyukhina
0421bc472a
Fix posting slack message about ratelimits (#3582)
# What this PR does

## Which issue(s) this PR fixes
https://github.com/grafana/oncall-private/issues/2374
## Checklist

- [ ] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-19 06:05:57 +00:00
Yulya Artyukhina
8ade7d65e8
Fix alert group columns validation (#3577)
# What this PR does
Fix alert group columns validation: - validate column ids by each type
separately
## Which issue(s) this PR fixes
validation check from this issue -
https://github.com/grafana/oncall-private/issues/2378
## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-15 17:15:50 +00:00
Michael Derynck
e7f3eff72c
Limit how long acknowledge reminders can run for (#3571)
# What this PR does
Stops rescheduling of `acknowledge_reminder_task` after 2 weeks.
Assumption being if it has been sitting for that long in acknowledged
state it is likely to not need more reminders that it is still
acknowledged. Notifications for thread were probably muted a long time
ago.

## Which issue(s) this PR fixes

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-15 16:50:01 +00:00
Yulya Artyukhina
2b62da77b7
Check if escalation was skipped in Slack before trying to notify user (#3562)
# What this PR does
Updates check if escalation was skipped in Slack before trying to notify
user by Slack.

## Which issue(s) this PR fixes

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-15 09:33:01 +00:00
Dominik Broj
92fa509d22
Brojd/improve e2e tests dx (#3516)
# What this PR does
- introduce e2e tests in Tilt
- support e2e tests commands in Makefile
- stabilize local setup

## Which issue(s) this PR fixes
https://github.com/grafana/oncall/issues/3492

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-15 08:58:25 +00:00
Michael Derynck
e442508bd1
Update CHANGELOG.md 2023-12-14 15:14:51 -07:00
Matias Bordese
e260e23715
Add missing success log entries for personal notifications (#3557) 2023-12-14 18:32:26 +00:00
Yulya Artyukhina
6c1ac8aa73
Update CHANGELOG.md 2023-12-14 13:19:55 +01:00
Yulya Artyukhina
088414c4d3
Add multi-stack support for mobile app (#3500)
# What this PR does
Allow creating multiple mobile devices with same `registration_id` for
different users (multi-stack support)

## Which issue(s) this PR fixes
https://github.com/grafana/oncall/issues/3452

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-13 09:00:18 +00:00
Michael Derynck
d6873b0d73
Update CHANGELOG.md 2023-12-12 13:46:32 -07:00
Yulya Artyukhina
e003e8a0b8
Fix message is too big exception for mobile push notification (#3556)
# What this PR does
Adds limit for alert title length in mobile app push notifications
## Which issue(s) this PR fixes
https://github.com/grafana/oncall-private/issues/2375
## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-12 16:46:08 +00:00
Yulya Artyukhina
0861113ed5
Add error code for mobile notification logs (#3554)
# What this PR does
Adds error code for mobile notification logs
## Which issue(s) this PR fixes

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-12 12:02:26 +00:00
Joey Orlando
f4d3a7c7e8
Update CHANGELOG.md 2023-12-11 14:24:44 -05:00
Stanislav Lutsenko
0d959a5c20
Fix amazon_ses inbound email ESP provider (#3509)
# What this PR does
Fixes django-anymail[amazon-ses] issues according to [anymail
docs](https://anymail.dev/en/stable/esps/amazon_ses/)

## Which issue(s) this PR fixes
[#3508](https://github.com/grafana/oncall/issues/3508)

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [ ] Documentation added (or `pr:no public docs` PR label added if not
required)
- [ ] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)

---------

Co-authored-by: Joey Orlando <joey.orlando@grafana.com>
Co-authored-by: Joey Orlando <joseph.t.orlando@gmail.com>
2023-12-11 12:33:54 -05:00
Joey Orlando
16ba87bff6
Don't update alert group metrics when deleting an alert group (#3544)
# Which issue(s) this PR fixes

Fixes https://github.com/grafana/oncall-private/issues/2376

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [ ] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-11 12:16:00 -05:00
Maxim Mordasov
fcad289089
Fix schedules invalid dates issue (#3541)
# What this PR does

Fix schedules invalid dates issue

## Which issue(s) this PR fixes

https://github.com/grafana/support-escalations/issues/8084

## Checklist

- [ ] Unit, integration, and e2e (if applicable) tests updated
- [ ] Documentation added (or `pr:no public docs` PR label added if not
required)
- [ ] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-11 14:17:41 +00:00
Innokentii Konstantinov
3de2b1d4ad Update CHANGELOG 2023-12-11 18:25:39 +08:00
Joey Orlando
783e0f7ad0
Update CHANGELOG.md 2023-12-08 11:14:51 -05:00
Yulya Artyukhina
7e54a43f50
Fix team changing on PUT request if team is not in request data (#3530)
# What this PR does
Removes setting team to default value on PUT request to internal
endpoints if team is not in request data.
(For integrations, escalation chains, schedules and webhooks)

## Which issue(s) this PR fixes
https://github.com/grafana/oncall-private/issues/2368

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-07 14:44:52 +00:00
Matias Bordese
e54817246b
Update CHANGELOG.md 2023-12-06 13:11:16 -03:00
Matias Bordese
054401a214
Fix missing timestamp value, add test (#3522) 2023-12-06 16:02:54 +00:00
Vadim Stepanov
a46610b096
Update CHANGELOG.md 2023-12-06 13:33:58 +00:00
Matias Bordese
e053eb084d
Track alert received timestamp on alert group creation (#3513)
Keep record of the timestamp when the alert group creation task is
triggered, allowing to track the delta time between alert received
datetime and alert group creation timestamp.

Related to https://github.com/grafana/oncall-private/issues/2347
2023-12-06 12:20:03 +00:00
Joey Orlando
382b18b052
Mobile app proxy gateway (#3449)
# What this PR does

Closes https://github.com/grafana/oncall-private/issues/2324

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-05 19:58:05 +00:00
Joey Orlando
a1edc20cbe
Update CHANGELOG.md 2023-12-05 12:14:19 -05:00
Dominik Broj
93fee4228d
Rename integrations table tabs (#3501)
# What this PR does
Rename "Connections" tab to "Monitoring Systems" and "Direct Paging" to
"Manual Direct Paging" on Integrations page

## Which issue(s) this PR fixes
https://github.com/grafana/oncall-private/issues/2302

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-05 12:43:48 +00:00
Joey Orlando
61f0c177e8
Update CHANGELOG.md 2023-12-05 07:50:51 -05:00
jorgeav
4df8985283
Jinja2 template helper filter datetimeformat_as_timezone (#3426)
# What this PR does
Add an additional jinja2 template helper filter to convert a timezone
aware datetime to a different timezone.

## Which issue(s) this PR fixes
Alert payloads that originate from different time zones may include
timestamps having a local time offset. This filter enables
standardization of timestamp timezones.

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)

---------

Co-authored-by: Joey Orlando <joey.orlando@grafana.com>
2023-12-04 13:39:04 -05:00
Vadim Stepanov
4ccfda58e5
Disallow creating and deleting direct paging integrations (#3475)
# What this PR does

Disallows creating and deleting direct paging integrations via both
internal and public APIs. It also hides the direct paging option in the
UI when creating a new integration.

## Which issue(s) this PR fixes

Related to https://github.com/grafana/oncall-private/issues/2302

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)

---------

Co-authored-by: Dominik <dominik.broj@grafana.com>
2023-12-04 13:13:53 +00:00
Joey Orlando
adc4f5905e
Update CHANGELOG.md 2023-12-01 12:00:20 -05:00
Joey Orlando
34bab57dcd
Update CHANGELOG.md 2023-12-01 10:05:24 -05:00
Joey Orlando
76a88bc0c1
Revert "upgrade to Python 3.12 (#3456)" and "bump uwsgi version to latest #3466" (#3483)
# What this PR does

This reverts commits 7c4b40a046 and
cdb22285db.

See https://github.com/grafana/oncall-private/pull/2361 for more
details.
2023-12-01 09:56:26 -05:00
Ildar Iskhakov
30caa18f9d
Make telegram on_alert_group_action_triggered asynchronous (#3471)
# What this PR does


[send_alert_group_signal](https://github.com/grafana/oncall/blob/dev/engine/apps/alerts/tasks/send_alert_group_signal.py#L12)
task is not idempotent. It launches
[on_alert_group_action_triggered_async](a2851d3f81/engine/apps/slack/representatives/alert_group_representative.py (L158))
for slack and then might fail on
[on_alert_group_action_triggered](b2f4ffb98a/engine/apps/telegram/alert_group_representative.py (L79))
(not async) due to database DoesNotExist exception.

This PR makes telegram representative asyncronous

## Which issue(s) this PR fixes

## Checklist

- [ ] Unit, integration, and e2e (if applicable) tests updated
- [ ] Documentation added (or `pr:no public docs` PR label added if not
required)
- [ ] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-12-01 10:49:00 +00:00
Vadim Stepanov
4a6314ae68
Update CHANGELOG.md 2023-11-30 17:31:37 +00:00
Vadim Stepanov
8188dd5dd2
Create missing direct paging integrations (#3468)
# What this PR does

Makes organization sync create direct paging integrations for Grafana
teams that don't have one.

## Which issue(s) this PR fixes

Related to https://github.com/grafana/oncall-private/issues/2302

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-11-30 17:18:18 +00:00
Joey Orlando
7c4b40a046
upgrade to Python 3.12 (#3456)
# What this PR does

Upgrade to Python 3.12 + fix several invalid test assertions that lead
to test failures in the latest version of `pytest`:
```
AttributeError: 'called_once_with' is not a valid assertion. Use a spec for the mock if 'called_once_with' is meant to be an attribute.. Did you mean: 'assert_called_once_with'?
```

## Checklist

- [ ] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-11-30 13:47:41 +00:00
Joey Orlando
6ef0a3a683
Update CHANGELOG.md 2023-11-30 08:06:31 -05:00
Vadim Stepanov
35e683c2b6
Update CHANGELOG.md 2023-11-30 11:52:27 +00:00
Vadim Stepanov
381a9ecf54
Delete duplicate direct paging integrations (#3412)
# What this PR does

Deletes duplicate direct paging integrations (i.e. keeps only the first
direct paging integration per team).
Also adds a unique constraint that will make such duplicates impossible
at the DB level.

## Which issue(s) this PR fixes

Related to https://github.com/grafana/oncall-private/issues/2302

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-11-30 11:19:12 +00:00
Matias Bordese
1875fdcc47
Update CHANGELOG.md 2023-11-29 18:04:18 -03:00
Michael Derynck
f1518cb857
Ensure stack_id and org_id are ints (#3458)
# What this PR does
When reading plugin provisioning data if the value was > 999999 it was
converted to exponential notation by the template which the backend
could not understand as an ID. This makes sure it is written as an int.

## Which issue(s) this PR fixes

## Checklist

- [x] Unit, integration, and e2e (if applicable) tests updated
- [x] Documentation added (or `pr:no public docs` PR label added if not
required)
- [x] `CHANGELOG.md` updated (or `pr:no changelog` PR label added if not
required)
2023-11-29 13:45:49 -07:00
Rares Mardare
455f74560c
Alert group column/label selector (#3281)
# What this PR does

Adds new functionality to enable which columns should show on the alert
group page


![image](https://github.com/grafana/oncall/assets/40542072/952d4004-9cd6-478c-a104-cd5d270cfd58)

---------

Co-authored-by: Julia <ferril.darkdiver@gmail.com>
2023-11-29 12:11:31 +00:00