question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Requires.NotEmpty(Guid)

See original GitHub issue

The Requires.NotEmpty(Guid) method here was replaced with Requires.NotDefault, which creates an inconsistency with Microsoft.VisualStudio.Validation. Should we update that repo to match? This is tangentially related to #38.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
AArnottcommented, Sep 28, 2020

and have NotEmpty(Guid) be removed

That’s never going to happen. vs-validation is used in many Microsoft components and thus has a high backward compat obligation. I don’t mind copying NotDefault<T> from here to vs-validation, but that’s probably all I’d want to do.

0reactions
AArnottcommented, Oct 2, 2020

Let’s leave NotEmpty(Guid) alone. It’s in vs-validation and we won’t be obsoleting it there.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Requires.NotEmpty(Guid, String) Method
Throws an exception if the specified parameter's value is Empty. C++. Copy. public: static void NotEmpty(Guid value, System::String ^ parameterName);
Read more >
Creating a not-empty GUID validation attribute and a not- ...
In this post I described a [NotEmpty] validation attribute that can be used to detect when a Guid property on a model is...
Read more >
c# - Validation of Guid
Empty, which will satisfy the requirements of the Required attribute. Now that being said, it is possible to get what you want you...
Read more >
I Have a Problem with Empty GUIDs! | by Hasangi Kahaduwa
GUID stands for Global Unique Identifier. Whenever an unique identifier is required this, 128-bit integer (16 bytes) could be used.
Read more >
Why NotEmpty() does not check if value for Guid type is ...
Hello, I'm a bit confused. Why NotEmpty() rule does not check if Guid argument is equal to default(Guid) and return that it's not...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found