Skip to content
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

Add the key in the message on throwing a KeyNotFoundException #282

Merged
merged 2 commits into from Aug 9, 2016
Merged

Add the key in the message on throwing a KeyNotFoundException #282

merged 2 commits into from Aug 9, 2016

Conversation

rogihee
Copy link
Contributor

@rogihee rogihee commented Aug 5, 2016

Description of Change

Add the key in the message on throwing a KeyNotFoundException for trying to access an invalid key in the ResourceDictionary. This helps in tracking down what resource is actually missing.

Bugs Fixed

None

API Changes

None

Behavioral Changes

None

PR Checklist

  • Has tests (if omitted, state reason in description)
  • Rebased on top of master at time of PR
  • Changes adhere to coding standard
  • Consolidate commits as makes sense

…ing to access an invalid key in the ResourceDictionary. This helps a lot in tracking down what resource is actually missing.

…ing to access an invalid key in the ResourceDictionary. This helps a lot in tracking down what resource is actually missing.
@dnfclas
Copy link

dnfclas commented Aug 5, 2016

Hi @rogihee, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!

In order for us to evaluate and accept your PR, we ask that you sign a contribution license agreement. It's all electronic and will take just minutes. I promise there's no faxing. https://cla2.dotnetfoundation.org.

TTYL, DNFBOT;

@dnfclas
Copy link

dnfclas commented Aug 5, 2016

@rogihee, Thanks for signing the contribution license agreement so quickly! Actual humans will now validate the agreement and then evaluate the PR.

Thanks, DNFBOT;

@@ -98,7 +98,7 @@ public bool ContainsKey(string key)
return _innerDictionary[index];
if (_mergedInstance != null && _mergedInstance.ContainsKey(index))
return _mergedInstance[index];
throw new KeyNotFoundException();
throw new KeyNotFoundException("The resource '" + index + "' is not present in the dictionary.");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Better if we used c# 6 features but ok not problem.

@rmarinho
Copy link
Member

rmarinho commented Aug 5, 2016

👍

@@ -253,4 +253,13 @@ public void MultiLevelMerge ()
Assert.Fail ();
}
}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add the unit test inside the test class. It won't compile otherwise. :) 👎 until fixed (to prevent merge)

@ahmedalejo
Copy link

Awesome thanks, this will surely reduce my chances of becoming bald. what
an headache this gave me.

Key
On Fri, 5 Aug 2016 at 07:32 Rui Marinho notifications@github.com wrote:

👍


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#282 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AGr-6l8xH6Sz3BE923tVZFmz8yp5EL9qks5qcxFTgaJpZM4JdeCV
.

@rogihee
Copy link
Contributor Author

rogihee commented Aug 7, 2016

I fixed the test build dunno, what happened there..Also used the C# 6 string interpolation.

@rmarinho rmarinho merged commit 43e90a3 into xamarin:master Aug 9, 2016
@samhouts samhouts added this to the 2.3.3 milestone Jun 27, 2018
mattleibow pushed a commit that referenced this pull request Jan 28, 2021
* GH-221: Add iOS SecAccessible properties (#223)

* Address #221, use AfterFirstUnlockThisDeviceOnly to match other platforms. Although allow a platform specific override to set accessible state.

* Add tests

* Added iOS specific prop to set SecAccessible

* Default to AfterFirstUnlock on iOS SecureStorage

* A few fixes for the release. (#228)

* Setting the correct flags for Chrome Tabs. Fixes #225

* Make sure that there is data to decrypt before starting. Fixes #226

* Fixes for TTS. Fixes #227

* A bit of the fixes for emails on iOS. Relates to #224

* Update the email bit for iOS #224

* Cleaning up the code #224

* Make sure to set the email properties. Fixes #229

* Update SDK Extras

This fixes a lot of references that were required on android that aren't.

* Update Readme with Installation information. (#237)

* Update Readme with Installation information.

* Update README.md

* Update README.md

* Adding the initial work to get Tizen started. #23

* Revert "Adding the initial work to get Tizen started. #23"

This reverts commit 58b6041.

* Update the docs with the latest APIs (#233)

Add docs for SecAccessible

* GH-245: Add Orientation Sensor (#249)

* Add Orientation Sensor

* Add Orientation Sensor

* Remove .csproj clutter

* "orientationsensor" --> "orientation sensor" or just "orientation"

* GH-192: Added DateTime to Preferences (#232)

* Added DateTime to preferences. Fixes #192
 - also properly using overloads

* Added some unit tests

* Added the docs for the new Preferences APIs

* Update Readme with Device Display Information

Added link to Current Features for Device Display Information

* Fixes #258 and Fixes #255 (#259)

* Fixes #258
* put vectors nuget everywhere.
* NuGet is broken - https://developercommunity.visualstudio.com/content/problem/232996/warning-nu1603-runtimenativesystemiocompression-41.html
* The NuGet doesn't add the assembly references from the GAC
* We need to use a later version of the iOS SDK

* Fix typo (#274)

* Fix up null checks when getting lask known location.

* Additional Null checks

* GH-240 Add IsMainThread detection API (#277)

* Add IsMainThread detection API

* Add platform tests for main thread

* Update docs and add more platform tests

* iOS secure storage simulator tests (#247) (#278)

* iOS secure storage simulator tests (#247)

* Remove line that skips test on virtual devices

* Adding keychain-access-groups in Entitlements.plist

* Setting CodeSign entitlements for Debug configuration

* Making same entitlement.plist changes for iOS sample

* Removing specific code sign key

* Removing physical device trait for iOS SecureStorageTests

* Update DeviceTests.iOS.csproj

* Update Samples.iOS.csproj

* Add configs for codesign on release

* Fixes #181 Allowing setting of calibration for heading. (#282)

* GH-254 Update Support Packages, Forms, and Reference Vectors (#279)

* Update Support Packages, Forms, and Reference Vectors

* Bump targetsdk

* Fix android build :)

* Fix build
rmarinho pushed a commit that referenced this pull request Mar 3, 2021
I think the asterisk belongs to the windows implementation not the MacOS implementation

Co-authored-by: David Ortinau <david.ortinau@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants