Commit 5c2a9c5
fix(audience): treat missing queue dir as empty queue in ReadBatch (SDK-341)
- DiskStore.ReadBatch was the one path that called
Directory.GetFiles(_queueDir) without the DirectoryNotFoundException
guard the rest of the methods (DeleteAll, ApplyAnonymousDowngrade,
TryDelete) already use.
- Linux Mono / IL2CPP test cells run a SetUp that deletes the SDK
persistent dir between every test. A background flush timer started
by the prior test can fire after the delete; the resulting GetFiles
raised DirectoryNotFoundException which propagated through
HttpTransport.SendBatchAsync to OnError, made the SampleApp log
"flush() Err" instead of "flush() Ok", and failed the test.
- Same shape was hitting Shutdown's flush path: the AggregateException
the caller saw was wrapping the same DirectoryNotFoundException.
- Catch + return Array.Empty<string>(). Empty result is the correct
semantics: a deleted queue dir has no events to send.
Surfaced by run 25539153233 once SDK-317 (PR #754) landed real Linux
PlayMode coverage. Affected 9 cells (2 Mono, 7 IL2CPP) on Unity 6.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 54cbf4a commit 5c2a9c5
1 file changed
Lines changed: 12 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
68 | | - | |
69 | | - | |
70 | | - | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
71 | 80 | | |
72 | 81 | | |
73 | 82 | | |
| |||
0 commit comments