{"action":"created","issue":{"url":"https://api.github.com/repos/dotnet/corefx/issues/28501","repository_url":"https://api.github.com/repos/dotnet/corefx","labels_url":"https://api.github.com/repos/dotnet/corefx/issues/28501/labels{/name}","comments_url":"https://api.github.com/repos/dotnet/corefx/issues/28501/comments","events_url":"https://api.github.com/repos/dotnet/corefx/issues/28501/events","html_url":"https://github.com/dotnet/corefx/issues/28501","id":308855758,"node_id":"MDU6SXNzdWUzMDg4NTU3NTg=","number":28501,"title":"EmailAddressAttribute behaves differently in .NET Core vs. NetFx","user":{"login":"Tornhoof","id":7989549,"node_id":"MDQ6VXNlcjc5ODk1NDk=","avatar_url":"https://avatars1.githubusercontent.com/u/7989549?v=4","gravatar_id":"","url":"https://api.github.com/users/Tornhoof","html_url":"https://github.com/Tornhoof","followers_url":"https://api.github.com/users/Tornhoof/followers","following_url":"https://api.github.com/users/Tornhoof/following{/other_user}","gists_url":"https://api.github.com/users/Tornhoof/gists{/gist_id}","starred_url":"https://api.github.com/users/Tornhoof/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Tornhoof/subscriptions","organizations_url":"https://api.github.com/users/Tornhoof/orgs","repos_url":"https://api.github.com/users/Tornhoof/repos","events_url":"https://api.github.com/users/Tornhoof/events{/privacy}","received_events_url":"https://api.github.com/users/Tornhoof/received_events","type":"User","site_admin":false},"labels":[{"id":365147639,"node_id":"MDU6TGFiZWwzNjUxNDc2Mzk=","url":"https://api.github.com/repos/dotnet/corefx/labels/area-System.ComponentModel.DataAnnotations","name":"area-System.ComponentModel.DataAnnotations","color":"d4c5f9","default":false},{"id":145399955,"node_id":"MDU6TGFiZWwxNDUzOTk5NTU=","url":"https://api.github.com/repos/dotnet/corefx/labels/bug","name":"bug","color":"207de5","default":true},{"id":181727851,"node_id":"MDU6TGFiZWwxODE3Mjc4NTE=","url":"https://api.github.com/repos/dotnet/corefx/labels/tenet-compatibility","name":"tenet-compatibility","color":"c2e0c6","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/dotnet/corefx/milestones/5","html_url":"https://github.com/dotnet/corefx/milestone/5","labels_url":"https://api.github.com/repos/dotnet/corefx/milestones/5/labels","id":1328080,"node_id":"MDk6TWlsZXN0b25lMTMyODA4MA==","number":5,"title":"Future","description":"Milestone tracking issues not triaged to a planned release. Work in this milestone may happen, or may not: it is not committed.","creator":{"login":"joshfree","id":1302850,"node_id":"MDQ6VXNlcjEzMDI4NTA=","avatar_url":"https://avatars1.githubusercontent.com/u/1302850?v=4","gravatar_id":"","url":"https://api.github.com/users/joshfree","html_url":"https://github.com/joshfree","followers_url":"https://api.github.com/users/joshfree/followers","following_url":"https://api.github.com/users/joshfree/following{/other_user}","gists_url":"https://api.github.com/users/joshfree/gists{/gist_id}","starred_url":"https://api.github.com/users/joshfree/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joshfree/subscriptions","organizations_url":"https://api.github.com/users/joshfree/orgs","repos_url":"https://api.github.com/users/joshfree/repos","events_url":"https://api.github.com/users/joshfree/events{/privacy}","received_events_url":"https://api.github.com/users/joshfree/received_events","type":"User","site_admin":false},"open_issues":1919,"closed_issues":207,"state":"open","created_at":"2015-09-29T00:25:45Z","updated_at":"2018-06-25T14:52:41Z","due_on":null,"closed_at":null},"comments":12,"created_at":"2018-03-27T07:44:03Z","updated_at":"2018-06-25T16:23:47Z","closed_at":null,"author_association":"NONE","body":"It behaves differently for the following Unit Tests and I think both behaviours are not 100% correct:\r\nJust for reference:\r\nhttps://msdn.microsoft.com/en-us/library/system.componentmodel.dataannotations.emailaddressattribute(v=vs.110).aspx\r\n\r\n```csharp\r\npublic class UnitTest1\r\n{\r\n    private static EmailAddressAttribute AddressAttribute = new EmailAddressAttribute();\r\n\r\n    [Theory]\r\n    [InlineData(\"test@test.com\", true)]\r\n    [InlineData(\"test@test.co.uk\", true)]\r\n    [InlineData(\"test+t@test.co.uk\", true)]\r\n    [InlineData(\"test\", false)]\r\n    [InlineData(\"test.com\", false)]\r\n    [InlineData(\"test@test\", false)]\r\n    [InlineData(\"test@test.\", false)]\r\n    public void EmailValidity(string email, bool result)\r\n    {\r\n        Assert.Equal(result, AddressAttribute.IsValid(email));\r\n    }\r\n}\r\n```\r\nIn NetFX 4.7 all tests succeed.\r\nIn NetCore 1.0/2.0 the tests for \"test@test\" and \"test@test.\" fail.\r\n\r\nIn #25129 @PeterSmithRedmond said that atleast test@test is a valid email, but as far as i understand the spec test@test.  (notice the dot) is not, the domain part is called dot-atom in the spec https://tools.ietf.org/html/rfc2822#section-3.2.4 and has either no dot or dot and other valid symbols after the dot.\r\n\r\nIf I'm correct there are bugs in both implementations, in netfx the test for \"test@test\" should fail (because it's a valid address) and in net core the test for \"test@test.\" should succeed, because it's not a valid address.\r\n\r\nRepro:\r\n\r\n[EmailAddressAttributeRepro.zip](https://github.com/dotnet/corefx/files/1850894/EmailAddressAttributeRepro.zip)\r\n\r\nJust run it with the different test frameworks."},"comment":{"url":"https://api.github.com/repos/dotnet/corefx/issues/comments/400011896","html_url":"https://github.com/dotnet/corefx/issues/28501#issuecomment-400011896","issue_url":"https://api.github.com/repos/dotnet/corefx/issues/28501","id":400011896,"node_id":"MDEyOklzc3VlQ29tbWVudDQwMDAxMTg5Ng==","user":{"login":"lukos","id":581018,"node_id":"MDQ6VXNlcjU4MTAxOA==","avatar_url":"https://avatars1.githubusercontent.com/u/581018?v=4","gravatar_id":"","url":"https://api.github.com/users/lukos","html_url":"https://github.com/lukos","followers_url":"https://api.github.com/users/lukos/followers","following_url":"https://api.github.com/users/lukos/following{/other_user}","gists_url":"https://api.github.com/users/lukos/gists{/gist_id}","starred_url":"https://api.github.com/users/lukos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lukos/subscriptions","organizations_url":"https://api.github.com/users/lukos/orgs","repos_url":"https://api.github.com/users/lukos/repos","events_url":"https://api.github.com/users/lukos/events{/privacy}","received_events_url":"https://api.github.com/users/lukos/received_events","type":"User","site_admin":false},"created_at":"2018-06-25T16:23:47Z","updated_at":"2018-06-25T16:23:47Z","author_association":"NONE","body":"Two examples:\r\n\r\n.something@example.com\r\nsomething.@example.com\r\n\r\nI believe both should fail validation and neither do. These are also reasonable typing errors to make."}}
{"actor":{"display_login":"lukos"}}