1817 Коммитов

Автор SHA1 Сообщение Дата
Agniva De Sarker
a6d37fa14c MM-61887: Log the userID if a metric exceeds the last histogram bucket (#29448)
We create a custom histogram metric that logs the userID
when the observed value is greater or equal to the last bucket value.

This allows us to start tracking the slowest users of a system
while at the same time not polluting the Prometheus metrics
by storing a userID for every observation.

https://mattermost.atlassian.net/browse/MM-61887

```release-note
NONE
```
2024-12-05 09:12:54 +05:30
unified-ci-app[bot]
421001c981 Update latest minor version to 10.4.0 (#29474)
Automatic Merge
2024-12-04 19:47:36 +01:00
Nick Misasi
027ac51b81 Remove write_restrictable from AdvancedLoggingJSON (#29424) 2024-12-04 13:29:03 -05:00
Agniva De Sarker
833578741d Improve Redis failure modes (#29405)
While investigating code paths during
Redis downtime, I found out that the library
by default retries indefinitely for read commmands.

This leads to it being stuck in a loop
while trying to read anything from Redis.
We fix that by disabling retry.

Secondly, we adjust the ConnWriteTimeout
value slightly from its default of 10s
which is a bit too high for normal working
conditions.

Ref: https://github.com/redis/rueidis/issues/680
```release-note
NONE
```
2024-12-03 09:34:47 +05:30
Weblate (bot)
3c6d5f2d47 Translations update from Mattermost Weblate (#29444)
Automatic Merge
2024-12-02 16:17:37 +01:00
k srisri reddy
961fc6bfe9 fix: MM-61260: handled errors to fix linting (#29340)
Co-authored-by: Ibrahim Serdar Acikgoz <serdaracikgoz86@gmail.com>
2024-11-29 15:27:15 +00:00
Ivy Gesare
ff1ffc51dc [MM-61460] Fix errcheck issues in server/channels/app/plugin_signature_test.go (#29348)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-29 10:36:19 +01:00
Agniva De Sarker
4ec4b4d525 MM-61886: Add actionable page navigation metrics (#29332)
Page load is one of the metrics that we track and present
to MLT. However, in its current form, it is not very
actionable because it also contains the network latency.

We split the whole metric into these parts:
startTime
|
responseStart = TTFB
|
responseEnd = TTLB
|
domInteractive = Start of processing phase
|
loadEventEnd = Load complete

This gives us better visibility into exactly
which phase in the load process is slow.

I have experimented with other metrics like
- domContentLoadedEventStart
- domContentLoadedEventEnd
- domComplete

and observed that they do not have sufficient
gaps in the timespan to have any relevance.

Additionally, I have moved TTFB from being a
web vitals metric to being tracked from the performance
metrics to remain consistent with the other navigation
metrics measured.

Lastly, I took this chance to improve some of the
validation errors that we threw to include more
context into the input that was passed and why
does it fail.

This also meant that I had to change the tests
to check for error strings rather than direct
errors which is a bad thing, but I don't think
it's worth the effort trying to have named error
variables for all of them.

https://mattermost.atlassian.net/browse/MM-61886

```release-note
NONE
```
2024-11-29 11:24:35 +05:30
AulakhHarsh
2c32040e2e [MM-61769] Fix errcheck for /platform/searchengine.go (#29341)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-28 10:17:33 +01:00
Arya Khochare
54eff271bd Fixed errcheck issues in server/channels/app/integration_action_test.go (#29039)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-27 14:02:12 +01:00
AulakhHarsh
d9981beb9d Fix errcheck issues in server/channels/jobs/resend_invitation_email/worker.go (#29353)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-27 12:07:31 +01:00
Pablo Vélez
48c14af280 MM-61297 - remove unused code (#29354)
* MM-61297 - remove unused code

* remove unused code for install plugin in backend

* fix translations
2024-11-26 19:11:21 -05:00
AulakhHarsh
edbcb247c6 Fix errcheck issues in server/channels/app/platform/log.go (#29349)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-26 16:22:31 +01:00
Weblate (bot)
24a1b5e0f3 Translations update from Mattermost Weblate (#29382)
* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 57.1% (3432 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Polish)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/pl/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Polish)

Currently translated at 100.0% (6008 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/pl/

* Translated using Weblate (Ukrainian)

Currently translated at 59.3% (3566 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 59.9% (3603 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Czech)

Currently translated at 94.0% (5652 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/cs/

* Translated using Weblate (Polish)

Currently translated at 100.0% (6008 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/pl/

* Translated using Weblate (Ukrainian)

Currently translated at 60.0% (3607 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Czech)

Currently translated at 95.7% (5755 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/cs/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 60.2% (3617 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Czech)

Currently translated at 96.4% (5796 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/cs/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 60.2% (3617 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (German)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/de/

* Translated using Weblate (German)

Currently translated at 100.0% (6008 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/de/

* Translated using Weblate (Czech)

Currently translated at 97.4% (5857 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/cs/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Dutch)

Currently translated at 99.9% (6007 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/nl/

* Translated using Weblate (Ukrainian)

Currently translated at 60.4% (3632 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Dutch)

Currently translated at 99.1% (2574 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/nl/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 60.7% (3651 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Dutch)

Currently translated at 99.5% (2585 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/nl/

* Translated using Weblate (Portuguese (Brazil))

Currently translated at 82.0% (2131 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/pt_BR/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 61.4% (3694 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Portuguese (Brazil))

Currently translated at 85.3% (2216 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/pt_BR/

* Translated using Weblate (Ukrainian)

Currently translated at 61.6% (3703 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 61.6% (3706 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 61.7% (3708 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 61.7% (3709 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 61.7% (3711 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 63.9% (3845 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Kazakh)

Currently translated at 6.9% (415 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/kk/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Turkish)

Currently translated at 98.8% (2567 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/tr/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Turkish)

Currently translated at 98.8% (5938 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/tr/

* Translated using Weblate (Ukrainian)

Currently translated at 65.9% (3964 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Kazakh)

Currently translated at 6.9% (419 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/kk/

* Translated using Weblate (English (Australia))

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/en_AU/

* Translated using Weblate (Turkish)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/tr/

* Translated using Weblate (English (Australia))

Currently translated at 100.0% (6008 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/en_AU/

* Translated using Weblate (Turkish)

Currently translated at 100.0% (6008 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/tr/

* Translated using Weblate (Japanese)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/ja/

* Translated using Weblate (Dutch)

Currently translated at 99.5% (2586 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/nl/

* Translated using Weblate (Japanese)

Currently translated at 100.0% (6008 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/ja/

* Translated using Weblate (Kazakh)

Currently translated at 7.0% (421 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/kk/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 67.3% (4047 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Dutch)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/nl/

* Translated using Weblate (Chinese (Simplified Han script))

Currently translated at 99.4% (2583 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/zh_Hans/

* Translated using Weblate (Chinese (Simplified Han script))

Currently translated at 100.0% (6008 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/zh_Hans/

* Translated using Weblate (Kazakh)

Currently translated at 7.5% (456 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/kk/

* Translated using Weblate (Chinese (Simplified Han script))

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/zh_Hans/

* Translated using Weblate (Ukrainian)

Currently translated at 70.1% (4216 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Chinese (Simplified Han script))

Currently translated at 100.0% (6008 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/zh_Hans/

* Translated using Weblate (Chinese (Traditional Han script))

Currently translated at 98.5% (2560 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/zh_Hant/

* Translated using Weblate (Polish)

Currently translated at 100.0% (6008 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/pl/

* Translated using Weblate (Swedish)

Currently translated at 98.7% (5933 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/sv/

* Translated using Weblate (Ukrainian)

Currently translated at 70.7% (4250 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Swedish)

Currently translated at 98.3% (2553 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/sv/

* Translated using Weblate (Ukrainian)

Currently translated at 100.0% (2597 of 2597 strings)

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/uk/

* Translated using Weblate (Swedish)

Currently translated at 98.7% (5934 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/sv/

* Translated using Weblate (Ukrainian)

Currently translated at 70.9% (4261 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 70.9% (4261 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Update translation files

Updated by "Cleanup translation files" hook in Weblate.

Translation: Mattermost/server
Translate-URL: https://translate.mattermost.com/projects/mattermost/server/

* Update translation files

Updated by "Cleanup translation files" hook in Weblate.

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/

* Translated using Weblate (Ukrainian)

Currently translated at 70.9% (4261 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 70.9% (4261 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

* Translated using Weblate (Ukrainian)

Currently translated at 70.9% (4261 of 6008 strings)

Translation: Mattermost/webapp
Translate-URL: https://translate.mattermost.com/projects/mattermost/webapp/uk/

---------

Co-authored-by: Serhii Khomiuk <sergiy.khomiuk@gmail.com>
Co-authored-by: master7 <marcin.karkosz@rajska.info>
Co-authored-by: Martin Mičuda <micuda@rematiptop.cz>
Co-authored-by: jprusch <rs@schaeferbarthold.de>
Co-authored-by: Tom De Moor <tom@controlaltdieliet.be>
Co-authored-by: Henrique Latorre <hpflatorre@gmail.com>
Co-authored-by: Akbar Abdrakhmanov <kz.akbar@gmail.com>
Co-authored-by: Kaya Zeren <kayazeren@gmail.com>
Co-authored-by: Matthew Williams <Matthew.Williams@outlook.com.au>
Co-authored-by: kaakaa <stooner.hoe@gmail.com>
Co-authored-by: ThrRip <coding@thrrip.space>
Co-authored-by: Yanyiyi <oabb1388@gmail.com>
Co-authored-by: Dženan <dznv@pm.me>
Co-authored-by: MArtin Johnson <martinjohnson@bahnhof.se>
2024-11-26 08:01:13 +01:00
Ivy Gesare
193f9463ed Change: Fix errcheck issues in server/channels/app/platform/session_test.go (#29376) 2024-11-26 10:15:13 +08:00
catalintomai
c98f0f3a0f MM-60487: Consolidate config telemetry (#28200) 2024-11-25 17:35:25 +00:00
AulakhHarsh
f4e9221261 [MM-61768] Fix #29337 Errcheck in channels/app/platform/metrics.go (#29347) 2024-11-25 13:44:36 +01:00
Ivy Gesare
a61ffadd84 [MM-61766] Fix errcheck issues in server/channels/app/platform/link_cache.go (#29363) 2024-11-25 13:41:16 +01:00
TheInvincible
8e2610e459 update status_test.go (fix errcheck issue) (#29157)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-22 15:10:23 +01:00
Seiya Homma
5234b6897e [MM-61761] Fix errcheck issues in channels/app/platform/cluster_handlers.go (#29302)
* Fixed errcheck issues

* fixed issues

* fixed issues

* Fix merge conflict

* fix code
2024-11-22 12:40:26 +05:30
Julien Tant
3b1eb64e02 [MM-51201/MM-60406/MM-60404] CrossTeam Search posts and files (#28478)
* poc - wip

* add search files across teams

* eslint

* fix existing tests

* fix webapp style

* fix test

* add api doc

* change initial state in test

* add tests on API

* add tests on file info layer

* fix file search tags

* add rhs reducer test

* reset team selected when the RHS is suppressed

* change css to reflect UI

* fix style

* fix doc wording

* make getSearchTeam return currentTeamId when value is not set

* await is unnecessary

* revert boolean check and add test

* add comment to getSearchTeam to let dev knows it defaults to currentTeam

* remove redundant team check

* simplfy test

* fix style check

---------

Co-authored-by: Caleb Roseland <caleb@calebroseland.com>
Co-authored-by: Mattermost Build <build@mattermost.com>
2024-11-21 13:40:46 -07:00
Pattara Kiatisevi
f0280d6dd4 Thai tone marks and vowels at the end of the search term is wrongly removed. (#29071)
Co-authored-by: sukoom pornsuksiri <sukoom@mm.co.th>
2024-11-21 13:47:48 +00:00
David Edler
d59c5b2608 Fixed errcheck issues in server/channels/app/import_functions_test.go (#29229) 2024-11-21 13:14:07 +01:00
Arya Khochare
45860309b1 Fixed errcheck issues in server/channels/app/plugin_install.go (#29062)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-21 11:30:30 +01:00
Ben Schumacher
5911590ce6 [MM-61858] Fix flaky TestSendNotifications (#29339) 2024-11-21 09:51:59 +01:00
Vishal
746eb70e01 [MM-60689] Add Webhook ID in the logs (#28846)
* add webhook id to logs

* Move hook_id context to api level from app level.

* pass errCtx to other references of same app-error-id

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-11-21 13:53:10 +05:30
Scott Bishel
790103fae0 MM-59540 Ensure user has invite team permission in order to change setting (#28670)
* ensure user has invite team permission in order to change setting

* add tests and handle UI

* lint fixes

* revert changes to invite section input

* update tests

* revert bad merge

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-11-20 16:02:32 -07:00
Ben Schumacher
11b66de686 [MM-61693] Only check for LDAP info if LDAP is enabled during Support Packet generation (#29185) 2024-11-20 17:55:37 +01:00
Arya Khochare
b986f39825 Fixed errcheck issues in server/channels/api4/user_test.go (#28647)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-20 17:28:39 +01:00
TheoForger
4bb4f9814b [MM-61077] Fix errcheck issues in server/channels/web/static.go (#29285)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-20 14:44:22 +01:00
Rohan Sharma
5de425c298 [MM-61462] Fix errcheck issues in server/channels/app/post.go (#29205)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-20 14:43:48 +01:00
Ivy Gesare
82bd3b6df1 [MM-61762] Fix errcheck issues in server/channels/app/platform/config_test.go (#29323)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-20 12:23:44 +01:00
molejnik88
1a095f74c2 [MM-61459] Fix errcheck issues in server/channels/app/plugin_signatur… (#29202) 2024-11-20 10:40:05 +01:00
Agniva De Sarker
5c5276312b Fix race condition in app/channel_test.go (#29331) 2024-11-20 10:28:02 +01:00
Arya Khochare
ed7a38e80c Fixed errcheck issues in server/channels/app/server_test.go (#29199)
* errcheck issues fixed

* NoError to Error

---------

Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-19 12:45:47 -05:00
Domenico Rizzo
f64402e5c5 MM-61519 Fix errcheck in channels/app/plugin_api_tests/test_update_user_auth_plugin/main.go (#29284)
* Removed test_update_user_auth_plugin from golangci

The test_update_user_auth_plugin has been removed from the .golangci.yml configuration file. This change simplifies the linting process by excluding unnecessary files.

* Refactored error handling in user auth tests

The error handling for the 'expectUserAuth' function within the user authentication plugin tests has been refactored. Previously, errors were not being explicitly checked after each call to this function. Now, an error check is performed after each invocation and if an error is found, it's immediately returned. This change improves the robustness of our test suite by ensuring that potential issues are caught and handled appropriately during testing.

* Refactor error handling in UpdateUserAuth

The error handling in the UpdateUserAuth function has been refactored. The variable 'err' was replaced with 'appErr' to better reflect its purpose and improve code readability.

* Updated user authentication in plugin API

The user authentication method in the plugin API has been updated. Previously, it was fetching the user based on a static configuration value. Now, it fetches the user dynamically using the provided userID. This change makes the function more flexible and adaptable to different use cases.

* Updated golangci configuration

Removed a test file from the exclusion list in the golangci.yml configuration. This will allow linting checks to be performed on this previously excluded file, improving code quality and consistency.

* Updated golangci configuration

Removed a test file from the exclusion list in the golangci configuration. This will ensure that our linting tools also cover this previously excluded test file, improving overall code quality checks.

---------

Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-19 11:54:58 -05:00
Nick Misasi
8f716a61e6 remove Stripe CSP from server (#29306)
* remove Stripe CSP from server

* Update tests

* Fix more tests

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-11-19 10:57:32 -05:00
Harshil Sharma
05abb39019 Revert ana ccidental change (#29325) 2024-11-19 17:50:37 +05:30
David Edler
03a4462b19 Fixed errcheck issues in server/channels/app/channel_test.go (#29233)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-19 12:46:27 +01:00
Harshil Sharma
949e13725f Added precense check for scheduled posts before accessing error code (#29322)
* Added precense check for scheduled posts before accesing error code

* Expliocitelly stated the undefined nature
2024-11-19 10:58:09 +00:00
AulakhHarsh
e5a4b1efba Fix errcheck issues in server/channels/app/platform/busy_test.go (#29318) 2024-11-19 10:45:54 +01:00
Agniva De Sarker
c6a7a8f628 Fix flaky TestCreatePost and others (#29320)
We don't clear the Redis cache for every test.
This can cause issues because the cache is shared
across test. We fix that with this PR.
```release-note
NONE
```
2024-11-19 14:23:37 +05:30
Rohan Sharma
aa0d117f30 [MM-61101] Fix errcheck issues in server/channels/app/channel.go (#28787)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-19 08:56:23 +01:00
Weblate (bot)
9e05c075ff Translations update from Mattermost Weblate (#29317)
Automatic Merge
2024-11-18 14:17:13 +01:00
Agniva De Sarker
7f032b0b39 MM-61524: Fix flaky test RedisPubSub (#29311)
- We refactor some of the testlib assertion code
and add a new function to just return true or false.

https://mattermost.atlassian.net/browse/MM-61524
```release-note
NONE
```
2024-11-18 14:55:34 +05:30
TheInvincible
c2c2bc1efe update status.go (fix errcheck issue) (#29156)
Co-authored-by: Ben Schumacher <ben.schumacher@mattermost.com>
2024-11-18 09:23:11 +01:00
Rohan Sharma
c682f649b5 [MM-61464] Fix errcheck issues in server/channels/app/post_metadata.go (#29204)
Co-authored-by: Mattermost Build <build@mattermost.com>
2024-11-18 08:35:50 +01:00
Agniva De Sarker
d6a89c69c2 Fix flaky test TestScheduledPostStore (#29301)
There were couple of errors in the test:
1. UpdatedScheduledPost will automatically
set the ProcessedAt to now internally inside
toUpdateMap. So setting the value from outside
has no effect.
2. The bug was that if it took more than a
milisecond to capture the time, and then
do the internal call, then the Get call
will have a higher value and therefore fail.

Since UpdatedScheduledPost doesn't return
an updated post, so there is no need
to compare the timestamps at all.
```release-note
NONE
```
2024-11-16 14:32:46 +05:30
pRAnaY
504934b612 fixed errcheck in test_serve_metrics_plugin (#29289) 2024-11-15 21:02:17 +01:00
Harrison Healey
207503185e MM-61012 Add special handling to OS detection for mobile apps (#29139)
* Stop recording unknown platforms as "Windows" in Sessions table

* Add more tests to user_agent_test.go

* MM-61012 Add special handling to OS detection for mobile apps

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-11-15 12:25:28 -05:00