microsoftgraph / microsoftgraph/msgraph-sdk-java
Site `search` query parameter is inconsistent between SDK and Graph Explorer
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Java
- Sterne
- 444
- Forks
- 154
- Ø Merge
- 18 Std. 28 Min.
- Gemergte PRs (30 T.)
- 4
Beschreibung
Describe the bug
When using Graph Explorer, the API endpoint https://graph.microsoft.com/v1.0/sites returns nothing.
With Graph Explorer, it appears that using ?search=* works to return all sites.
When using the SDK, the same endpoint returns sites, and specifying queryParameters.search = "*" throws:
Syntax error: character '*' is not valid at position 0 in '*'.
com.microsoft.graph.models.odataerrors.ODataError: Syntax error: character '*' is not valid at position 0 in '*'.
based on the response:
{
"error": {
"code": "BadRequest",
"message": "Syntax error: character '*' is not valid at position 0 in '*'.",
"innerError": {
"date": "2025-03-31T18:56:12",
"request-id": "f29db1f9-b0d7-4d4b-a724-7599a932bcca",
"client-request-id": "fb1f170c-a4c0-4eb6-bb8c-852e3d3c7762"
}
}
}
These inconsistencies (along with issues like #2344 and #2345 ) make it very difficult to sanely develop applications using the MS Graph SDK.
One difference is that I am using client cert / secret credentials for the SDK and personal credentials for Explorer. That should not affect the API's functional behavior though.
Expected behavior
APIs should have consistent behavior.
How to reproduce
See above.
SDK Version
6.33.0
Latest version known to work for scenario above?
No response
Known Workarounds
Pull out hair, write code with many "argh" comments, and proceed
Debug output
No response
Configuration
No response
Other information
No response
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne damit, die /v1.0/sites-Anfragen in Graph Explorer und mit der SDK-Version 6.33.0 zu reproduzieren, und vergleiche dabei die Anmeldedaten und die serialisierte Suchabfrage. Verfolge, ob die Abweichung in der Java SDK-Anfrage oder im Verhalten der Graph API liegt; abgeschlossen ist die Untersuchung, wenn die verantwortliche Komponente sowie ein konsistentes Verhalten oder eine dokumentierte Einschränkung festgestellt wurden.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- java
- Bereich
- api
- Issue-Typ
- Bug
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Muss geklärt werden
- Anfängerfreundlichkeit
- 25/100