Skip to content

Commit 29ab438

Browse files
authored
Merge branch 'main' into jedrazb-fix-chicken-egg-problem-on-release
2 parents da50055 + 85078f8 commit 29ab438

File tree

4 files changed

+9
-4
lines changed

4 files changed

+9
-4
lines changed

Dockerfile.ftest.wolfi

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM docker.elastic.co/wolfi/python:3.11-dev@sha256:b70abdb46f6a1ed5057fb50018924eea03345044b5224c260a3d0334a748eb96
1+
FROM docker.elastic.co/wolfi/python:3.11-dev@sha256:62936d0d2db57c9bd195b31c1fcafff1413040ea94d37c88435487ebe041fb54
22
USER root
33
COPY . /connectors
44
WORKDIR /connectors

Dockerfile.wolfi

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM docker.elastic.co/wolfi/python:3.11-dev@sha256:b70abdb46f6a1ed5057fb50018924eea03345044b5224c260a3d0334a748eb96
1+
FROM docker.elastic.co/wolfi/python:3.11-dev@sha256:62936d0d2db57c9bd195b31c1fcafff1413040ea94d37c88435487ebe041fb54
22
USER root
33
COPY . /app
44
WORKDIR /app

connectors/sources/outlook.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
html_to_text,
4545
iso_utc,
4646
retryable,
47+
url_encode,
4748
)
4849

4950
RETRIES = 3
@@ -410,7 +411,8 @@ async def _fetch_token(self):
410411
)
411412
async def get_users(self):
412413
access_token = await self._fetch_token()
413-
url = f"https://graph.microsoft.com/v1.0/users?$top={TOP}"
414+
filter_ = url_encode("accountEnabled eq true")
415+
url = f"https://graph.microsoft.com/v1.0/users?$top={TOP}&$filter={filter_}"
414416
while True:
415417
try:
416418
async with self._get_session.get(

tests/sources/test_outlook.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -420,7 +420,10 @@ def side_effect_function(url, headers):
420420
Args:
421421
url, ssl: Params required for get call
422422
"""
423-
if url == "https://graph.microsoft.com/v1.0/users?$top=999":
423+
if (
424+
url
425+
== "https://graph.microsoft.com/v1.0/users?$top=999&$filter=accountEnabled%20eq%20true"
426+
):
424427
return get_json_mock(
425428
mock_response={
426429
"@odata.nextLink": "https://graph.microsoft.com/v1.0/users?$top=999&$skipToken=fake-skip-token",

0 commit comments

Comments
 (0)