OPCache bug
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 28/100
Direzione di ricerca
Inizia da src/RequestInformation.php alla riga 66 e confronta il suo utilizzo di PhpDoc con AnnotationReader.php di doctrine/annotations alla riga 122. Riproduci la richiesta GET dell'utente con opcache.save_comments impostato su 0, quindi determina se l'SDK può evitare il percorso di annotazione che causa l'errore o documentare chiaramente un workaround supportato.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Describe the bug
Hi,
I'm using your library for Microsoft SSO. I only need to fetch basic user information like: getId, getMail, getGivenName, getSurname, and getUserPrincipalName. I’m doing this with the following script:
However, the doctrine/annotations library recently fixed a bug that affects our integration: https://github.com/doctrine/annotations/pull/446/files
I’m using OPCache, so option opcache.save_comments with the flag value set as 0. So while you are using PhpDoc I'm getting error from: https://github.com/doctrine/annotations/blob/2.0.x/lib/Doctrine/Common/Annotations/AnnotationReader.php#L122
Expected behavior
The only place where PhpDoc data is read is here: https://github.com/microsoft/kiota-abstractions-php/blob/main/src/RequestInformation.php#L66 - and microsoft/kiota-abstractions-php is a dependency of microsoftgraph/msgraph-sdk-php-core.
The dependency chain is quite large, but it seems that in my case, I don’t have any query parameters - and those are likely required for this issue to occur.
How can I work around this problem, aside from enabling comments in the cache?
How to reproduce
Set option opcache.save_comments with the flag value as 0
$tokenRequestContext = new AuthorizationCodeContext(
tenantId: $config['tenant'],
clientId: $config['clientId'],
clientSecret: $config['clientSecret'],
authCode: $params[self::PARAM_IN_CODE],
redirectUri: $config['redirectUri'],
);
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $config['scopes']);
$user = $graphServiceClient->me()->get()->wait();
$userData = [
'id' => $user->getId(),
'userPrincipalName' => $user->getUserPrincipalName(),
'userEmail' => $user->getMail(),
'userFirstName' => $user->getGivenName(),
'userLastName' => $user->getSurname(),
];
// ...
SDK Version
2.25.0
Latest version known to work for scenario above?
No response
Known Workarounds
No response
Debug output
Click to expand log
```</details>
### Configuration
_No response_
### Other information
_No response_
- Lingua principale
- PHP
- Stelle
- 669
- Fork
- 150
- Merge medio
- 15h 21m
- PR unite (30g)
- 3
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di microsoftgraph/msgraph-sdk-php
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
microsoftgraph/msgraph-sdk-php#1794 · 2 commenti ·
-
bug: metadata type:bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
microsoftgraph/msgraph-sdk-php#1739 · 6 commenti ·
-
status:waiting-for-triage type:bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 68/100
microsoftgraph/msgraph-sdk-php#1643 · 8 commenti · 4 reazioni ·
-
status:waiting-for-triage
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
microsoftgraph/msgraph-sdk-php#1800 · 1 reazione ·
-
Now Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 1/100
microsoftgraph/msgraph-sdk-php#1799 ·
Tutte le issue di microsoftgraph/msgraph-sdk-php
Issue simili
-
sync-en
Difficoltà 1/5 1-3 ore Idoneità per principianti 85/100
-
[6.x]: "Cannot use object of type stdClass as array" loading Users index (regression of #19182) Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
getgrav/grav-plugin-api#45 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
RSS-Bridge/rss-bridge#5098 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
phingofficial/phing#2025 ·