-
Notifications
You must be signed in to change notification settings - Fork 451
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
Moving to EventGrid extension version 1.0.0 + fix flaky test #3143
Conversation
@@ -120,7 +120,7 @@ | |||
<HintPath>..\..\packages\Microsoft.Azure.WebJobs.Extensions.DocumentDB.1.3.0-beta1-10632\lib\net45\Microsoft.Azure.WebJobs.Extensions.DocumentDB.dll</HintPath> | |||
</Reference> | |||
<Reference Include="Microsoft.Azure.WebJobs.Extensions.EventGrid, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL"> | |||
<HintPath>..\..\packages\Microsoft.Azure.WebJobs.Extensions.EventGrid.1.0.0-10036\lib\net46\Microsoft.Azure.WebJobs.Extensions.EventGrid.dll</HintPath> |
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.
Nuget flags 1.0.0-10036 as an invalid package version (nuget pack issue), causing all VS builds to fail on all of my dev machines (failing to compile the Packages project). We don't have an actual product issue since apparently this doesn't repro on AppVeyor.
Confirmed with @watashiSHUN that 1.0.0 is the same bits as this version so this is safe to do. Going forward, he's going to fix this versioning scheme.
15dea7a
to
f613e86
Compare
@@ -0,0 +1,6 @@ | |||
<?xml version="1.0" encoding="utf-8"?> |
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.
Added this missing packages file while trying to fix the build errors. You get warnings/errors without it.
@@ -1550,10 +1550,6 @@ internal static void ApplyConfiguration(JObject config, ScriptHostConfiguration | |||
scriptConfig.Functions.Add((string)function); | |||
} | |||
} | |||
else | |||
{ | |||
scriptConfig.Functions = null; |
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.
The test was flaking out because while it was specifying a functions whitelist, the whitelist wasn't actually being applied. There were then 4 functions running, and from time to time the queue function might get a message and timeout as well, leading to the flakiness. The test was verifying only a single timeout exception and there were multiple occurring.
Not sure why this else branch was here anyways - note that in other cases below, we only apply/override imperative settings if the json has a value.
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.
ApplyConfiguration_ClearsFunctionsFilter test failed in the PR build. Please take a look.
@@ -149,6 +144,7 @@ private MockExceptionHandler GetExceptionHandler(ScriptHostManager manager) | |||
|
|||
private async Task<MockScriptHostManager> CreateAndStartScriptHostManager(string scriptLang, string functionName, TimeSpan timeout, TraceWriter traceWriter) | |||
{ | |||
// filter down to a single function |
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.
Before my fix, I verified in the debugger that this whitelist was being ignored
}); | ||
|
||
// verify that our mock handler received the timeout exception |
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.
This .Single() is what was throwing, because there were multiple timeouts in rare cases
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.
👍
@@ -1550,10 +1550,6 @@ internal static void ApplyConfiguration(JObject config, ScriptHostConfiguration | |||
scriptConfig.Functions.Add((string)function); | |||
} | |||
} | |||
else | |||
{ | |||
scriptConfig.Functions = null; |
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.
ApplyConfiguration_ClearsFunctionsFilter test failed in the PR build. Please take a look.
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.
Thanks, @mathewc !
Changes look good. @pragnagopa pointed out that you had a failing test, but looks like you've sent an update so. This LGTM, so let's get it in once you're green.
Fix for https://ci.appveyor.com/project/appsvc/azure-webjobs-sdk-script-y8o14/build/20180712-0606/tests