-
Notifications
You must be signed in to change notification settings - Fork 10.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support destinations in NameTrees with encoded keys (issue 14847) #14848
Conversation
Initially I considered updating the `NameOrNumberTree`-implementation to handle encoded keys, however that quickly became somewhat messy (especially in the `NameOrNumberTree.get`-method) since only NameTrees using string-keys. Hence the easiest solution, as far as I'm concerned, was thus to just update the `Catalog.destinations`-getter instead. Please note that in the referenced PDF document the `Catalog.destination`-method will thus fallback to fetch all destinations, which should be fine since this is the very first case of encoded keys that we've seen. Also changes the `NameOrNumberTree.getAll`-method to prevent a possible run-time error, although we've so far not seen such a case, for any non-Array Kids-entries found in a NameTree/NumberTree. Finally, to improve overall consistency and to hopefully prevent future bugs, the patch also updates a couple of other `NameTree` call-sites to correctly handle encoded keys. (Note that the `Catalog.attachments`-getter was already doing this.)
19e0907
to
71370d0
Compare
/botio test |
From: Bot.io (Linux m4)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.241.84.105:8877/5f3fdfd2c4b79bf/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.193.163.58:8877/26a62102389ec84/output.txt |
From: Bot.io (Linux m4)FailedFull output at http://54.241.84.105:8877/5f3fdfd2c4b79bf/output.txt Total script time: 24.87 mins
Image differences available at: http://54.241.84.105:8877/5f3fdfd2c4b79bf/reftest-analyzer.html#web=eq.log |
From: Bot.io (Windows)SuccessFull output at http://54.193.163.58:8877/26a62102389ec84/output.txt Total script time: 26.42 mins
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Initially I considered updating the
NameOrNumberTree
-implementation to handle encoded keys, however that quickly became somewhat messy (especially in theNameOrNumberTree.get
-method) since only NameTrees using string-keys.Hence the easiest solution, as far as I'm concerned, was thus to just update the
Catalog.destinations
-getter instead. Please note that in the referenced PDF document theCatalog.destination
-method will thus fallback to fetch all destinations, which should be fine since this is the very first case of encoded keys that we've seen.Also changes the
NameOrNumberTree.getAll
-method to prevent a possible run-time error, although we've so far not seen such a case, for any non-Array Kids-entries found in a NameTree/NumberTree.Finally, to improve overall consistency and to hopefully prevent future bugs, the patch also updates a couple of other
NameTree
call-sites to correctly handle encoded keys. (Note that theCatalog.attachments
-getter was already doing this.)