refactor: convert file fetch_commands to ts (#28139) #3
12968 tests run, 12924 passed, 36 skipped, 8 failed, 2 retried.
Annotations
Check failure on line 1 in com/mattermost/mattermost/server/v8/channels/api4
github-actions / Postgres (Results)
com/mattermost/mattermost/server/v8/channels/api4.TestSyncLdap/SystemAdminClient#01
Failed
Raw output
=== RUN TestSyncLdap/SystemAdminClient#01
{"timestamp":"2024-10-11 06:19:17.009 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"a5oi1qtz4bbbbfyydg1zzie81r","user_id":"cs3wfktgkpbmi8opcn17mrsqfc","status_code":"200"}
==================
WARNING: DATA RACE
Read at 0x00c009be4ab0 by goroutine 325580:
reflect.maplen()
/usr/local/go/src/runtime/map.go:1406 +0x0
reflect.Value.lenNonSlice()
/usr/local/go/src/reflect/value.go:1785 +0x1e9
reflect.Value.Len()
/usr/local/go/src/reflect/value.go:1774 +0x137
internal/fmtsort.Sort()
/usr/local/go/src/internal/fmtsort/sort.go:58 +0x121
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:816 +0x1144
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:853 +0x1d3e
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:853 +0x1d3e
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:921 +0x132a
fmt.(*pp).printArg()
/usr/local/go/src/fmt/print.go:759 +0xb84
fmt.(*pp).doPrintf()
/usr/local/go/src/fmt/print.go:1174 +0x10ce
fmt.Sprintf()
/usr/local/go/src/fmt/print.go:239 +0x5c
github.com/stretchr/testify/mock.Arguments.Diff()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:939 +0x1b2
github.com/stretchr/testify/mock.(*Mock).findExpectedCall()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:368 +0x147
github.com/stretchr/testify/mock.(*Mock).MethodCalled()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:476 +0xac
github.com/stretchr/testify/mock.(*Mock).Called()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:466 +0x195
github.com/mattermost/mattermost/server/v8/einterfaces/mocks.(*LdapInterface).StartSynchronizeJob()
/mattermost/server/einterfaces/mocks/LdapInterface.go:406 +0x1b0
github.com/mattermost/mattermost/server/v8/channels/app.(*App).SyncLdap.func1()
/mattermost/server/channels/app/ldap.go:33 +0x1d8
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).Go.func1()
/mattermost/server/channels/app/platform/goroutines.go:14 +0x37
Previous write at 0x00c009be4ab0 by goroutine 325520:
runtime.mapclear()
/usr/local/go/src/runtime/map.go:989 +0x0
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).ReturnSessionToPool()
/mattermost/server/channels/app/platform/session.go:25 +0xcf
github.com/mattermost/mattermost/server/v8/channels/app.(*App).ReturnSessionToPool()
/mattermost/server/channels/app/session.go:227 +0x26
github.com/mattermost/mattermost/server/v8/channels/web.Handler.ServeHTTP.deferwrap1()
/mattermost/server/channels/web/handlers.go:295 +0x55
runtime.deferreturn()
/usr/local/go/src/runtime/panic.go:602 +0x5d
github.com/mattermost/mattermost/server/v8/channels/web.(*Handler).ServeHTTP()
<autogenerated>:1 +0xe7
github.com/klauspost/compress/gzhttp.NewWrapper.func1.1()
/go/pkg/mod/github.com/klauspost/[email protected]/gzhttp/compress.go:495 +0x7c6
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2171 +0x47
github.com/gorilla/mux.(*Router).ServeHTTP()
/go/pkg/mod/github.com/gorilla/[email protected]/mux.go:212 +0x371
net/http.serverHandler.ServeHTTP()
/usr/local/go/src/net/http/server.go:3142 +0x2a1
net/http.(*conn).serve()
/usr/local/go/src/net/http/server.go:2044 +0x13c4
net/http.(*Server).Serve.gowrap3()
/usr/local/go/src/net/http/server.go:3290 +0x4f
Goroutine 325580 (running) created at:
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).Go()
/mattermost/server/channels/app/platform/goroutines.go:13 +0xec
github.com/mattermost/mattermost/server/v8/channels/app.(*Server).Go()
/mattermost/server/channels/app/server.go:806 +0x148
github.com/mattermost/mattermost/server/v8/channels/app.(*App).SyncLdap()
/mattermost/server/channels/app/ldap.go:21 +0x5d
github.com/mattermost/mattermost/server/v8/channels/api4.syncLdap()
/mattermost/server/channels/api4/ldap.go:69 +0x9de
github.com/mattermost/mattermost/server/v8/channels/web.Handler.ServeHTTP()
/mattermost/server/channels/web/handlers.go:387 +0x6645
github.com/mattermost/mattermost/server/v8/channels/web.(*Handler).ServeHTTP()
<autogenerated>:1 +0xe7
github.com/klauspost/compress/gzhttp.NewWrapper.func1.1()
/go/pkg/mod/github.com/klauspost/[email protected]/gzhttp/compress.go:495 +0x7c6
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2171 +0x47
github.com/gorilla/mux.(*Router).ServeHTTP()
/go/pkg/mod/github.com/gorilla/[email protected]/mux.go:212 +0x371
net/http.serverHandler.ServeHTTP()
/usr/local/go/src/net/http/server.go:3142 +0x2a1
net/http.(*conn).serve()
/usr/local/go/src/net/http/server.go:2044 +0x13c4
net/http.(*Server).Serve.gowrap3()
/usr/local/go/src/net/http/server.go:3290 +0x4f
Goroutine 325520 (running) created at:
net/http.(*Server).Serve()
/usr/local/go/src/net/http/server.go:3290 +0x8ec
github.com/mattermost/mattermost/server/v8/channels/app.(*Server).Start.func2()
/mattermost/server/channels/app/server.go:1070 +0x224
==================
{"timestamp":"2024-10-11 06:19:17.011 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"wboz9gtofbrfjxcsuw6atg6z1e","user_id":"cs3wfktgkpbmi8opcn17mrsqfc","status_code":"200"}
testing.go:1398: race detected during execution of test
--- FAIL: TestSyncLdap/SystemAdminClient#01 (0.01s)
Check failure on line 1 in com/mattermost/mattermost/server/v8/channels/api4
github-actions / Postgres (Results)
com/mattermost/mattermost/server/v8/channels/api4.TestSyncLdap
Failed
Raw output
=== RUN TestSyncLdap
{"timestamp":"2024-10-11 06:19:15.675 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 06:19:15.675 Z","level":"info","msg":"Successfully connected to cache backend","caller":"platform/service.go:191","backend":"redis","result":"PONG"}
{"timestamp":"2024-10-11 06:19:15.675 Z","level":"info","msg":"Server is initializing...","caller":"platform/service.go:194","go_version":"go1.22.6"}
{"timestamp":"2024-10-11 06:19:15.677 Z","level":"info","msg":"Starting websocket hubs","caller":"platform/web_hub.go:106","number_of_hubs":4}
{"timestamp":"2024-10-11 06:19:15.677 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":0}
{"timestamp":"2024-10-11 06:19:15.677 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":1}
{"timestamp":"2024-10-11 06:19:15.677 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":3}
{"timestamp":"2024-10-11 06:19:15.678 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":2}
{"timestamp":"2024-10-11 06:19:15.678 Z","level":"info","msg":"Loaded system translations","caller":"i18n/i18n.go:175","for locale":"en","from locale":"/mattermost/server/i18n/en.json"}
{"timestamp":"2024-10-11 06:19:15.685 Z","level":"info","msg":"Ensuring the telemetry ID..","caller":"telemetry/telemetry.go:167"}
{"timestamp":"2024-10-11 06:19:15.686 Z","level":"info","msg":"telemetry ID is set","caller":"telemetry/telemetry.go:177","id":"wzoqc3sreib8tb3rwfpy1eo1go"}
{"timestamp":"2024-10-11 06:19:15.707 Z","level":"error","msg":"SiteURL must be set. Some features will operate incorrectly if the SiteURL is not set. See documentation for details: https://mattermost.com/pl/configure-site-url","caller":"app/server.go:390"}
{"timestamp":"2024-10-11 06:19:15.707 Z","level":"info","msg":"Current version is 10.2.0 (///)","caller":"app/server.go:404","current_version":"10.2.0","build_number":"","build_date":"","build_hash":"","build_hash_enterprise":"","service_environment":"dev"}
{"timestamp":"2024-10-11 06:19:15.707 Z","level":"info","msg":"Team Edition Build","caller":"app/server.go:420","enterprise_build":false}
{"timestamp":"2024-10-11 06:19:15.707 Z","level":"info","msg":"Printing current working","caller":"app/server.go:424","directory":"/tmp/testlib3309064259"}
{"timestamp":"2024-10-11 06:19:15.707 Z","level":"info","msg":"Loaded config","caller":"app/server.go:425","source":"memory://"}
{"timestamp":"2024-10-11 06:19:15.933 Z","level":"debug","msg":"initElasticsearchChannelIndexCheck: calling elasticsearchChannelIndexCheckWithRetry before setting up config and license change listeners...","caller":"app/elasticsearch.go:21"}
{"timestamp":"2024-10-11 06:19:15.933 Z","level":"debug","msg":"elasticsearchChannelIndexCheckWithRetry: attempting to check channel index state...","caller":"app/elasticsearch.go:64"}
{"timestamp":"2024-10-11 06:19:15.933 Z","level":"debug","msg":"elasticsearchChannelIndexCheckWithRetry: skipping because elasticsearch indexing is disabled","caller":"app/elasticsearch.go:67"}
{"timestamp":"2024-10-11 06:19:15.976 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 06:19:15.983 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 06:19:15.983 Z","level":"info","msg":"Starting up plugins","caller":"app/plugin.go:191"}
{"timestamp":"2024-10-11 06:19:15.983 Z","level":"debug","msg":"Enabling plugin health check job","caller":"plugin/environment.go:661","interval_s":"30s"}
{"timestamp":"2024-10-11 06:19:15.983 Z","level":"info","msg":"Syncing plugins from the file store","caller":"app/plugin.go:268"}
{"timestamp":"2024-10-11 06:19:15.983 Z","level":"debug","msg":"Plugin health check job starting.","caller":"plugin/health_check.go:31"}
{"timestamp":"2024-10-11 06:19:15.983 Z","level":"info","msg":"No plugins to sync from the file store","caller":"app/plugin.go:311"}
{"timestamp":"2024-10-11 06:19:15.983 Z","level":"debug","msg":"No prepackaged plugins directory found","caller":"app/plugin.go:929"}
{"timestamp":"2024-10-11 06:19:15.983 Z","level":"debug","msg":"Not persisting transitionally prepackaged plugins: none found","caller":"app/plugin.go:1201"}
{"timestamp":"2024-10-11 06:19:15.988 Z","level":"debug","msg":"Able to write files to local storage.","caller":"filestore/localstore.go:82"}
{"timestamp":"2024-10-11 06:19:16.007 Z","level":"info","msg":"Starting Server...","caller":"app/server.go:887"}
{"timestamp":"2024-10-11 06:19:16.007 Z","level":"info","msg":"Server is listening on 127.0.0.1:35531","caller":"app/server.go:963","address":"127.0.0.1:35531"}
{"timestamp":"2024-10-11 06:19:16.007 Z","level":"debug","msg":"No license provided; Remote Cluster services disabled","caller":"app/server.go:580"}
{"timestamp":"2024-10-11 06:19:16.077 Z","level":"debug","msg":"Initializing web routes","caller":"web/web.go:26"}
{"timestamp":"2024-10-11 06:19:16.078 Z","level":"debug","msg":"Skipping update to assets subpath since CI build","caller":"utils/subpath.go:187"}
{"timestamp":"2024-10-11 06:19:16.078 Z","level":"debug","msg":"Using client directory","caller":"web/static.go:34","clientDir":"/tmp/testlib3309064259/client"}
{"timestamp":"2024-10-11 06:19:16.079 Z","level":"debug","msg":"Configured Client4 bool string values","caller":"api4/apitestlib.go:212","true":"True","false":"0"}
{"timestamp":"2024-10-11 06:19:16.951 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users/login","request_id":"ewfrshq8w7do8yop7ntuxdo14y","user_id":"s85hnqzabirrtqcxcfsxopbzno","status_code":"200"}
{"timestamp":"2024-10-11 06:19:16.961 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users/login","request_id":"yed5scbadfr7mjenasb7snhrmr","user_id":"cs3wfktgkpbmi8opcn17mrsqfc","status_code":"200"}
{"timestamp":"2024-10-11 06:19:16.964 Z","level":"info","msg":"Set license","caller":"platform/license.go:384","id":"","issued_at":"1970-01-01 00:00:00.000 Z","starts_at":"1970-01-01 00:00:00.000 Z","expires_at":"2025-01-09 06:19:16.964 Z","sku_name":"","sku_short_name":"","is_trial":false,"is_gov_sku":false,"customer_id":"some ID","features.users":0,"features":{"advanced_logging":true,"cloud":false,"cluster":true,"compliance":true,"custom_permissions_schemes":true,"data_retention":true,"elastic_search":true,"email_notification_contents":true,"enterprise_plugins":true,"future":true,"google":true,"guest_accounts":true,"guest_accounts_permissions":true,"id_loaded":true,"ldap":true,"ldap_groups":true,"lock_teammate_name_display":true,"message_export":true,"metrics":true,"mfa":true,"mhpns":true,"office365":true,"openid":true,"outgoing_oauth_connections":true,"remote_cluster_service":true,"saml":true,"shared_channels":true}}
{"timestamp":"2024-10-11 06:19:16.998 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 06:19:17.004 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 06:19:17.018 Z","level":"debug","msg":"You do not have the appropriate permissions.","caller":"web/context.go:120","path":"/api/v4/ldap/sync","request_id":"t3kqoxq6ujgh8qbxju47stzfur","ip_addr":"127.0.0.1","user_id":"s85hnqzabirrtqcxcfsxopbzno","method":"POST","err_where":"Permissions","http_code":403,"error":"Permissions: You do not have the appropriate permissions., userId=s85hnqzabirrtqcxcfsxopbzno, permission=create_ldap_sync_job"}
{"timestamp":"2024-10-11 06:19:17.018 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"t3kqoxq6ujgh8qbxju47stzfur","user_id":"s85hnqzabirrtqcxcfsxopbzno","status_code":"403"}
{"timestamp":"2024-10-11 06:19:17.019 Z","level":"info","msg":"Purging all caches","caller":"platform/cluster_handlers.go:114"}
{"timestamp":"2024-10-11 06:19:17.021 Z","level":"info","msg":"License key has not been uploaded. Loading license key from disk.","caller":"utils/license.go:107","filename":"/tmp/testlib3309064259/config/mattermost.mattermost-license"}
{"timestamp":"2024-10-11 06:19:17.021 Z","level":"warn","msg":"Failed to get license from disk","caller":"platform/license.go:93","error":"We could not find the license key on disk at /tmp/testlib3309064259/config/mattermost.mattermost-license: stat /tmp/testlib3309064259/config/mattermost.mattermost-license: no such file or directory"}
{"timestamp":"2024-10-11 06:19:17.022 Z","level":"warn","msg":"License key from https://mattermost.com required to unlock enterprise features.","caller":"platform/license.go:105","error":"resource \"License\" not found, id: "}
{"timestamp":"2024-10-11 06:19:17.022 Z","level":"info","msg":"Cleared license","caller":"platform/license.go:384","id":"","issued_at":"1970-01-01 00:00:00.000 Z","starts_at":"1970-01-01 00:00:00.000 Z","expires_at":"2025-01-09 06:19:16.964 Z","sku_name":"","sku_short_name":"","is_trial":false,"is_gov_sku":false,"customer_id":"some ID","features.users":0,"features":{"advanced_logging":true,"cloud":false,"cluster":true,"compliance":true,"custom_permissions_schemes":true,"data_retention":true,"elastic_search":true,"email_notification_contents":true,"enterprise_plugins":true,"future":true,"google":true,"guest_accounts":true,"guest_accounts_permissions":true,"id_loaded":true,"ldap":true,"ldap_groups":true,"lock_teammate_name_display":true,"message_export":true,"metrics":true,"mfa":true,"mhpns":true,"office365":true,"openid":true,"outgoing_oauth_connections":true,"remote_cluster_service":true,"saml":true,"shared_channels":true}}
{"timestamp":"2024-10-11 06:19:17.026 Z","level":"info","msg":"Stopping Server...","caller":"app/server.go:669"}
{"timestamp":"2024-10-11 06:19:17.035 Z","level":"info","msg":"Shutting down Email batching service...","caller":"email/service.go:85"}
{"timestamp":"2024-10-11 06:19:17.035 Z","level":"info","msg":"Shutting down plugins","caller":"app/plugin.go:362"}
{"timestamp":"2024-10-11 06:19:17.035 Z","level":"debug","msg":"Disabling plugin health check job","caller":"plugin/environment.go:670"}
{"timestamp":"2024-10-11 06:19:17.035 Z","level":"info","msg":"stopping websocket hub connections","caller":"platform/web_hub.go:127"}
{"timestamp":"2024-10-11 06:19:17.036 Z","level":"info","msg":"Server stopped","caller":"app/server.go:753"}
--- FAIL: TestSyncLdap (1.44s)
Check failure on line 1 in com/mattermost/mattermost/server/v8/channels/api4
github-actions / Postgres (Results)
com/mattermost/mattermost/server/v8/channels/api4.TestSyncLdap/SystemAdminClient#01
Failed
Raw output
=== RUN TestSyncLdap/SystemAdminClient#01
{"timestamp":"2024-10-11 07:15:15.367 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"dboofrduniysbe1oiykqjtjf9a","user_id":"wq4tmtkc7bdempy7foq7n5e35o","status_code":"200"}
==================
WARNING: DATA RACE
Read at 0x00c001914270 by goroutine 1201:
reflect.maplen()
/usr/local/go/src/runtime/map.go:1406 +0x0
reflect.Value.lenNonSlice()
/usr/local/go/src/reflect/value.go:1785 +0x1e9
reflect.Value.Len()
/usr/local/go/src/reflect/value.go:1774 +0x137
internal/fmtsort.Sort()
/usr/local/go/src/internal/fmtsort/sort.go:58 +0x121
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:816 +0x1144
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:853 +0x1d3e
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:853 +0x1d3e
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:921 +0x132a
fmt.(*pp).printArg()
/usr/local/go/src/fmt/print.go:759 +0xb84
fmt.(*pp).doPrintf()
/usr/local/go/src/fmt/print.go:1174 +0x10ce
fmt.Sprintf()
/usr/local/go/src/fmt/print.go:239 +0x5c
github.com/stretchr/testify/mock.Arguments.Diff()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:939 +0x1b2
github.com/stretchr/testify/mock.(*Mock).findExpectedCall()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:368 +0x147
github.com/stretchr/testify/mock.(*Mock).MethodCalled()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:476 +0xac
github.com/stretchr/testify/mock.(*Mock).Called()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:466 +0x195
github.com/mattermost/mattermost/server/v8/einterfaces/mocks.(*LdapInterface).StartSynchronizeJob()
/mattermost/server/einterfaces/mocks/LdapInterface.go:406 +0x1b0
github.com/mattermost/mattermost/server/v8/channels/app.(*App).SyncLdap.func1()
/mattermost/server/channels/app/ldap.go:33 +0x1d8
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).Go.func1()
/mattermost/server/channels/app/platform/goroutines.go:14 +0x37
Previous write at 0x00c001914270 by goroutine 1154:
runtime.mapclear()
/usr/local/go/src/runtime/map.go:989 +0x0
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).ReturnSessionToPool()
/mattermost/server/channels/app/platform/session.go:25 +0xcf
github.com/mattermost/mattermost/server/v8/channels/app.(*App).ReturnSessionToPool()
/mattermost/server/channels/app/session.go:227 +0x26
github.com/mattermost/mattermost/server/v8/channels/web.Handler.ServeHTTP.deferwrap1()
/mattermost/server/channels/web/handlers.go:295 +0x55
runtime.deferreturn()
/usr/local/go/src/runtime/panic.go:602 +0x5d
github.com/mattermost/mattermost/server/v8/channels/web.(*Handler).ServeHTTP()
<autogenerated>:1 +0xe7
github.com/klauspost/compress/gzhttp.NewWrapper.func1.1()
/go/pkg/mod/github.com/klauspost/[email protected]/gzhttp/compress.go:495 +0x7c6
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2171 +0x47
github.com/gorilla/mux.(*Router).ServeHTTP()
/go/pkg/mod/github.com/gorilla/[email protected]/mux.go:212 +0x371
net/http.serverHandler.ServeHTTP()
/usr/local/go/src/net/http/server.go:3142 +0x2a1
net/http.(*conn).serve()
/usr/local/go/src/net/http/server.go:2044 +0x13c4
net/http.(*Server).Serve.gowrap3()
/usr/local/go/src/net/http/server.go:3290 +0x4f
Goroutine 1201 (running) created at:
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).Go()
/mattermost/server/channels/app/platform/goroutines.go:13 +0xec
github.com/mattermost/mattermost/server/v8/channels/app.(*Server).Go()
/mattermost/server/channels/app/server.go:806 +0x148
github.com/mattermost/mattermost/server/v8/channels/app.(*App).SyncLdap()
/mattermost/server/channels/app/ldap.go:21 +0x5d
github.com/mattermost/mattermost/server/v8/channels/api4.syncLdap()
/mattermost/server/channels/api4/ldap.go:69 +0x9de
github.com/mattermost/mattermost/server/v8/channels/web.Handler.ServeHTTP()
/mattermost/server/channels/web/handlers.go:387 +0x6645
github.com/mattermost/mattermost/server/v8/channels/web.(*Handler).ServeHTTP()
<autogenerated>:1 +0xe7
github.com/klauspost/compress/gzhttp.NewWrapper.func1.1()
/go/pkg/mod/github.com/klauspost/[email protected]/gzhttp/compress.go:495 +0x7c6
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2171 +0x47
github.com/gorilla/mux.(*Router).ServeHTTP()
/go/pkg/mod/github.com/gorilla/[email protected]/mux.go:212 +0x371
net/http.serverHandler.ServeHTTP()
/usr/local/go/src/net/http/server.go:3142 +0x2a1
net/http.(*conn).serve()
/usr/local/go/src/net/http/server.go:2044 +0x13c4
net/http.(*Server).Serve.gowrap3()
/usr/local/go/src/net/http/server.go:3290 +0x4f
Goroutine 1154 (running) created at:
net/http.(*Server).Serve()
/usr/local/go/src/net/http/server.go:3290 +0x8ec
github.com/mattermost/mattermost/server/v8/channels/app.(*Server).Start.func2()
/mattermost/server/channels/app/server.go:1070 +0x224
==================
{"timestamp":"2024-10-11 07:15:15.372 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"af1jozxn938amr7pe83w9zgtiw","user_id":"wq4tmtkc7bdempy7foq7n5e35o","status_code":"200"}
testing.go:1398: race detected during execution of test
--- FAIL: TestSyncLdap/SystemAdminClient#01 (0.01s)
Check failure on line 1 in com/mattermost/mattermost/server/v8/channels/api4
github-actions / Postgres (Results)
com/mattermost/mattermost/server/v8/channels/api4.TestSyncLdap
Failed
Raw output
=== RUN TestSyncLdap
{"timestamp":"2024-10-11 07:15:09.786 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 07:15:09.786 Z","level":"info","msg":"Successfully connected to cache backend","caller":"platform/service.go:191","backend":"redis","result":"PONG"}
{"timestamp":"2024-10-11 07:15:09.786 Z","level":"info","msg":"Server is initializing...","caller":"platform/service.go:194","go_version":"go1.22.6"}
{"timestamp":"2024-10-11 07:15:09.788 Z","level":"info","msg":"Starting websocket hubs","caller":"platform/web_hub.go:106","number_of_hubs":4}
{"timestamp":"2024-10-11 07:15:09.788 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":1}
{"timestamp":"2024-10-11 07:15:09.788 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":0}
{"timestamp":"2024-10-11 07:15:09.788 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":2}
{"timestamp":"2024-10-11 07:15:09.788 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":3}
{"timestamp":"2024-10-11 07:15:09.789 Z","level":"info","msg":"Loaded system translations","caller":"i18n/i18n.go:175","for locale":"en","from locale":"/mattermost/server/i18n/en.json"}
{"timestamp":"2024-10-11 07:15:09.797 Z","level":"info","msg":"Ensuring the telemetry ID..","caller":"telemetry/telemetry.go:167"}
{"timestamp":"2024-10-11 07:15:09.798 Z","level":"info","msg":"telemetry ID is set","caller":"telemetry/telemetry.go:177","id":"798y8rrwq3gftkdmercc474xnw"}
{"timestamp":"2024-10-11 07:15:09.817 Z","level":"error","msg":"SiteURL must be set. Some features will operate incorrectly if the SiteURL is not set. See documentation for details: https://mattermost.com/pl/configure-site-url","caller":"app/server.go:390"}
{"timestamp":"2024-10-11 07:15:09.817 Z","level":"info","msg":"Current version is 10.2.0 (///)","caller":"app/server.go:404","current_version":"10.2.0","build_number":"","build_date":"","build_hash":"","build_hash_enterprise":"","service_environment":"dev"}
{"timestamp":"2024-10-11 07:15:09.817 Z","level":"info","msg":"Team Edition Build","caller":"app/server.go:420","enterprise_build":false}
{"timestamp":"2024-10-11 07:15:09.817 Z","level":"info","msg":"Printing current working","caller":"app/server.go:424","directory":"/tmp/testlib2988604483"}
{"timestamp":"2024-10-11 07:15:09.817 Z","level":"info","msg":"Loaded config","caller":"app/server.go:425","source":"memory://"}
{"timestamp":"2024-10-11 07:15:10.068 Z","level":"debug","msg":"initElasticsearchChannelIndexCheck: calling elasticsearchChannelIndexCheckWithRetry before setting up config and license change listeners...","caller":"app/elasticsearch.go:21"}
{"timestamp":"2024-10-11 07:15:10.068 Z","level":"debug","msg":"elasticsearchChannelIndexCheckWithRetry: attempting to check channel index state...","caller":"app/elasticsearch.go:64"}
{"timestamp":"2024-10-11 07:15:10.068 Z","level":"debug","msg":"elasticsearchChannelIndexCheckWithRetry: skipping because elasticsearch indexing is disabled","caller":"app/elasticsearch.go:67"}
{"timestamp":"2024-10-11 07:15:10.102 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 07:15:10.105 Z","level":"info","msg":"Post.Message has size restrictions","caller":"sqlstore/post_store.go:2619","max_characters":16383,"max_bytes":65535}
{"timestamp":"2024-10-11 07:15:10.111 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 07:15:10.111 Z","level":"info","msg":"Starting up plugins","caller":"app/plugin.go:191"}
{"timestamp":"2024-10-11 07:15:10.111 Z","level":"debug","msg":"Enabling plugin health check job","caller":"plugin/environment.go:661","interval_s":"30s"}
{"timestamp":"2024-10-11 07:15:10.111 Z","level":"info","msg":"Syncing plugins from the file store","caller":"app/plugin.go:268"}
{"timestamp":"2024-10-11 07:15:10.111 Z","level":"debug","msg":"Plugin health check job starting.","caller":"plugin/health_check.go:31"}
{"timestamp":"2024-10-11 07:15:10.111 Z","level":"info","msg":"No plugins to sync from the file store","caller":"app/plugin.go:311"}
{"timestamp":"2024-10-11 07:15:10.111 Z","level":"debug","msg":"No prepackaged plugins directory found","caller":"app/plugin.go:929"}
{"timestamp":"2024-10-11 07:15:10.111 Z","level":"debug","msg":"Not persisting transitionally prepackaged plugins: none found","caller":"app/plugin.go:1201"}
{"timestamp":"2024-10-11 07:15:10.116 Z","level":"debug","msg":"Able to write files to local storage.","caller":"filestore/localstore.go:82"}
{"timestamp":"2024-10-11 07:15:10.135 Z","level":"info","msg":"Starting Server...","caller":"app/server.go:887"}
{"timestamp":"2024-10-11 07:15:10.135 Z","level":"info","msg":"Server is listening on 127.0.0.1:43147","caller":"app/server.go:963","address":"127.0.0.1:43147"}
{"timestamp":"2024-10-11 07:15:10.136 Z","level":"debug","msg":"No license provided; Remote Cluster services disabled","caller":"app/server.go:580"}
{"timestamp":"2024-10-11 07:15:10.199 Z","level":"debug","msg":"Initializing web routes","caller":"web/web.go:26"}
{"timestamp":"2024-10-11 07:15:10.200 Z","level":"debug","msg":"Skipping update to assets subpath since CI build","caller":"utils/subpath.go:187"}
{"timestamp":"2024-10-11 07:15:10.200 Z","level":"debug","msg":"Using client directory","caller":"web/static.go:34","clientDir":"/tmp/testlib2988604483/client"}
{"timestamp":"2024-10-11 07:15:10.201 Z","level":"debug","msg":"Configured Client4 bool string values","caller":"api4/apitestlib.go:212","true":"1","false":"F"}
{"timestamp":"2024-10-11 07:15:10.204 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 07:15:11.056 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"k9zmk7eb8idyddsm4zsa67ocyc@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:11.083 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"8ern3wrxttduzftdef3ppemoch","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:11.097 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 07:15:11.920 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"md4bxz46f3fu3mip7ehp8wfhke@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:11.937 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"3u8ob7nhh3nmmrem5own6cnm7w","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:12.776 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"drpgwjgftbffdyuiu53ckpikuc@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:12.793 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"t41oxopky7b5zdccbgke71hgce","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:13.623 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"hf4f7zmtkbryjp47y87z3ym3uh@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:13.640 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"3qp4qf8iybgutfoqwzi5ddespo","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:14.478 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"cbek4hbqh3895duahehpapw99w@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:14.495 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"jgy1jkxoy7g4mpp8irx6gb5g6c","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:15.325 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users/login","request_id":"q5tfucosc386xqj1mgdsgrh86e","user_id":"6h9xcrr6xt8wmn3uubkhtjmodw","status_code":"200"}
{"timestamp":"2024-10-11 07:15:15.327 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users/login","request_id":"eu5n1d114p8c5mg9x33e9jiajo","user_id":"wq4tmtkc7bdempy7foq7n5e35o","status_code":"200"}
{"timestamp":"2024-10-11 07:15:15.328 Z","level":"info","msg":"Set license","caller":"platform/license.go:384","id":"","issued_at":"1970-01-01 00:00:00.000 Z","starts_at":"1970-01-01 00:00:00.000 Z","expires_at":"2025-01-09 07:15:15.328 Z","sku_name":"","sku_short_name":"","is_trial":false,"is_gov_sku":false,"customer_id":"some ID","features.users":0,"features":{"advanced_logging":true,"cloud":false,"cluster":true,"compliance":true,"custom_permissions_schemes":true,"data_retention":true,"elastic_search":true,"email_notification_contents":true,"enterprise_plugins":true,"future":true,"google":true,"guest_accounts":true,"guest_accounts_permissions":true,"id_loaded":true,"ldap":true,"ldap_groups":true,"lock_teammate_name_display":true,"message_export":true,"metrics":true,"mfa":true,"mhpns":true,"office365":true,"openid":true,"outgoing_oauth_connections":true,"remote_cluster_service":true,"saml":true,"shared_channels":true}}
{"timestamp":"2024-10-11 07:15:15.364 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 07:15:15.375 Z","level":"debug","msg":"You do not have the appropriate permissions.","caller":"web/context.go:120","path":"/api/v4/ldap/sync","request_id":"erceifzukfrf8dzzs6mmrpb4ur","ip_addr":"127.0.0.1","user_id":"6h9xcrr6xt8wmn3uubkhtjmodw","method":"POST","err_where":"Permissions","http_code":403,"error":"Permissions: You do not have the appropriate permissions., userId=6h9xcrr6xt8wmn3uubkhtjmodw, permission=create_ldap_sync_job"}
{"timestamp":"2024-10-11 07:15:15.375 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"erceifzukfrf8dzzs6mmrpb4ur","user_id":"6h9xcrr6xt8wmn3uubkhtjmodw","status_code":"403"}
{"timestamp":"2024-10-11 07:15:15.375 Z","level":"info","msg":"Purging all caches","caller":"platform/cluster_handlers.go:114"}
{"timestamp":"2024-10-11 07:15:15.378 Z","level":"info","msg":"License key has not been uploaded. Loading license key from disk.","caller":"utils/license.go:107","filename":"/tmp/testlib2988604483/config/mattermost.mattermost-license"}
{"timestamp":"2024-10-11 07:15:15.378 Z","level":"warn","msg":"Failed to get license from disk","caller":"platform/license.go:93","error":"We could not find the license key on disk at /tmp/testlib2988604483/config/mattermost.mattermost-license: stat /tmp/testlib2988604483/config/mattermost.mattermost-license: no such file or directory"}
{"timestamp":"2024-10-11 07:15:15.379 Z","level":"warn","msg":"License key from https://mattermost.com required to unlock enterprise features.","caller":"platform/license.go:105","error":"resource \"License\" not found, id: "}
{"timestamp":"2024-10-11 07:15:15.379 Z","level":"info","msg":"Cleared license","caller":"platform/license.go:384","id":"","issued_at":"1970-01-01 00:00:00.000 Z","starts_at":"1970-01-01 00:00:00.000 Z","expires_at":"2025-01-09 07:15:15.328 Z","sku_name":"","sku_short_name":"","is_trial":false,"is_gov_sku":false,"customer_id":"some ID","features.users":0,"features":{"advanced_logging":true,"cloud":false,"cluster":true,"compliance":true,"custom_permissions_schemes":true,"data_retention":true,"elastic_search":true,"email_notification_contents":true,"enterprise_plugins":true,"future":true,"google":true,"guest_accounts":true,"guest_accounts_permissions":true,"id_loaded":true,"ldap":true,"ldap_groups":true,"lock_teammate_name_display":true,"message_export":true,"metrics":true,"mfa":true,"mhpns":true,"office365":true,"openid":true,"outgoing_oauth_connections":true,"remote_cluster_service":true,"saml":true,"shared_channels":true}}
{"timestamp":"2024-10-11 07:15:15.382 Z","level":"info","msg":"Stopping Server...","caller":"app/server.go:669"}
{"timestamp":"2024-10-11 07:15:15.398 Z","level":"info","msg":"Shutting down Email batching service...","caller":"email/service.go:85"}
{"timestamp":"2024-10-11 07:15:15.398 Z","level":"info","msg":"Shutting down plugins","caller":"app/plugin.go:362"}
{"timestamp":"2024-10-11 07:15:15.398 Z","level":"debug","msg":"Disabling plugin health check job","caller":"plugin/environment.go:670"}
{"timestamp":"2024-10-11 07:15:15.398 Z","level":"info","msg":"stopping websocket hub connections","caller":"platform/web_hub.go:127"}
{"timestamp":"2024-10-11 07:15:15.400 Z","level":"info","msg":"Server stopped","caller":"app/server.go:753"}
--- FAIL: TestSyncLdap (5.69s)
Check failure on line 1 in com/mattermost/mattermost/server/v8/channels/api4
github-actions / Postgres (Results)
com/mattermost/mattermost/server/v8/channels/api4.TestSyncLdap/SystemAdminClient#01
Failed
Raw output
=== RUN TestSyncLdap/SystemAdminClient#01
{"timestamp":"2024-10-11 07:15:26.217 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"ptjnexkey7rp8mcoaumxzjbdse","user_id":"qziouir11tg1merxjxx96mr4te","status_code":"200"}
==================
WARNING: DATA RACE
Read at 0x00c0017dcd50 by goroutine 1202:
reflect.maplen()
/usr/local/go/src/runtime/map.go:1406 +0x0
reflect.Value.lenNonSlice()
/usr/local/go/src/reflect/value.go:1785 +0x1e9
reflect.Value.Len()
/usr/local/go/src/reflect/value.go:1774 +0x137
internal/fmtsort.Sort()
/usr/local/go/src/internal/fmtsort/sort.go:58 +0x121
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:816 +0x1144
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:853 +0x1d3e
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:853 +0x1d3e
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:921 +0x132a
fmt.(*pp).printArg()
/usr/local/go/src/fmt/print.go:759 +0xb84
fmt.(*pp).doPrintf()
/usr/local/go/src/fmt/print.go:1174 +0x10ce
fmt.Sprintf()
/usr/local/go/src/fmt/print.go:239 +0x5c
github.com/stretchr/testify/mock.Arguments.Diff()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:939 +0x1b2
github.com/stretchr/testify/mock.(*Mock).findExpectedCall()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:368 +0x147
github.com/stretchr/testify/mock.(*Mock).MethodCalled()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:476 +0xac
github.com/stretchr/testify/mock.(*Mock).Called()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:466 +0x195
github.com/mattermost/mattermost/server/v8/einterfaces/mocks.(*LdapInterface).StartSynchronizeJob()
/mattermost/server/einterfaces/mocks/LdapInterface.go:406 +0x1b0
github.com/mattermost/mattermost/server/v8/channels/app.(*App).SyncLdap.func1()
/mattermost/server/channels/app/ldap.go:33 +0x1d8
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).Go.func1()
/mattermost/server/channels/app/platform/goroutines.go:14 +0x37
Previous write at 0x00c0017dcd50 by goroutine 988:
runtime.mapclear()
/usr/local/go/src/runtime/map.go:989 +0x0
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).ReturnSessionToPool()
/mattermost/server/channels/app/platform/session.go:25 +0xcf
github.com/mattermost/mattermost/server/v8/channels/app.(*App).ReturnSessionToPool()
/mattermost/server/channels/app/session.go:227 +0x26
github.com/mattermost/mattermost/server/v8/channels/web.Handler.ServeHTTP.deferwrap1()
/mattermost/server/channels/web/handlers.go:295 +0x55
runtime.deferreturn()
/usr/local/go/src/runtime/panic.go:602 +0x5d
github.com/mattermost/mattermost/server/v8/channels/web.(*Handler).ServeHTTP()
<autogenerated>:1 +0xe7
github.com/klauspost/compress/gzhttp.NewWrapper.func1.1()
/go/pkg/mod/github.com/klauspost/[email protected]/gzhttp/compress.go:495 +0x7c6
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2171 +0x47
github.com/gorilla/mux.(*Router).ServeHTTP()
/go/pkg/mod/github.com/gorilla/[email protected]/mux.go:212 +0x371
net/http.serverHandler.ServeHTTP()
/usr/local/go/src/net/http/server.go:3142 +0x2a1
net/http.(*conn).serve()
/usr/local/go/src/net/http/server.go:2044 +0x13c4
net/http.(*Server).Serve.gowrap3()
/usr/local/go/src/net/http/server.go:3290 +0x4f
Goroutine 1202 (running) created at:
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).Go()
/mattermost/server/channels/app/platform/goroutines.go:13 +0xec
github.com/mattermost/mattermost/server/v8/channels/app.(*Server).Go()
/mattermost/server/channels/app/server.go:806 +0x148
github.com/mattermost/mattermost/server/v8/channels/app.(*App).SyncLdap()
/mattermost/server/channels/app/ldap.go:21 +0x5d
github.com/mattermost/mattermost/server/v8/channels/api4.syncLdap()
/mattermost/server/channels/api4/ldap.go:69 +0x9de
github.com/mattermost/mattermost/server/v8/channels/web.Handler.ServeHTTP()
/mattermost/server/channels/web/handlers.go:387 +0x6645
github.com/mattermost/mattermost/server/v8/channels/web.(*Handler).ServeHTTP()
<autogenerated>:1 +0xe7
github.com/klauspost/compress/gzhttp.NewWrapper.func1.1()
/go/pkg/mod/github.com/klauspost/[email protected]/gzhttp/compress.go:495 +0x7c6
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2171 +0x47
github.com/gorilla/mux.(*Router).ServeHTTP()
/go/pkg/mod/github.com/gorilla/[email protected]/mux.go:212 +0x371
net/http.serverHandler.ServeHTTP()
/usr/local/go/src/net/http/server.go:3142 +0x2a1
net/http.(*conn).serve()
/usr/local/go/src/net/http/server.go:2044 +0x13c4
net/http.(*Server).Serve.gowrap3()
/usr/local/go/src/net/http/server.go:3290 +0x4f
Goroutine 988 (running) created at:
net/http.(*Server).Serve()
/usr/local/go/src/net/http/server.go:3290 +0x8ec
github.com/mattermost/mattermost/server/v8/channels/app.(*Server).Start.func2()
/mattermost/server/channels/app/server.go:1070 +0x224
==================
{"timestamp":"2024-10-11 07:15:26.221 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"pdyp7j1g3tgg38wy6widks1gho","user_id":"qziouir11tg1merxjxx96mr4te","status_code":"200"}
testing.go:1398: race detected during execution of test
--- FAIL: TestSyncLdap/SystemAdminClient#01 (0.01s)
Check failure on line 1 in com/mattermost/mattermost/server/v8/channels/api4
github-actions / Postgres (Results)
com/mattermost/mattermost/server/v8/channels/api4.TestSyncLdap
Failed
Raw output
=== RUN TestSyncLdap
{"timestamp":"2024-10-11 07:15:20.602 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 07:15:20.602 Z","level":"info","msg":"Successfully connected to cache backend","caller":"platform/service.go:191","backend":"redis","result":"PONG"}
{"timestamp":"2024-10-11 07:15:20.602 Z","level":"info","msg":"Server is initializing...","caller":"platform/service.go:194","go_version":"go1.22.6"}
{"timestamp":"2024-10-11 07:15:20.605 Z","level":"info","msg":"Starting websocket hubs","caller":"platform/web_hub.go:106","number_of_hubs":4}
{"timestamp":"2024-10-11 07:15:20.605 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":0}
{"timestamp":"2024-10-11 07:15:20.605 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":2}
{"timestamp":"2024-10-11 07:15:20.605 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":1}
{"timestamp":"2024-10-11 07:15:20.605 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":3}
{"timestamp":"2024-10-11 07:15:20.606 Z","level":"info","msg":"Loaded system translations","caller":"i18n/i18n.go:175","for locale":"en","from locale":"/mattermost/server/i18n/en.json"}
{"timestamp":"2024-10-11 07:15:20.614 Z","level":"info","msg":"Ensuring the telemetry ID..","caller":"telemetry/telemetry.go:167"}
{"timestamp":"2024-10-11 07:15:20.615 Z","level":"info","msg":"telemetry ID is set","caller":"telemetry/telemetry.go:177","id":"jq8w36xpojdzf89ermtio69fbe"}
{"timestamp":"2024-10-11 07:15:20.634 Z","level":"error","msg":"SiteURL must be set. Some features will operate incorrectly if the SiteURL is not set. See documentation for details: https://mattermost.com/pl/configure-site-url","caller":"app/server.go:390"}
{"timestamp":"2024-10-11 07:15:20.634 Z","level":"info","msg":"Current version is 10.2.0 (///)","caller":"app/server.go:404","current_version":"10.2.0","build_number":"","build_date":"","build_hash":"","build_hash_enterprise":"","service_environment":"dev"}
{"timestamp":"2024-10-11 07:15:20.634 Z","level":"info","msg":"Team Edition Build","caller":"app/server.go:420","enterprise_build":false}
{"timestamp":"2024-10-11 07:15:20.634 Z","level":"info","msg":"Printing current working","caller":"app/server.go:424","directory":"/tmp/testlib1964125163"}
{"timestamp":"2024-10-11 07:15:20.634 Z","level":"info","msg":"Loaded config","caller":"app/server.go:425","source":"memory://"}
{"timestamp":"2024-10-11 07:15:20.879 Z","level":"debug","msg":"initElasticsearchChannelIndexCheck: calling elasticsearchChannelIndexCheckWithRetry before setting up config and license change listeners...","caller":"app/elasticsearch.go:21"}
{"timestamp":"2024-10-11 07:15:20.879 Z","level":"debug","msg":"elasticsearchChannelIndexCheckWithRetry: attempting to check channel index state...","caller":"app/elasticsearch.go:64"}
{"timestamp":"2024-10-11 07:15:20.879 Z","level":"debug","msg":"elasticsearchChannelIndexCheckWithRetry: skipping because elasticsearch indexing is disabled","caller":"app/elasticsearch.go:67"}
{"timestamp":"2024-10-11 07:15:20.913 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 07:15:20.915 Z","level":"info","msg":"Post.Message has size restrictions","caller":"sqlstore/post_store.go:2619","max_characters":16383,"max_bytes":65535}
{"timestamp":"2024-10-11 07:15:20.920 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 07:15:20.920 Z","level":"info","msg":"Starting up plugins","caller":"app/plugin.go:191"}
{"timestamp":"2024-10-11 07:15:20.920 Z","level":"debug","msg":"Enabling plugin health check job","caller":"plugin/environment.go:661","interval_s":"30s"}
{"timestamp":"2024-10-11 07:15:20.921 Z","level":"info","msg":"Syncing plugins from the file store","caller":"app/plugin.go:268"}
{"timestamp":"2024-10-11 07:15:20.921 Z","level":"debug","msg":"Plugin health check job starting.","caller":"plugin/health_check.go:31"}
{"timestamp":"2024-10-11 07:15:20.921 Z","level":"info","msg":"No plugins to sync from the file store","caller":"app/plugin.go:311"}
{"timestamp":"2024-10-11 07:15:20.921 Z","level":"debug","msg":"No prepackaged plugins directory found","caller":"app/plugin.go:929"}
{"timestamp":"2024-10-11 07:15:20.921 Z","level":"debug","msg":"Not persisting transitionally prepackaged plugins: none found","caller":"app/plugin.go:1201"}
{"timestamp":"2024-10-11 07:15:20.926 Z","level":"debug","msg":"Able to write files to local storage.","caller":"filestore/localstore.go:82"}
{"timestamp":"2024-10-11 07:15:20.945 Z","level":"info","msg":"Starting Server...","caller":"app/server.go:887"}
{"timestamp":"2024-10-11 07:15:20.945 Z","level":"info","msg":"Server is listening on 127.0.0.1:44543","caller":"app/server.go:963","address":"127.0.0.1:44543"}
{"timestamp":"2024-10-11 07:15:20.945 Z","level":"debug","msg":"No license provided; Remote Cluster services disabled","caller":"app/server.go:580"}
{"timestamp":"2024-10-11 07:15:21.010 Z","level":"debug","msg":"Initializing web routes","caller":"web/web.go:26"}
{"timestamp":"2024-10-11 07:15:21.012 Z","level":"debug","msg":"Skipping update to assets subpath since CI build","caller":"utils/subpath.go:187"}
{"timestamp":"2024-10-11 07:15:21.012 Z","level":"debug","msg":"Using client directory","caller":"web/static.go:34","clientDir":"/tmp/testlib1964125163/client"}
{"timestamp":"2024-10-11 07:15:21.012 Z","level":"debug","msg":"Configured Client4 bool string values","caller":"api4/apitestlib.go:212","true":"T","false":"0"}
{"timestamp":"2024-10-11 07:15:21.015 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 07:15:21.851 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"79wz975d3j8tfkjwr16xcafyoh@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:21.877 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"5noqi458b3d3xykc8ikx16fq8w","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:21.891 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 07:15:22.713 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"ojwn46oentgojjuhsss39r96te@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:22.731 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"3s3fi7drh3fopyego7ixtjjb5a","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:23.565 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"gnay7aro4pdhjj5zk8n5kmiarc@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:23.582 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"jjsriwjy1tyjj8mdx13xozdfec","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:24.426 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"ado5n11677ncxe9zqa3n4torgw@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:24.443 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"cxmz1san93r57dr6jjz6o6bncc","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:25.272 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"8h4tw3d1x7ghzeqeuuddnkag6r@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:25.289 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"ceiwosddkighzgnhuohaoti5py","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:26.171 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users/login","request_id":"ys1etp79ityypf7xt31sn9eb8a","user_id":"qziouir11tg1merxjxx96mr4te","status_code":"200"}
{"timestamp":"2024-10-11 07:15:26.177 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users/login","request_id":"3jtwoufdc7nrtmpbyxzqyhwh6h","user_id":"o7fsiotxfb8m9cezmo5ceax63w","status_code":"200"}
{"timestamp":"2024-10-11 07:15:26.178 Z","level":"info","msg":"Set license","caller":"platform/license.go:384","id":"","issued_at":"1970-01-01 00:00:00.000 Z","starts_at":"1970-01-01 00:00:00.000 Z","expires_at":"2025-01-09 07:15:26.178 Z","sku_name":"","sku_short_name":"","is_trial":false,"is_gov_sku":false,"customer_id":"some ID","features.users":0,"features":{"advanced_logging":true,"cloud":false,"cluster":true,"compliance":true,"custom_permissions_schemes":true,"data_retention":true,"elastic_search":true,"email_notification_contents":true,"enterprise_plugins":true,"future":true,"google":true,"guest_accounts":true,"guest_accounts_permissions":true,"id_loaded":true,"ldap":true,"ldap_groups":true,"lock_teammate_name_display":true,"message_export":true,"metrics":true,"mfa":true,"mhpns":true,"office365":true,"openid":true,"outgoing_oauth_connections":true,"remote_cluster_service":true,"saml":true,"shared_channels":true}}
{"timestamp":"2024-10-11 07:15:26.215 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 07:15:26.223 Z","level":"debug","msg":"You do not have the appropriate permissions.","caller":"web/context.go:120","path":"/api/v4/ldap/sync","request_id":"yt4m1dgtftr3jxhhsg1gsj9g5y","ip_addr":"127.0.0.1","user_id":"o7fsiotxfb8m9cezmo5ceax63w","method":"POST","err_where":"Permissions","http_code":403,"error":"Permissions: You do not have the appropriate permissions., userId=o7fsiotxfb8m9cezmo5ceax63w, permission=create_ldap_sync_job"}
{"timestamp":"2024-10-11 07:15:26.223 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"yt4m1dgtftr3jxhhsg1gsj9g5y","user_id":"o7fsiotxfb8m9cezmo5ceax63w","status_code":"403"}
{"timestamp":"2024-10-11 07:15:26.224 Z","level":"info","msg":"Purging all caches","caller":"platform/cluster_handlers.go:114"}
{"timestamp":"2024-10-11 07:15:26.231 Z","level":"info","msg":"License key has not been uploaded. Loading license key from disk.","caller":"utils/license.go:107","filename":"/tmp/testlib1964125163/config/mattermost.mattermost-license"}
{"timestamp":"2024-10-11 07:15:26.231 Z","level":"warn","msg":"Failed to get license from disk","caller":"platform/license.go:93","error":"We could not find the license key on disk at /tmp/testlib1964125163/config/mattermost.mattermost-license: stat /tmp/testlib1964125163/config/mattermost.mattermost-license: no such file or directory"}
{"timestamp":"2024-10-11 07:15:26.232 Z","level":"warn","msg":"License key from https://mattermost.com required to unlock enterprise features.","caller":"platform/license.go:105","error":"resource \"License\" not found, id: "}
{"timestamp":"2024-10-11 07:15:26.232 Z","level":"info","msg":"Cleared license","caller":"platform/license.go:384","id":"","issued_at":"1970-01-01 00:00:00.000 Z","starts_at":"1970-01-01 00:00:00.000 Z","expires_at":"2025-01-09 07:15:26.178 Z","sku_name":"","sku_short_name":"","is_trial":false,"is_gov_sku":false,"customer_id":"some ID","features.users":0,"features":{"advanced_logging":true,"cloud":false,"cluster":true,"compliance":true,"custom_permissions_schemes":true,"data_retention":true,"elastic_search":true,"email_notification_contents":true,"enterprise_plugins":true,"future":true,"google":true,"guest_accounts":true,"guest_accounts_permissions":true,"id_loaded":true,"ldap":true,"ldap_groups":true,"lock_teammate_name_display":true,"message_export":true,"metrics":true,"mfa":true,"mhpns":true,"office365":true,"openid":true,"outgoing_oauth_connections":true,"remote_cluster_service":true,"saml":true,"shared_channels":true}}
{"timestamp":"2024-10-11 07:15:26.236 Z","level":"info","msg":"Stopping Server...","caller":"app/server.go:669"}
{"timestamp":"2024-10-11 07:15:26.251 Z","level":"info","msg":"Shutting down Email batching service...","caller":"email/service.go:85"}
{"timestamp":"2024-10-11 07:15:26.251 Z","level":"info","msg":"Shutting down plugins","caller":"app/plugin.go:362"}
{"timestamp":"2024-10-11 07:15:26.251 Z","level":"debug","msg":"Disabling plugin health check job","caller":"plugin/environment.go:670"}
{"timestamp":"2024-10-11 07:15:26.251 Z","level":"info","msg":"stopping websocket hub connections","caller":"platform/web_hub.go:127"}
{"timestamp":"2024-10-11 07:15:26.252 Z","level":"info","msg":"Server stopped","caller":"app/server.go:753"}
--- FAIL: TestSyncLdap (5.74s)
Check failure on line 1 in com/mattermost/mattermost/server/v8/channels/api4
github-actions / Postgres (Results)
com/mattermost/mattermost/server/v8/channels/api4.TestSyncLdap/SystemAdminClient#01
Failed
Raw output
=== RUN TestSyncLdap/SystemAdminClient#01
{"timestamp":"2024-10-11 07:15:37.050 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"hx15747yf7g9xrkc46jkp351kr","user_id":"9cjjzq15rtyw9mkcst5tec5two","status_code":"200"}
==================
WARNING: DATA RACE
Read at 0x00c00218d8f0 by goroutine 1201:
reflect.maplen()
/usr/local/go/src/runtime/map.go:1406 +0x0
reflect.Value.lenNonSlice()
/usr/local/go/src/reflect/value.go:1785 +0x1e9
reflect.Value.Len()
/usr/local/go/src/reflect/value.go:1774 +0x137
internal/fmtsort.Sort()
/usr/local/go/src/internal/fmtsort/sort.go:58 +0x121
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:816 +0x1144
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:853 +0x1d3e
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:853 +0x1d3e
fmt.(*pp).printValue()
/usr/local/go/src/fmt/print.go:921 +0x132a
fmt.(*pp).printArg()
/usr/local/go/src/fmt/print.go:759 +0xb84
fmt.(*pp).doPrintf()
/usr/local/go/src/fmt/print.go:1174 +0x10ce
fmt.Sprintf()
/usr/local/go/src/fmt/print.go:239 +0x5c
github.com/stretchr/testify/mock.Arguments.Diff()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:939 +0x1b2
github.com/stretchr/testify/mock.(*Mock).findExpectedCall()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:368 +0x147
github.com/stretchr/testify/mock.(*Mock).MethodCalled()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:476 +0xac
github.com/stretchr/testify/mock.(*Mock).Called()
/go/pkg/mod/github.com/stretchr/[email protected]/mock/mock.go:466 +0x195
github.com/mattermost/mattermost/server/v8/einterfaces/mocks.(*LdapInterface).StartSynchronizeJob()
/mattermost/server/einterfaces/mocks/LdapInterface.go:406 +0x1b0
github.com/mattermost/mattermost/server/v8/channels/app.(*App).SyncLdap.func1()
/mattermost/server/channels/app/ldap.go:33 +0x1d8
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).Go.func1()
/mattermost/server/channels/app/platform/goroutines.go:14 +0x37
Previous write at 0x00c00218d8f0 by goroutine 988:
runtime.mapclear()
/usr/local/go/src/runtime/map.go:989 +0x0
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).ReturnSessionToPool()
/mattermost/server/channels/app/platform/session.go:25 +0xcf
github.com/mattermost/mattermost/server/v8/channels/app.(*App).ReturnSessionToPool()
/mattermost/server/channels/app/session.go:227 +0x26
github.com/mattermost/mattermost/server/v8/channels/web.Handler.ServeHTTP.deferwrap1()
/mattermost/server/channels/web/handlers.go:295 +0x55
runtime.deferreturn()
/usr/local/go/src/runtime/panic.go:602 +0x5d
github.com/mattermost/mattermost/server/v8/channels/web.(*Handler).ServeHTTP()
<autogenerated>:1 +0xe7
github.com/klauspost/compress/gzhttp.NewWrapper.func1.1()
/go/pkg/mod/github.com/klauspost/[email protected]/gzhttp/compress.go:495 +0x7c6
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2171 +0x47
github.com/gorilla/mux.(*Router).ServeHTTP()
/go/pkg/mod/github.com/gorilla/[email protected]/mux.go:212 +0x371
net/http.serverHandler.ServeHTTP()
/usr/local/go/src/net/http/server.go:3142 +0x2a1
net/http.(*conn).serve()
/usr/local/go/src/net/http/server.go:2044 +0x13c4
net/http.(*Server).Serve.gowrap3()
/usr/local/go/src/net/http/server.go:3290 +0x4f
Goroutine 1201 (running) created at:
github.com/mattermost/mattermost/server/v8/channels/app/platform.(*PlatformService).Go()
/mattermost/server/channels/app/platform/goroutines.go:13 +0xec
github.com/mattermost/mattermost/server/v8/channels/app.(*Server).Go()
/mattermost/server/channels/app/server.go:806 +0x148
github.com/mattermost/mattermost/server/v8/channels/app.(*App).SyncLdap()
/mattermost/server/channels/app/ldap.go:21 +0x5d
github.com/mattermost/mattermost/server/v8/channels/api4.syncLdap()
/mattermost/server/channels/api4/ldap.go:69 +0x9de
github.com/mattermost/mattermost/server/v8/channels/web.Handler.ServeHTTP()
/mattermost/server/channels/web/handlers.go:387 +0x6645
github.com/mattermost/mattermost/server/v8/channels/web.(*Handler).ServeHTTP()
<autogenerated>:1 +0xe7
github.com/klauspost/compress/gzhttp.NewWrapper.func1.1()
/go/pkg/mod/github.com/klauspost/[email protected]/gzhttp/compress.go:495 +0x7c6
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2171 +0x47
github.com/gorilla/mux.(*Router).ServeHTTP()
/go/pkg/mod/github.com/gorilla/[email protected]/mux.go:212 +0x371
net/http.serverHandler.ServeHTTP()
/usr/local/go/src/net/http/server.go:3142 +0x2a1
net/http.(*conn).serve()
/usr/local/go/src/net/http/server.go:2044 +0x13c4
net/http.(*Server).Serve.gowrap3()
/usr/local/go/src/net/http/server.go:3290 +0x4f
Goroutine 988 (running) created at:
net/http.(*Server).Serve()
/usr/local/go/src/net/http/server.go:3290 +0x8ec
github.com/mattermost/mattermost/server/v8/channels/app.(*Server).Start.func2()
/mattermost/server/channels/app/server.go:1070 +0x224
==================
{"timestamp":"2024-10-11 07:15:37.053 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"wfyy5q7nq3n1mmbo1mbahozdpr","user_id":"9cjjzq15rtyw9mkcst5tec5two","status_code":"200"}
testing.go:1398: race detected during execution of test
--- FAIL: TestSyncLdap/SystemAdminClient#01 (0.01s)
Check failure on line 1 in com/mattermost/mattermost/server/v8/channels/api4
github-actions / Postgres (Results)
com/mattermost/mattermost/server/v8/channels/api4.TestSyncLdap
Failed
Raw output
=== RUN TestSyncLdap
{"timestamp":"2024-10-11 07:15:31.413 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 07:15:31.413 Z","level":"info","msg":"Successfully connected to cache backend","caller":"platform/service.go:191","backend":"redis","result":"PONG"}
{"timestamp":"2024-10-11 07:15:31.413 Z","level":"info","msg":"Server is initializing...","caller":"platform/service.go:194","go_version":"go1.22.6"}
{"timestamp":"2024-10-11 07:15:31.416 Z","level":"info","msg":"Starting websocket hubs","caller":"platform/web_hub.go:106","number_of_hubs":4}
{"timestamp":"2024-10-11 07:15:31.416 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":1}
{"timestamp":"2024-10-11 07:15:31.416 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":0}
{"timestamp":"2024-10-11 07:15:31.416 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":3}
{"timestamp":"2024-10-11 07:15:31.416 Z","level":"debug","msg":"Hub is starting","caller":"platform/web_hub.go:386","index":2}
{"timestamp":"2024-10-11 07:15:31.417 Z","level":"info","msg":"Loaded system translations","caller":"i18n/i18n.go:175","for locale":"en","from locale":"/mattermost/server/i18n/en.json"}
{"timestamp":"2024-10-11 07:15:31.425 Z","level":"info","msg":"Ensuring the telemetry ID..","caller":"telemetry/telemetry.go:167"}
{"timestamp":"2024-10-11 07:15:31.426 Z","level":"info","msg":"telemetry ID is set","caller":"telemetry/telemetry.go:177","id":"aob7dgr3638zpxr58z1ectccne"}
{"timestamp":"2024-10-11 07:15:31.445 Z","level":"error","msg":"SiteURL must be set. Some features will operate incorrectly if the SiteURL is not set. See documentation for details: https://mattermost.com/pl/configure-site-url","caller":"app/server.go:390"}
{"timestamp":"2024-10-11 07:15:31.445 Z","level":"info","msg":"Current version is 10.2.0 (///)","caller":"app/server.go:404","current_version":"10.2.0","build_number":"","build_date":"","build_hash":"","build_hash_enterprise":"","service_environment":"dev"}
{"timestamp":"2024-10-11 07:15:31.445 Z","level":"info","msg":"Team Edition Build","caller":"app/server.go:420","enterprise_build":false}
{"timestamp":"2024-10-11 07:15:31.446 Z","level":"info","msg":"Printing current working","caller":"app/server.go:424","directory":"/tmp/testlib1522937082"}
{"timestamp":"2024-10-11 07:15:31.446 Z","level":"info","msg":"Loaded config","caller":"app/server.go:425","source":"memory://"}
{"timestamp":"2024-10-11 07:15:31.702 Z","level":"debug","msg":"initElasticsearchChannelIndexCheck: calling elasticsearchChannelIndexCheckWithRetry before setting up config and license change listeners...","caller":"app/elasticsearch.go:21"}
{"timestamp":"2024-10-11 07:15:31.702 Z","level":"debug","msg":"elasticsearchChannelIndexCheckWithRetry: attempting to check channel index state...","caller":"app/elasticsearch.go:64"}
{"timestamp":"2024-10-11 07:15:31.702 Z","level":"debug","msg":"elasticsearchChannelIndexCheckWithRetry: skipping because elasticsearch indexing is disabled","caller":"app/elasticsearch.go:67"}
{"timestamp":"2024-10-11 07:15:31.735 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 07:15:31.738 Z","level":"info","msg":"Post.Message has size restrictions","caller":"sqlstore/post_store.go:2619","max_characters":16383,"max_bytes":65535}
{"timestamp":"2024-10-11 07:15:31.743 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 07:15:31.743 Z","level":"info","msg":"Starting up plugins","caller":"app/plugin.go:191"}
{"timestamp":"2024-10-11 07:15:31.744 Z","level":"debug","msg":"Enabling plugin health check job","caller":"plugin/environment.go:661","interval_s":"30s"}
{"timestamp":"2024-10-11 07:15:31.744 Z","level":"info","msg":"Syncing plugins from the file store","caller":"app/plugin.go:268"}
{"timestamp":"2024-10-11 07:15:31.744 Z","level":"debug","msg":"Plugin health check job starting.","caller":"plugin/health_check.go:31"}
{"timestamp":"2024-10-11 07:15:31.744 Z","level":"info","msg":"No plugins to sync from the file store","caller":"app/plugin.go:311"}
{"timestamp":"2024-10-11 07:15:31.744 Z","level":"debug","msg":"No prepackaged plugins directory found","caller":"app/plugin.go:929"}
{"timestamp":"2024-10-11 07:15:31.744 Z","level":"debug","msg":"Not persisting transitionally prepackaged plugins: none found","caller":"app/plugin.go:1201"}
{"timestamp":"2024-10-11 07:15:31.749 Z","level":"debug","msg":"Able to write files to local storage.","caller":"filestore/localstore.go:82"}
{"timestamp":"2024-10-11 07:15:31.768 Z","level":"info","msg":"Starting Server...","caller":"app/server.go:887"}
{"timestamp":"2024-10-11 07:15:31.769 Z","level":"info","msg":"Server is listening on 127.0.0.1:45761","caller":"app/server.go:963","address":"127.0.0.1:45761"}
{"timestamp":"2024-10-11 07:15:31.769 Z","level":"debug","msg":"No license provided; Remote Cluster services disabled","caller":"app/server.go:580"}
{"timestamp":"2024-10-11 07:15:31.835 Z","level":"debug","msg":"Initializing web routes","caller":"web/web.go:26"}
{"timestamp":"2024-10-11 07:15:31.837 Z","level":"debug","msg":"Skipping update to assets subpath since CI build","caller":"utils/subpath.go:187"}
{"timestamp":"2024-10-11 07:15:31.837 Z","level":"debug","msg":"Using client directory","caller":"web/static.go:34","clientDir":"/tmp/testlib1522937082/client"}
{"timestamp":"2024-10-11 07:15:31.838 Z","level":"debug","msg":"Configured Client4 bool string values","caller":"api4/apitestlib.go:212","true":"TRUE","false":"f"}
{"timestamp":"2024-10-11 07:15:31.843 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 07:15:32.685 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"4gb6mdj3hid3pge4h59zdtbf4e@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:32.703 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"5ub49qnbobyfxbcpxyf9337x4h","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:32.716 Z","level":"debug","msg":"Fetching user count for first user account check","caller":"platform/config.go:356"}
{"timestamp":"2024-10-11 07:15:33.547 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"1xk1yj5oc3ra8mu5tagk4r9r5y@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:33.564 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"d3tnhuj3ffn17r83b9iecfzsxo","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:34.431 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"5mouwupoeifoieyxdc3j6kwq3c@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:34.450 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"44s1qmk76pr8uns5izjzwxx6wc","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:35.299 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"gtnk6wdyqfyspygym1ez9w3h3e@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:35.315 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"wrb3ua6q5jnqdbdpy3qc4w86ga","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:36.151 Z","level":"info","msg":"sending mail","caller":"mail/mail.go:295","to":"yj4xkex7hjbjidcrx15yd5gwqe@localhost","subject":"[Mattermost] You joined "}
{"timestamp":"2024-10-11 07:15:36.169 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users","request_id":"os1rn93p5pbdxrhenxsfdndzfr","user_id":"","status_code":"201"}
{"timestamp":"2024-10-11 07:15:37.005 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users/login","request_id":"nx3wxrs9w38hmraatiz35jyh8e","user_id":"9cjjzq15rtyw9mkcst5tec5two","status_code":"200"}
{"timestamp":"2024-10-11 07:15:37.008 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/users/login","request_id":"azmdub5fg7rtjfzc4rpowwfqoa","user_id":"if38oaniu3nk7fum3o5hckxmoo","status_code":"200"}
{"timestamp":"2024-10-11 07:15:37.009 Z","level":"info","msg":"Set license","caller":"platform/license.go:384","id":"","issued_at":"1970-01-01 00:00:00.000 Z","starts_at":"1970-01-01 00:00:00.000 Z","expires_at":"2025-01-09 07:15:37.009 Z","sku_name":"","sku_short_name":"","is_trial":false,"is_gov_sku":false,"customer_id":"some ID","features.users":0,"features":{"advanced_logging":true,"cloud":false,"cluster":true,"compliance":true,"custom_permissions_schemes":true,"data_retention":true,"elastic_search":true,"email_notification_contents":true,"enterprise_plugins":true,"future":true,"google":true,"guest_accounts":true,"guest_accounts_permissions":true,"id_loaded":true,"ldap":true,"ldap_groups":true,"lock_teammate_name_display":true,"message_export":true,"metrics":true,"mfa":true,"mhpns":true,"office365":true,"openid":true,"outgoing_oauth_connections":true,"remote_cluster_service":true,"saml":true,"shared_channels":true}}
{"timestamp":"2024-10-11 07:15:37.046 Z","level":"debug","msg":"Advanced logging config not provided for notification logging","caller":"platform/config.go:165"}
{"timestamp":"2024-10-11 07:15:37.056 Z","level":"debug","msg":"You do not have the appropriate permissions.","caller":"web/context.go:120","path":"/api/v4/ldap/sync","request_id":"u13uf5bwai87zkw8st3dbrakiw","ip_addr":"127.0.0.1","user_id":"if38oaniu3nk7fum3o5hckxmoo","method":"POST","err_where":"Permissions","http_code":403,"error":"Permissions: You do not have the appropriate permissions., userId=if38oaniu3nk7fum3o5hckxmoo, permission=create_ldap_sync_job"}
{"timestamp":"2024-10-11 07:15:37.056 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:185","method":"POST","url":"/api/v4/ldap/sync","request_id":"u13uf5bwai87zkw8st3dbrakiw","user_id":"if38oaniu3nk7fum3o5hckxmoo","status_code":"403"}
{"timestamp":"2024-10-11 07:15:37.057 Z","level":"info","msg":"Purging all caches","caller":"platform/cluster_handlers.go:114"}
{"timestamp":"2024-10-11 07:15:37.059 Z","level":"info","msg":"License key has not been uploaded. Loading license key from disk.","caller":"utils/license.go:107","filename":"/tmp/testlib1522937082/config/mattermost.mattermost-license"}
{"timestamp":"2024-10-11 07:15:37.059 Z","level":"warn","msg":"Failed to get license from disk","caller":"platform/license.go:93","error":"We could not find the license key on disk at /tmp/testlib1522937082/config/mattermost.mattermost-license: stat /tmp/testlib1522937082/config/mattermost.mattermost-license: no such file or directory"}
{"timestamp":"2024-10-11 07:15:37.060 Z","level":"warn","msg":"License key from https://mattermost.com required to unlock enterprise features.","caller":"platform/license.go:105","error":"resource \"License\" not found, id: "}
{"timestamp":"2024-10-11 07:15:37.060 Z","level":"info","msg":"Cleared license","caller":"platform/license.go:384","id":"","issued_at":"1970-01-01 00:00:00.000 Z","starts_at":"1970-01-01 00:00:00.000 Z","expires_at":"2025-01-09 07:15:37.009 Z","sku_name":"","sku_short_name":"","is_trial":false,"is_gov_sku":false,"customer_id":"some ID","features.users":0,"features":{"advanced_logging":true,"cloud":false,"cluster":true,"compliance":true,"custom_permissions_schemes":true,"data_retention":true,"elastic_search":true,"email_notification_contents":true,"enterprise_plugins":true,"future":true,"google":true,"guest_accounts":true,"guest_accounts_permissions":true,"id_loaded":true,"ldap":true,"ldap_groups":true,"lock_teammate_name_display":true,"message_export":true,"metrics":true,"mfa":true,"mhpns":true,"office365":true,"openid":true,"outgoing_oauth_connections":true,"remote_cluster_service":true,"saml":true,"shared_channels":true}}
{"timestamp":"2024-10-11 07:15:37.063 Z","level":"info","msg":"Stopping Server...","caller":"app/server.go:669"}
{"timestamp":"2024-10-11 07:15:37.083 Z","level":"info","msg":"Shutting down Email batching service...","caller":"email/service.go:85"}
{"timestamp":"2024-10-11 07:15:37.083 Z","level":"info","msg":"Shutting down plugins","caller":"app/plugin.go:362"}
{"timestamp":"2024-10-11 07:15:37.083 Z","level":"debug","msg":"Disabling plugin health check job","caller":"plugin/environment.go:670"}
{"timestamp":"2024-10-11 07:15:37.083 Z","level":"info","msg":"stopping websocket hub connections","caller":"platform/web_hub.go:127"}
{"timestamp":"2024-10-11 07:15:37.084 Z","level":"info","msg":"Server stopped","caller":"app/server.go:753"}
--- FAIL: TestSyncLdap (5.75s)