VSTS - Deploy Test Agent fails - unable to connect to TFS after deploying test agenet?

Using VSTS,
account name -https://dbsanz.visualstudio.com
team project name - AgileMcWms
build number: 171

Agent - Private:
Current agent version: '2.123.0'
OS : win server 2012 r2

Issue Description
Ok, I am using the same machine to build/deploy and run unit tests and then selenium tests
After all passed, selenium tests run
So it can download the agent at C/TestAgent but then throws the error - not able to connect to TFS.
I have checked the winrm on port 5985 And Enable-PSRemoting –Force .. they all good

_PS C:\Windows\system32> winrm e winrm/config/listener
Listener
Address = *
Transport = HTTP
Port = 5985
Hostname
Enabled = true
URLPrefix = wsman
CertificateThumbprint
ListeningOn = <IP_ADDRESS>, <IP_ADDRESS>, ::1, fe80::5efe:<IP_ADDRESS>%13
PS C:\Windows\system32> Enable-PSRemoting -Force
WinRM is already set up to receive requests on this computer.
WinRM is already set up for remote management on this computer._

Then I switched and tried my local laptop to run the tests and all good.
Can you please have a look at the below error log and let me know what I am missing?
User details used to deploy agent and run test has the admin access on the server
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2017-11-16T04:14:18.0976801Z ##[section]Starting: Deploy TestAgent on
2017-11-16T04:14:18.1445411Z ==============================================================================
2017-11-16T04:14:18.1445411Z Task         : Visual Studio Test Agent Deployment
2017-11-16T04:14:18.1445411Z Description  : Deploy and configure Test Agent to run tests on a set of machines
2017-11-16T04:14:18.1445411Z Version      : 2.1.33
2017-11-16T04:14:18.1445411Z Author       : Microsoft Corporation
2017-11-16T04:14:18.1445411Z Help         : More Information
2017-11-16T04:14:18.1445411Z ==============================================================================
2017-11-16T04:14:20.5820393Z ****************************************************************
2017-11-16T04:14:20.5820393Z                     Task Input Information
2017-11-16T04:14:20.5820393Z ----------------------------------------------------------------
2017-11-16T04:14:20.5820393Z testMachineInput         = buildservername.schenker.int.au
2017-11-16T04:14:20.5820393Z adminUserName            = domain\userid
2017-11-16T04:14:20.5820393Z winRmProtocal            = Http
2017-11-16T04:14:20.5820393Z testCertificate          = true
2017-11-16T04:14:20.5820393Z machineUserName          = domain\userid
2017-11-16T04:14:20.5820393Z runAsProcess             = true
2017-11-16T04:14:20.5820393Z logonAutomatically       = true
2017-11-16T04:14:20.5820393Z disableScreenSaver       = true
2017-11-16T04:14:20.5820393Z isDataCollectionOnly     = false
2017-11-16T04:14:20.5820393Z testPlatform             = 15.0
2017-11-16T04:14:20.5820393Z agentLocation            =
2017-11-16T04:14:20.5820393Z updateTestAgent          = false
2017-11-16T04:14:20.5820393Z ****************************************************************
2017-11-16T04:14:21.3166046Z Starting to deploy and configure test agent on test machines.
2017-11-16T04:14:21.3320741Z Inputs provided are:
2017-11-16T04:14:21.3320741Z Use HTTP Port: True
2017-11-16T04:14:21.3320741Z Username: domain\userid
2017-11-16T04:14:21.3320741Z Disable Screen saver: True
2017-11-16T04:14:21.3320741Z Login Automatically: True
2017-11-16T04:14:21.3320741Z Run as process: True
2017-11-16T04:14:21.3320741Z Agent would be downloaded from https://go.microsoft.com/fwlink/?LinkId=615472
2017-11-16T04:14:21.3320741Z Update test agent: False
2017-11-16T04:14:21.3320741Z Run test agent as DataCollection only : False
2017-11-16T04:14:21.8789083Z Task 'VerifyTestAgentInstalled' on machine 'buildservername.schenker.int.au:5985' is being run
2017-11-16T04:14:28.7851777Z 	 Deployment started on target machine...
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z Query for Testplatfrom version: 15.0
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z Testing container: 'REGISTRY::HKEY_CLASSES_ROOT\CLSID{177F0C4A-1CD3-4DE7-A32C-71DBBB9FA36D}'
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z Exists.
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z Getting Visual Studio setup instances.
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z Found 1 instances.
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z Description   : Free, fully-featured IDE for students, open-source and individual developers
2017-11-16T04:14:28.7851777Z DisplayName   : Visual Studio Community 2017
2017-11-16T04:14:28.7851777Z Id            : ee6d2d29
2017-11-16T04:14:28.7851777Z InstallDate   : System.Runtime.InteropServices.ComTypes.FILETIME
2017-11-16T04:14:28.7851777Z Name          : VisualStudio/15.4.0+27004.2002
2017-11-16T04:14:28.7851777Z Path          : C:\Program Files (x86)\Microsoft Visual Studio\2017\Community
2017-11-16T04:14:28.7851777Z Version       : 15.4.27004.2002
2017-11-16T04:14:28.7851777Z VersionString : 15.4.27004.2002
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z Test Agent already exists
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z Version: 15.4.27004.2002
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z DTAAgentExecutionService is not present on the machine
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z DTAExecutionHost is not running
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z RemoteDeployerSource Verbose: 2 : [RemoteDeployer]16:Nov:17:15:14:24:1445; 4844, 4Created public key for communication
2017-11-16T04:14:28.7851777Z RemoteDeployerSource Information: 12 : [RemoteDeployer]16:Nov:17:15:14:24:1601; 4844, 4Deployment service - VisualStudioRemoteDeployerb5284dea-55d0-4501-b53d-b190aaa37141 is running...
2017-11-16T04:14:28.7851777Z RemoteDeployerSource Verbose: 4 : [RemoteDeployer]16:Nov:17:15:14:25:2070; 4844, 6Input file found
2017-11-16T04:14:28.7851777Z RemoteDeployerSource Verbose: 5 : [RemoteDeployer]16:Nov:17:15:14:25:2070; 4844, 6Reading input parameters
2017-11-16T04:14:28.7851777Z RemoteDeployerSource Verbose: 6 : [RemoteDeployer]16:Nov:17:15:14:25:2070; 4844, 6Finished reading input parameters
2017-11-16T04:14:28.7851777Z
2017-11-16T04:14:28.7851777Z Task 'VerifyTestAgentInstalled' on machine 'buildservername.schenker.int.au:5985' completed.
2017-11-16T04:14:29.7070520Z Task 'CopyFilesToTestAgent' on machine 'buildservername.schenker.int.au:5985' is being run
2017-11-16T04:14:30.1758054Z Task 'CopyFilesToTestAgent' on machine 'buildservername.schenker.int.au:5985' completed.
2017-11-16T04:14:30.1758054Z
2017-11-16T04:14:30.1758054Z \buildservername.schenker.int.au was deleted successfully.
2017-11-16T04:14:30.1758054Z
2017-11-16T04:14:30.1758054Z Copying recursively from E:\McWmsBuildAgent_work_tasks\DeployVisualStudioTestAgent_52a38a6a-1517-41d7-96cc-73ee0c60d2b6\2.1.33\TestExecution.zip to C:\TestAgent on machine buildservername.schenker.int.au succeeded.
2017-11-16T04:14:30.1758054Z
2017-11-16T04:14:30.1758054Z \buildservername.schenker.int.au was deleted successfully.
2017-11-16T04:14:30.1758054Z
2017-11-16T04:14:30.1758054Z
2017-11-16T04:15:30.1759688Z Task 'SetupTestMachineForUiTests' on machine 'buildservername.schenker.int.au:5985' is being run
2017-11-16T04:15:37.7384510Z 	 Deployment started on target machine...
2017-11-16T04:15:37.7384510Z
2017-11-16T04:15:37.7384510Z Test User userid
2017-11-16T04:15:37.7384510Z
2017-11-16T04:15:37.7384510Z Test UserDomain DomainName
2017-11-16T04:15:37.7384510Z
2017-11-16T04:15:37.7384510Z Executing command : powercfg.exe /Change monitor-timeout-ac 0 ; powercfg.exe /Change monitor-timeout-dc 0
2017-11-16T04:15:37.7384510Z
2017-11-16T04:15:37.7384510Z Error :
2017-11-16T04:15:37.7384510Z
2017-11-16T04:15:37.7384510Z Output :
2017-11-16T04:15:37.7384510Z
2017-11-16T04:15:37.7384510Z Configuration for UI testing is completed
2017-11-16T04:15:37.7384510Z
2017-11-16T04:15:37.7384510Z
2017-11-16T04:15:37.7384510Z RemoteDeployerSource Verbose: 2 : [RemoteDeployer]16:Nov:17:15:15:32:2384; 1284, 4Created public key for communication
2017-11-16T04:15:37.7384510Z RemoteDeployerSource Information: 12 : [RemoteDeployer]16:Nov:17:15:15:32:2540; 1284, 4Deployment service - VisualStudioRemoteDeployer313d6d38-cec9-4625-adc1-758685d3d105 is running...
2017-11-16T04:15:37.7384510Z RemoteDeployerSource Verbose: 4 : [RemoteDeployer]16:Nov:17:15:15:33:2853; 1284, 6Input file found
2017-11-16T04:15:37.7384510Z RemoteDeployerSource Verbose: 5 : [RemoteDeployer]16:Nov:17:15:15:33:2853; 1284, 6Reading input parameters
2017-11-16T04:15:37.7384510Z RemoteDeployerSource Verbose: 6 : [RemoteDeployer]16:Nov:17:15:15:33:2853; 1284, 6Finished reading input parameters
2017-11-16T04:15:37.7384510Z
2017-11-16T04:15:37.7384510Z Task 'SetupTestMachineForUiTests' on machine 'buildservername.schenker.int.au:5985' completed.
2017-11-16T04:15:37.7696944Z Task 'TestAgentConfiguration' on machine 'buildservername.schenker.int.au:5985' is being run
2017-11-16T04:16:37.7542166Z Task 'TestAgentConfiguration' on machine 'buildservername.schenker.int.au:5985' is taking time. Please Wait
2017-11-16T04:17:37.7543521Z Task 'TestAgentConfiguration' on machine 'buildservername.schenker.int.au:5985' is taking time. Please Wait
2017-11-16T04:17:55.8481226Z RemoteDeployerSource Verbose: 2 : [RemoteDeployer]16:Nov:17:15:15:39:6915; 3200, 4Created public key for communication
2017-11-16T04:17:55.8481226Z RemoteDeployerSource Information: 12 : [RemoteDeployer]16:Nov:17:15:15:39:7072; 3200, 4Deployment service - VisualStudioRemoteDeployeracbd6bee-be0e-4b3d-b552-21536dd17325 is running...
2017-11-16T04:17:55.8481226Z RemoteDeployerSource Verbose: 4 : [RemoteDeployer]16:Nov:17:15:15:40:7228; 3200, 6Input file found
2017-11-16T04:17:55.8481226Z RemoteDeployerSource Verbose: 5 : [RemoteDeployer]16:Nov:17:15:15:40:7228; 3200, 6Reading input parameters
2017-11-16T04:17:55.8481226Z RemoteDeployerSource Verbose: 6 : [RemoteDeployer]16:Nov:17:15:15:40:7228; 3200, 6Finished reading input parameters
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Task 'TestAgentConfiguration' on machine 'buildservername.schenker.int.au:5985' completed.
2017-11-16T04:17:55.8481226Z ##[warning]Task 'TestAgentConfiguration' for machine buildservername.schenker.int.au:5985's Error : System.Exception: The running command stopped because the preference variable "ErrorActionPreference" or common parameter is set to Stop: Unable to connect to Team Foundation Server
2017-11-16T04:17:55.8481226Z ##[warning]Task 'TestAgentConfiguration' for machine buildservername.schenker.int.au:5985's Log :
2017-11-16T04:17:55.8481226Z 	 Deployment started on target machine...
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z System.AggregateException: Failed to execute the powershell script. Consult the logs below for details of the error.
2017-11-16T04:17:55.8481226Z The running command stopped because the preference variable "ErrorActionPreference" or common parameter is set to Stop: Unable to connect to Team Foundation Server ---> System.Management.Automation.ActionPreferenceStopException: The running command stopped because the preference variable "ErrorActionPreference" or common parameter is set to Stop: Unable to connect to Team Foundation Server
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.Runspaces.PipelineBase.Invoke(IEnumerable input)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.Worker.ConstructPipelineAndDoWork(Runspace rs, Boolean performSyncInvoke)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.Worker.CreateRunspaceIfNeededAndDoWork(Runspace rsToUse, Boolean isSync)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.CoreInvokeHelper[TInput,TOutput](PSDataCollection1 input, PSDataCollection1 output, PSInvocationSettings settings)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.CoreInvoke[TInput,TOutput](PSDataCollection1 input, PSDataCollection1 output, PSInvocationSettings settings)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.Invoke(IEnumerable input, PSInvocationSettings settings)
2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Deployment.PowershellExecutor.<>c__DisplayClass28_0.b__0()
2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Utilities.RetryExecutor.<>c__DisplayClass19_01.<Execute>b__0() 2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Utilities.RetryExecutor.Execute(Action action) 2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Utilities.RetryExecutor.Execute[T](Func1 action)
2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Deployment.PowershellExecutor.Invoke(String errorContextMessage, Boolean writeResultToLog, Boolean isCancellable, ActionPreference errorActionPreference)
2017-11-16T04:17:55.8481226Z    --- End of inner exception stack trace ---
2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Deployment.PowershellExecutor.Invoke(String errorContextMessage, Boolean writeResultToLog, Boolean isCancellable, ActionPreference errorActionPreference)
2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Deployment.ScriptExecutor.ExecuteScript(IPowerShell powerShell, String script, String arguments, Boolean isScriptDotSourced, Boolean useHttp)
2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Deployment.DeploymentService.RunPowerShellScripts(DeploymentMachineSpecification deploymentMachine, ScriptSpecification scriptSpecification, ScriptSpecification initializationScriptSpecification, String applicationPath, IPowerShell powerShellSession)
2017-11-16T04:17:55.8481226Z ---> (Inner Exception #0) System.Management.Automation.ActionPreferenceStopException: The running command stopped because the preference variable "ErrorActionPreference" or common parameter is set to Stop: Unable to connect to Team Foundation Server
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.Runspaces.PipelineBase.Invoke(IEnumerable input)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.Worker.ConstructPipelineAndDoWork(Runspace rs, Boolean performSyncInvoke)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.Worker.CreateRunspaceIfNeededAndDoWork(Runspace rsToUse, Boolean isSync)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.CoreInvokeHelper[TInput,TOutput](PSDataCollection1 input, PSDataCollection1 output, PSInvocationSettings settings)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.CoreInvoke[TInput,TOutput](PSDataCollection1 input, PSDataCollection1 output, PSInvocationSettings settings)
2017-11-16T04:17:55.8481226Z    at System.Management.Automation.PowerShell.Invoke(IEnumerable input, PSInvocationSettings settings)
2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Deployment.PowershellExecutor.<>c__DisplayClass28_0.b__0()
2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Utilities.RetryExecutor.<>c__DisplayClass19_01.<Execute>b__0() 2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Utilities.RetryExecutor.Execute(Action action) 2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Utilities.RetryExecutor.Execute[T](Func1 action)
2017-11-16T04:17:55.8481226Z    at Microsoft.VisualStudio.Services.DevTestLabs.RemoteDeployer.Deployment.PowershellExecutor.Invoke(String errorContextMessage, Boolean writeResultToLog, Boolean isCancellable, ActionPreference errorActionPreference)<---
2017-11-16T04:17:55.8481226Z Test User userid
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Test UserDomain DomainName
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Testing container: 'REGISTRY::HKEY_CLASSES_ROOT\CLSID{177F0C4A-1CD3-4DE7-A32C-71DBBB9FA36D}'
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Exists.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Getting Visual Studio setup instances.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Found 1 instances.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Description   : Free, fully-featured IDE for students, open-source and individual developers
2017-11-16T04:17:55.8481226Z DisplayName   : Visual Studio Community 2017
2017-11-16T04:17:55.8481226Z Id            : ee6d2d29
2017-11-16T04:17:55.8481226Z InstallDate   : System.Runtime.InteropServices.ComTypes.FILETIME
2017-11-16T04:17:55.8481226Z Name          : VisualStudio/15.4.0+27004.2002
2017-11-16T04:17:55.8481226Z Path          : C:\Program Files (x86)\Microsoft Visual Studio\2017\Community
2017-11-16T04:17:55.8481226Z Version       : 15.4.27004.2002
2017-11-16T04:17:55.8481226Z VersionString : 15.4.27004.2002
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z VS path C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE; Test window path C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\CommonExtensions\Microsoft\TestWindow
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Path: C:\TestAgent\TfsAssemblies\Newtonsoft.Json.dll
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Loading module from path 'C:\TestAgent\TfsAssemblies\Newtonsoft.Json.dll'.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Loading module from path 'C:\TestAgent\TfsAssemblies\System.Net.Http.Formatting.dll'.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Loading module from path 'C:\TestAgent\TfsAssemblies\Microsoft.TeamFoundation.DistributedTask.Task.TestExecution.dll'.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Loading module from path 'C:\TestAgent\TfsAssemblies\Microsoft.TeamFoundation.Common.dll'.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Loading module from path 'C:\TestAgent\TfsAssemblies\Microsoft.TeamFoundation.Test.WebApi.dll'.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Loading module from path 'C:\TestAgent\TfsAssemblies\Microsoft.VisualStudio.Services.Common.dll'.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Loading module from path 'C:\TestAgent\TfsAssemblies\Microsoft.VisualStudio.Services.WebApi.dll'.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Loading module from path 'C:\TestAgent\PrivateAssemblies\Microsoft.VisualStudio.TestService.Utility.dll'.
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z ****************************************************************
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z                     Configure Test Agent
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z ----------------------------------------------------------------
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z SetupPath                       : (C:\TestAgent)
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z TestUserName                    : (DomainName\userid)
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z TfsCollection                   : (https://dbsanz.visualstudio.com/)
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z AsServiceOrProcess              : (Process)
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z EnvironmentUrl                  : (dta://env/442b3332-3557-49dd-80ed-9bc56c552466/_apis//201711161514213476)
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z MachineName                     : (buildservername)
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Capabilities                    : ()
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z TestAgentVersion                : (15.0)
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z ****************************************************************
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z Unable to connect to Team Foundation Server, Check if TFS is reachable from the test agent. Exception Details :
2017-11-16T04:17:55.8481226Z
2017-11-16T04:17:55.8481226Z System.Management.Automation.MethodInvocationException: Exception calling ".ctor" with "2" argument(s): "One or more errors occurred." ---> System.AggregateException: One or more errors occurred. ---> System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond <IP_ADDRESS>:80
2017-11-16T04:17:55.8637453Z    at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)
2017-11-16T04:17:55.8637453Z    at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception)
2017-11-16T04:17:55.8637453Z    --- End of inner exception stack trace ---
2017-11-16T04:17:55.8637453Z    at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
2017-11-16T04:17:55.8637453Z    at System.Net.Http.HttpClientHandler.GetResponseCallback(IAsyncResult ar)
2017-11-16T04:17:55.8637453Z    --- End of inner exception stack trace ---
2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.Common.VssHttpRetryMessageHandler.d__4.MoveNext() in E:\v2.0\A5_work\1\s\Vssf\Client\Common\VssHttpRetryMessageHandler.cs:line 159
2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown ---
2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.VssHttpClientBase.d__49.MoveNext() in E:\v2.0\A5_work\1\s\Vssf\Client\WebApi\VssHttpClientBase.cs:line 828
2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown ---
2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.VssHttpClientBase.d__461.MoveNext() in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\VssHttpClientBase.cs:line 727 2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown --- 2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.Location.Client.LocationHttpClient.<GetConnectionDataAsync>d__6.MoveNext() in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\HttpClients\LocationHttpClient.cs:line 73 2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown --- 2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.Location.VssServerDataProvider.<ConnectAsync>d__41.MoveNext() in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\Location\ServerDataProvider.cs:line 692 2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown --- 2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.Location.VssServerDataProvider.<EnsureConnectedAsync>d__39.MoveNext() in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\Location\ServerDataProvider.cs:line 642 2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown --- 2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.Location.VssServerDataProvider.<GetInstanceIdAsync>d__11.MoveNext() in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\Location\ServerDataProvider.cs:line 174 2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown --- 2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.Location.LocationService.<GetLocationDataAsync>d__2.MoveNext() in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\Location\LocationService.cs:line 54 2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown --- 2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.VssConnection.<GetClientInstanceAsync>d__18.MoveNext() in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\VssConnection.cs:line 357 2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown --- 2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.VssConnection.<GetClientServiceImplAsync>d__15.MoveNext() in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\VssConnection.cs:line 299 2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown --- 2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.VssConnection.<GetClientAsync>d__121.MoveNext() in E:\v2.0\A5_work\1\s\Vssf\Client\WebApi\VssConnection.cs:line 227
2017-11-16T04:17:55.8637453Z --- End of stack trace from previous location where exception was thrown ---
2017-11-16T04:17:55.8637453Z    at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
2017-11-16T04:17:55.8637453Z    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.TaskExtensions.SyncResult[T](Task1 task) in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\TaskExtensions.cs:line 35 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.Services.WebApi.VssConnection.GetClient[T]() in E:\v2.0\A5\_work\1\s\Vssf\Client\WebApi\VssConnection.cs:line 195 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.TestService.Utility.TestExecutionServiceRestApiHelper.Initialize(String serviceUrl, String accesToken) in E:\v2.0\A5\_work\1\s\Ta\Agent\VS.TestService.Utility\Client\TestExecutionServiceRestApiHelper.cs:line 107 2017-11-16T04:17:55.8637453Z    at System.Threading.Tasks.Task.Execute() 2017-11-16T04:17:55.8637453Z    --- End of inner exception stack trace --- 2017-11-16T04:17:55.8637453Z    at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions) 2017-11-16T04:17:55.8637453Z    at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken) 2017-11-16T04:17:55.8637453Z    at Microsoft.VisualStudio.TestService.Utility.TestExecutionServiceRestApiHelper.RunTaskWithRetriesOnServiceUnavailability[T](Func1 getTask) in E:\v2.0\A5_work\1\s\Ta\Agent\VS.TestService.Utility\Client\TestExecutionServiceRestApiHelper.cs:line 157
2017-11-16T04:17:55.8637453Z    --- End of inner exception stack trace ---
2017-11-16T04:17:55.8637453Z    at System.Management.Automation.DotNetAdapter.AuxiliaryConstructorInvoke(MethodInformation methodInformation, Object[] arguments, Object[] originalArguments)
2017-11-16T04:17:55.8637453Z    at System.Management.Automation.DotNetAdapter.ConstructorInvokeDotNet(Type type, ConstructorInfo[] constructors, Object[] arguments)
2017-11-16T04:17:55.8637453Z    at Microsoft.PowerShell.Commands.NewObjectCommand.CallConstructor(Type type, ConstructorInfo[] constructors, Object[] args)
2017-11-16T04:17:55.8637453Z
2017-11-16T04:17:55.8637453Z
2017-11-16T04:17:55.8637453Z ##[error]Error occurred on 'buildservername.schenker.int.au:5985'. Details : 'The running command stopped because the preference variable "ErrorActionPreference" or common parameter is set to Stop: Unable to connect to Team Foundation Server'. For troubleshooting, refer https://aka.ms/remotevstest.
2017-11-16T04:17:55.9262451Z ##[section]Finishing: Deploy TestAgent on

@debasisj does your remote machine (buildservername.schenker.int.au) has access to https://dbsanz.visualstudio.com? Asking this because in error message I see "Unable to connect to Team Foundation Server" or if there is a proxy on that machine?

Yes, it has access.
As I mentioned, this is my build agent server as well.
Regards,
Deb
On 16 Nov 2017, at 8:28 pm, Siddhartha Pandey <notifications<EMAIL_ADDRESS>wrote:
@debasisjhttps://github.com/debasisj does your remote machine (buildservername.schenker.int.auhttp://buildservername.schenker.int.au) has access to https://dbsanz.visualstudio.com? Asking this because in error message I see "Unable to connect to Team Foundation Server" or if there is a proxy on that machine?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/Microsoft/vsts-tasks/issues/5875#issuecomment-344865077, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AQ5t_04IDa71EBbCFk-iwYqb8jLwUMOcks5s3AAugaJpZM4Qf-Lb.

Hi Guys,
any update what i am missing?

I solved this Issue ;)
I recommends enabling and using the TLS 1.2 protocol on your server.  TLS 1.2 has improvements over previous versions of the TLS and SSL protocol which will improve your level of security.  By default, Windows Server does not have this feature enabled.  This KB article will describe the process to enable this.
Start the registry editor by clicking on Start and Run. Type in "regedit" into the Run field (without quotations).
Highlight Computer at the top of the registry tree.  Backup the registry first by clicking on File and then on Export.  Select a file location to save the registry file.
Note: You will be editing the registry.  This could have detrimental effects on your computer if done incorrectly, so it is strongly advised to make a backup.
Browse to the following registry key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols
Right click on the Protocols folder and select New and then Key from the drop-down menu. This will create new folder.  Rename this folder to TLS 1.2.
Right click on the TLS 1.2 key and add two new keys underneath it.
Rename the two new keys as:
Client
Server
Right click on the Client key and select New and then DWORD (32-bit) Value from the drop-down list.
Rename the DWORD to DisabledByDefault.
Right-click the name DisabledByDefault and select Modify... from the drop-down menu.
Ensure that the Value data field is set to 0 and the Base is Hexadecimal.  Click on OK.
Create another DWORD for the Client key as you did in Step 7.
Rename this second DWORD to Enabled.
Right-click the name Enabled and select Modify... from the drop-down menu.
Ensure that the Value data field is set to 1 and the Base is Hexadecimal. Click on OK.
Repeat steps 7 to 14 for the Server key (by creating two DWORDs, DisabledByDefault and Enabled, and their values underneath the Server key).
Reboot the server.

@debasisj are you still blocked on this. Did suggestion from @haddedayyadi helped?

Thanks for suggestions.
Eventually I worked it out by disabling routing internet request through proxy server which was not reachable or should not be hitting the proxy server from the VM.
Please close the issue.


Cannot build exaple

From a fresh clonned when attempting to build the nodejs example I get:
yarn install v1.22.17
[1/4] Resolving packages...
[2/4] Fetching packages...
warning<EMAIL_ADDRESS>The engine "vscode" appears to be invalid.
warning<EMAIL_ADDRESS>The engine "vscode" appears to be invalid.
[3/4] Linking dependencies...
warning "lerna > @lerna/version > @lerna/github-client > @octokit/rest ><EMAIL_ADDRESS>has unmet peer dependency "@octokit/core@>=3".
warning "workspace-aggregator-0e515c18-a138-4628-afb7-bb719063b036 > node-example ><EMAIL_ADDRESS>has incorrect peer dependency<EMAIL_ADDRESS>warning Workspaces can only be enabled in private projects.
warning Workspaces can only be enabled in private projects.
warning Workspaces can only be enabled in private projects.
warning Workspaces can only be enabled in private projects.
[4/4] Building fresh packages...
$ yarn run clean && yarn run build
yarn run v1.22.17
$ rimraf lib
Done in 0.05s.
yarn run v1.22.17
$ yarn run compile && webpack && yarn run copy
$ tsc
src/client.ts:10:8 - error TS2307: Cannot find module 'monaco-languageclient' or its corresponding type declarations.

10 } from 'monaco-languageclient';
          ~~~~~~~~~~~~~~~~~~~~~~~

src/client.ts:66:19 - error TS7006: Parameter 'errorHandler' implicitly has an 'any' type.

66             get: (errorHandler, closeHandler) => {
                     ~~~~~~~~~~~~

src/client.ts:66:33 - error TS7006: Parameter 'closeHandler' implicitly has an 'any' type.

66             get: (errorHandler, closeHandler) => {
                                   ~~~~~~~~~~~~

Found 3 errors

Did I miss any steps? How can I help you diagnosticate the issue
Any help would be appreciated

Hi @john-schmitz  you have to run yarn install once on top level of the project on a fresh checkout. I can reproduce your problem if I don't do this. Once you do, the problem above disappears.

I'm not familiar of yarn, but doesn't it mean the yarn.lock is broken?

Good point. Something seems fishy here. I deleted the lock file and then did yarn install again and it had many more changes. I will push a new branch and open a PR once I am certain it works as expected.

@CGNonofr  with PR #318<EMAIL_ADDRESS>was removed from yarn.lock and it was not replaced by<EMAIL_ADDRESS>what seems not logic, because the dependency is defined in both example and examples/browser. Even after manually removing the lock file and performing install in the project's root or the example it does not come back.!? 🤷♂

The workaround mentioned above applies. I guess the build and dependency management needs some love (see #315).

Since it's a yarn workspace, I don't think you should run yarn anywhere else than in the root (it's the case with npm workspace at least)

Yes, I only did to see if I can provoke an effect. True, with npm workspace you should only install in the root, but there the installation of child dependencies works. The yarn issue must have some to do with self referencing the repo here

Thanks everyone! I was able to run the example correctly!


Add hooks

Mode
Other
Feature description
I would like to suggest adding a new feature to the project configuration.
The feature request is to add hooks. Under hook I mean some subscription on events that are happening under the hood and executing some user logic. Example: Nuxt hooks
Suggested configuration:
import type { CustomProjectConfig } from "lost-pixel"

export const config: CustomProjectConfig = {
  // ...
  hooks: {
    "<hook-name>": async function (args) {
      await doSomethingWithArgs(args)
    },
  },
}

The expected process flow:

executing lib logic
executing user hook logic (the process is stopped until the hook handler is not resolved)
executing lib logic
....
finish the process

My case: I would like to edit generated screenshots before making a comparison. Usually, I use visual comparison for checking the state of reusable components, most of the time they are much bigger than the viewport. So I wrote a script that executes on provided images and can "trim" empty spaces (pixels with white color, from all sides until a row or column with at least 1 pixel with non-white color). I want to execute this script after screenshots were generated, but before the comparison started.
Would it be useful to add such a feature (hooks) to your library?
If the suggested feature is out of the library's scope, could you share please any other way how I can achieve the desired behavior?

hey! interesting idea in general, can see the application across various hooks and events.
i think currently you could do it in beforeTheScreenshot though, or? did you check it out?

i would be more than happy to accept the PR with after screenshot as well as extending element selector for non multi root components - gotta start somewhere, right? 😀 if you would require any help, i am here for you anytime!

Hi @d-ivashchuk
I have implemented the desired behavior, waiting for your review )
During development I had a problem with differences on how the headless browser in CI renders the screenshots compared to my local machine. How you usually solve this differences (which one you choose for baseline image)?

we either take them from test artefacts, or alternatively we run the tests with  docker update
https://docs.lost-pixel.com/user-docs/guides/testing-and-updating-baseline-locally

ah, clear, thanks
I committed them from CI and then merge --squash-ed them into commit
would be great if you can mention it in CONTRIBUTING.md


added api permissions endpoint

added api permissions endpoint to client.py for both Client and asyncClient

Thanks @rezaya92


Fix incorrect monkey-patch of requests json

Addresses #217

Coverage remained the same at 93.249% when pulling 025154a5a46b12806fe5e8caa6b597d8d87ae5fa on synapticarbors:patch-2 into 285d694b096daefe80b53eded7b5712d3cbaa4c7 on liampauling:master.


Parameterless function call

Parameterless function calls generate an error.
`"SELECT X(Y(Z())) AS TOTAL FROM STJ TBL"``
Dies in Unexpected 'RIGHT_PAREN', while
`"SELECT X(Y(Z)) AS TOTAL FROM STJ TBL"``
Works fine.
I'll try to fix it in the Jison grammar and submit a pull-request.

Please, note that there are some ambiguities in the current defined grammar. The current version of Jison gives us warnings about them.
But this can be trivially solved by adding a new production to UserFunction:
o "LITERAL LEFT_PAREN RIGHT_PAREN", -> new FunctionValue($1, [], true)


Adds TransformSpacing for FlowContainers

Adds TransformSpacing for FlowContainers
Renames SpriteText's TransformSpacing to TransformSpacingOverlap due to name-clash and SpriteText's variable being called SpacingOverlap

TransformSpacing can encompass all of TransformSpacingOverlap's functionality, want me to do so?
For https://github.com/ppy/osu/pull/202 (Transitions/Animations of buttons on PopUpDialogs and the Song Select options menu)

I think it may be wise to just remove the SpacingOverlap transform (doesn't seem necessary with this one added; just add internally inside SpriteText, right?).


wait for the animation to finish

Hello!
that was a nice work! thank you..
is there any way to wait for the previous animation to finish before starting another?

Thanks!
In order to wait for animation to finish, you can subscribe to animationposition_changed event. In handler  you compare getAnimationPosition() with getPosition() - as soon as they're equal, you know the animated marker arrived to its destination.


Applied Visual Design: Tertiary Colors Throwing Errors with Correct Hex

See screenshot below for clarification. Correct (given) hex codes are still throwing errors. Have refreshed, restarted, and cleared cache. Please advise as it will not allow me to continue without passing this challenge.
Thank you!
Challenge learn-about-tertiary-colors has an issue.
User Agent is: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36.
Please describe how to reproduce this issue, and include links to screenshots if possible.

@al3tte It's because you're using lowercase hex code values.
While the (general) convention is uppercase values, I think we should amend the tests to allow lowercase values too, as they're not incorrect.
Side Note - I can work on this, if we decide to proceed.

@Manish-Giri: Yeah... sorry... I should have accounted for this in my recent PR. 😄 .(I assumed people would just copy and paste the hex code values into the editor). I agree that you should go ahead with amending the tests to allow for the lowercase hex code option. (Although including tests for every possible permutation of a solution could become egregious, considering that the table provides the exact hex code values to use).
Note: Does this now mean that there should be an inclusion in the description field that hex code values can either be all lowercase or uppercase? If not, was this mentioned in an earlier challenge in the Applied Visual Design section?

@Manish-Giri Doh! I used lowercase values on the other hex tests so I didn't even think to try that!
@cdrainxv On the other challenges the lowercase values were accepted, so you may want to consider changing one or the other, for consistency's sake, if nothing else.
Thank you both for the quick responses though! :grinning:


bug: faucet flaky with sdk 0.47.3

Overview
There seems to be some error with Faucet version 0.30.1 and 0.30.0 running with sdk 0.47 using<EMAIL_ADDRESS>More details here: https://github.com/cosmos/cosmjs/issues/1353#issuecomment-1595810835

Fixed with #129


alternative onoff cancellation approach

This derives from the commits #23229 excluding the notifier, but uses a technique similar to that of the notifier to allow cancellation of in-progress operations without a failure case.  Cancelling a request or a reset always completes synchronously, even if this means errors in the transition are not reported.  Canceling a release converts it into a request that will force a transition to on as soon as the transition to stop completes.

Cancelling a request or a reset always completes synchronously, even if this means errors in the transition are not reported

So far this was a must have to get notification about an error and now it's not? Maybe there should be an option to have one monitor client which is notified about error onoff_monitor(srv,cli).
In general client will learn that service is in error state on next request so that seems ok but something is needed for cases when it is critical to react to error on time.

So far this was a must have to get notification about an error and now it's not?

It was a design goal when cancellation was an highly unusual operation.  Since cancellation appears to be common at least with your use style, its cost has increased.  There are several ways forward.
In general I'm not in favor of having a client that was configured to receive notification of a request completion suddenly have to cope with receiving notification of a release completion when the request is cancelled.  I can probably live with that, though, with a little documentation update.

Maybe there should be an option to have one monitor client which is notified about error onoff_monitor(srv,cli).

Yes, something like that, though I was thinking of a registry of callbacks for anything interested in receiving notifications of state changes, probably by moving that feature out of onoff_notifier.  Again, more thought required.
I'll make a second pass on this then.

@nordic-krch Next pass at this.
Cancellation no longer includes completion with -ECANCELLED.  The notify callback now includes the state at time of completion, so that clients originally submitted for a release but due to cancellation used for a request get told the state that was delivered.  There's also a monitor facility to track changes to the service state, which is the only way to be notified that transition has started, and the only way to try to correlate the result state for cancelled releases for spinwait and signal.  See the commit messages.
This is now nearly equal to the capabilities of #23229.  It's not equivalent because there's noting comparable to onoff_notifier_request/release to manage the client-specific state.  I'm not entirely sure that cancellation is the right way to solve that, but will look at it tomorrow.

Closing: this approach is now integrated into the development branch available for pre-PR review as #23229.


Tensorflow reimplementation performs significantly worse than original POC

Intro
I have asked this question several times on stackoverflow using different wording and level of details yet didn't get a single answer. Given the nature of the problem it is understandable, you cannot debug the network without training data and code. Still, maybe there is something obvious that I am missing here. We are trying to rewrite successful Torch POC binary classifier using Tensorflow to put it into production.
Torch POC
Torch model is a sequential binary classifier that works on word sequences and attempts to predict if the current word belongs to class 1 or 0. The model is quite simple, we have embedding layer and a special feature layer which we sum together before feeding the result vector into LSTM / GRU cell. At the output we do linear transform with sigmoid, compute binary cross entropy loss and update our parameters. Depending on the vocabulary size the model consists of 700k - 1000k params.
Tensorflow reimplmentation
We have been using standard Tensorflow language model trainable on Penn Treebank dataset as our code base. We have adapted it to the point where it looks identical to our Torch POC (same hyperparams and equal number of parameters) and started training.
Problem
It quickly became clear that Tensorflow reimplemetation does not learn anything even though the loss drops and test dataset shows error decrease: Test loss reduced: 97690.06433105469 --> 9929.968887329102. Loading the trained model and quering it with words showed that the model predictions are garbage. Besides the loss values are different for Torch and Tensorflow.
Tensorflow implementation (main part):
#################### PLACEHOLDERS ####################
# We use placeholders for the word, feature inputs and corresponding targets
self.words_input = tf.placeholder(tf.int32, [config.batch_size, config.seq_length])
self.feats_input = tf.placeholder(tf.float32, [config.batch_size, config.seq_length, config.nfeats])
self.targets_input = tf.placeholder(tf.float32, [config.batch_size, config.seq_length])

#################### VARIABLES ####################
# We use variables for trainable network params like word embeddings, weights and biases
# select params initialization
if self.init_method == "xavier":
    self.initer = tf.contrib.layers.xavier_initializer(uniform=False)

elif self.init_method == "uniform":
    self.initer = tf.random_uniform_initializer(-config.init_scale, config.init_scale)

elif self.init_method == "normal":
    self.initer = tf.random_normal_initializer()

else:
    self.initer = tf.zeros_initializer()

# word embeddings
with tf.variable_scope("input_layer"):
    self.embedding = tf.get_variable("embedding", [self.vocab_size, self.input_size],
                                     initializer=self.initer, trainable=True)
    # feature weights for linear transform
    self.feature_weight = tf.get_variable("feature_weigths", [config.nfeats, config.input_size],
                                          initializer=self.initer, trainable=True)
    # feature biases for linear transform
    self.feature_bias = tf.get_variable("feature_bias", [config.input_size],
                                        initializer=self.initer, trainable=True)

# weights and biases of output layer (follows hidden layer(s))
with tf.variable_scope("output_layer"):
    # this is where we define out linear + sigmoid sizes [hidden_size x 1 or several classes]
    self.output_w = tf.get_variable("output_w", [self.last_layer_size, self.pay_type],
                                    initializer=self.initer, trainable=True)

    self.output_b = tf.get_variable("output_b", [self.pay_type], initializer=self.initer,
                                    trainable=True)

#################### GRAPH ####################
# create embedding lookup table with embedding variable and word inputs placeholder
word_embeddings = tf.nn.embedding_lookup(self.embedding, self.words_input)  # [32 x 25 x 100]

# create feature linear transform layer with feature inputs placeholder
# first we need to swap tensor dims from [0, 1, 2] --> [1, 0, 2] to make seq_length first
_feats_trans = tf.transpose(self.feats_input, [1, 0, 2])  # [25 x 32 x 4]

# apply linear transform without activation in order
# to expand feature vectors [batch_size x nfeats] -> [batch_size x input_size]
# this is needed to sum them with word embeddings before recurrent layer
#_feats_exp = tf.map_fn(self._linear, _feats_trans, dtype=tf.float32, back_prop=True)  # [25 x 32 x 100]
_feats_exp = [tf.nn.xw_plus_b(s, self.feature_weight, self.feature_bias)
              for s in tf.unstack(_feats_trans, axis=0)]

# now stack the list of tensors and transpose back to [batch_size x seq_length x input_size]
feats_exp = tf.transpose(tf.stack(_feats_exp, axis=0), [1, 0, 2])  # [32 x 25 x 100]

# sum the outputs of the embedding and linear ops
inputs_sum = tf.add(word_embeddings, feats_exp)  # [32 x 25 x 100]

# apply dropout here if needed
#if self.training and self.input_keep_prob < 1:
#    inputs_sum = tf.nn.dropout(inputs_sum, self.input_keep_prob)

# split the input matrices vertically into separate tensors
_inputs_spl = tf.split(inputs_sum, config.seq_length, axis=1)
# remove single tensor dimensions
inputs = [tf.squeeze(split, [1]) for split in _inputs_spl]  # [25 * [32 x 100]]

# build recurrent cells
self.cell = self._create_recurrent_cell(config)

# initialize the hidden (recurrent) state to zero
self.initial_state = self.cell.zero_state(config.batch_size, tf.float32)

# create recurrent network using rnn cell and return outputs and final state
_outputs, self.final_state = self._apply_rec_cell(inputs, self.initial_state, self.cell, config)  # [800 x 200]

# apply dropout here if needed
if self.training and self.input_keep_prob < 1:
    cell_output = tf.nn.dropout(_outputs, self.input_keep_prob)

# the hidden layer output is fed into matmul(x, weights) + biases function
logits = tf.nn.xw_plus_b(cell_output, self.output_w, self.output_b)  # [800 x 1]

# transform logits into [seq_length x batch_size x 1]
_logits = tf.reshape(logits, [config.seq_length, config.batch_size, config.pay_type])  # [25 x 32 x 1]

self.logits = _logits

# add single dim to target tensor [32 x 25] --> [32 x 25 x 1]
_targets = tf.expand_dims(self.targets_input, axis=2)
# transform targets tensor [32 x 25 x 1] --> [25 x 32 x 1] for loss computation
_targets = tf.transpose(_targets, [1, 0, 2])

#################### LOSS CALCULATION ####################
# unstack logits and targets along seq_length dimension
_logits_uns = tf.unstack(_logits, axis=0)
_targets_uns = tf.unstack(_targets, axis=0)

# apply loss function to each sequence and compute individual losses
loss_fn = tf.losses.sigmoid_cross_entropy
#loss_fn = tf.nn.sigmoid_cross_entropy_with_logits
individual_losses = []

for t, o in zip(_targets_uns, _logits_uns):  # [32 x 1], [32 x 1]
    _loss = loss_fn(t, o, weights=1.0, label_smoothing=0, scope="sigmoid_cross_entropy",
                    loss_collection=tf.GraphKeys.LOSSES, reduction=tf.losses.Reduction.NONE)
    #_loss = loss_fn(labels=t, logits=o, name="sigmoid_cross_entropy")
    individual_losses.append(_loss)

# calculate the loss sum of individual losses
with tf.name_scope('loss'):
    self.loss = tf.reduce_sum(individual_losses)

#################### TRAINING ####################
if self.training:
    self.lr = tf.Variable(0.0, trainable=False)
    tvars = tf.trainable_variables()

    # print model shapes and total params
    print("MODEL params:")
    for t in tvars:
        print(t.shape)
    print("TOTAL params:", np.sum([np.prod(t.shape) for t in tvars]))

    # clip the gradient by norm
    if config.grad_clip > 0:
        grads, _ = tf.clip_by_global_norm(tf.gradients(self.loss, tvars), config.grad_clip)
    else:
        grads = tf.gradients(self.loss, tvars)

    # update variables (weights, biases, embeddings...)
    with tf.name_scope("optimizer"):
        optimizer = tf.train.AdamOptimizer(self.lr)
        #optimizer = tf.train.GradientDescentOptimizer(self.lr)
        # compute grads/vars for tensorboard
        self.grads_and_vars = optimizer.compute_gradients(self.loss)

        self.train_op = optimizer.apply_gradients(zip(grads, tvars),          global_step=tf.train.get_or_create_global_step())

Recurrent cell creation
    def _create_recurrent_cell(self, config):
        """
        Define and return recurrent cell.
        """
            cell = rnn.GRUCell(self.hidden_size,
                                           kernel_initializer=self.initer,
                                           bias_initializer=self.initer,
                                           activation=tf.nn.tanh)

            # apply dropout if required
            if self.training and self.output_keep_prob < 1.0:
                cell = rnn.DropoutWrapper(cell, output_keep_prob=self.output_keep_prob)

        # we might use several rnn cells in future
        return rnn.MultiRNNCell(cell, state_is_tuple=True)

Recurrent cell application
    def _apply_rec_cell(self, inputs, initial_state, cell, config):
        """
        Apply recurrence cell to each input sequence.
        """

        with variable_scope.variable_scope("recurrent_cell"):
            state = initial_state
            _outputs = []
            for i, inp in enumerate(inputs):  # 25 * [32 x 100]
                if i > 0:
                    variable_scope.get_variable_scope().reuse_variables()
                output, state = cell(inp, state)  # [32 x 200]
                _outputs.append(output)

        # concat the outputs and reshape them into 2D tensor (for xw_plus_b)
        outputs = tf.reshape(tf.concat(_outputs, 1), [-1, self.recurrent_state_size])
        return outputs, state

Torch POC training analysis
We first take a look at our Torch model and see how it trains during first 10 epochs. We use batch_size=32, seq_length=25, word embedding and feature vectors of size 100 and GRU cell size = 200.
nn.Sequential {
  [input -> (1) -> (2) -> (3) -> (4) -> output]
  (1): nn.ParallelTable {
    input
      |`-> (1): nn.Sequential {
      |      [input -> (1) -> (2) -> output]
      |      (1): nn.LookupTable
      |      (2): nn.SplitTable
      |    }
       `-> (2): nn.Sequential {
             [input -> (1) -> (2) -> output]
             (1): nn.SplitTable
             (2): nn.MapTable {
               nn.Linear(4 -> 100)
             }
           }
       ... -> output
  }
  (2): nn.ZipTable
  (3): nn.MapTable {
    nn.CAddTable
  }
  (4): nn.Sequencer @ nn.Recursor @ nn.Sequential {
    [input -> (1) -> (2) -> (3) -> (4) -> output]
    (1): nn.RecGRU(100 -> 200)
    (2): nn.Dropout(0.5, busy)
    (3): nn.Linear(200 -> 1)
    (4): nn.Sigmoid
  }
}

Epoch #1
training...
8.5397211080362e-08	embeddings grads
0.020771607756615	feature weights grads
0.00044380914187059	feature bias grads
8.6396757978946e-06	gru grads
5.7720841141418e-05	gru bias grads
0.022520124912262	output_w grads
0.32349386811256	output_b grads
learning rate:	0.0497500005
Elapsed time: 3.190759
Speed: 0.000019 sec/batch
Training ERR:<PHONE_NUMBER>2177
validating...
Validation ERR:<PHONE_NUMBER>009
check early-stopping...
Found new minima. Saving
Last best epoch: 1, ERR: 121.488988

Epoch #2
training...
5.9534809082606e-08	embeddings grads
0.010755381546915	feature weights grads
0.00030940235592425	feature bias grads
2.632729774632e-05	gru grads
8.1771839177236e-05	gru bias grads
0.044476393610239	output_w grads
0.37297031283379	output_b grads
learning rate:	0.049500001
Elapsed time: 2.988541
Speed: 0.000018 sec/batch
Training ERR:<PHONE_NUMBER>6807
validating...
Validation ERR:<PHONE_NUMBER>843
check early-stopping...
Found new minima. Saving
Last best epoch: 2, ERR: 115.883777

Epoch #3
training...
1.9829073494293e-08	embeddings grads
0.0085931243374944	feature weights grads
0.00010305171599612	feature bias grads
-2.4194558136514e-05	gru grads
-4.8788820095069e-06	gru bias grads
0.0073388875462115	output_w grads
0.40312686562538	output_b grads
learning rate:	0.0492500015
Elapsed time: 2.969960
Speed: 0.000018 sec/batch
Training ERR:<PHONE_NUMBER>7737
validating...
Validation ERR:<PHONE_NUMBER>1018
check early-stopping...
Found new minima. Saving
Last best epoch: 3, ERR: 110.509211

Epoch #4
training...
-7.4974275676709e-09	embeddings grads
0.0028696460649371	feature weights grads
-3.8964077248238e-05	feature bias grads
-3.4580276405904e-05	gru grads
-3.2265303161694e-05	gru bias grads
0.049573861062527	output_w grads
0.4097863137722	output_b grads
learning rate:	0.049000002
Elapsed time: 3.005452
Speed: 0.000018 sec/batch
Training ERR:<PHONE_NUMBER>8799
validating...
Validation ERR:<PHONE_NUMBER>1716
check early-stopping...
Found new minima. Saving
Last best epoch: 4, ERR: 107.629394

Epoch #5
training...
-3.623286559673e-08	embeddings grads
-0.01051034592092	feature weights grads
-0.00018830213230103	feature bias grads
4.4970302042202e-06	gru grads
3.8041966035962e-05	gru bias grads
0.0042808093130589	output_w grads
0.13134820759296	output_b grads
learning rate:	0.0487500025
Elapsed time: 2.966464
Speed: 0.000018 sec/batch
Training ERR:<PHONE_NUMBER>2801
validating...
Validation ERR:<PHONE_NUMBER>2633
check early-stopping...
Last best epoch: 4, ERR: 107.629394

Epoch #6
training...
-1.7328080303969e-08	embeddings grads
-0.0070463065057993	feature weights grads
-9.0054127213079e-05	feature bias grads
2.1397584077931e-06	gru grads
6.5339445427526e-05	gru bias grads
0.0060789352282882	output_w grads
0.13912197947502	output_b grads
learning rate:	0.048500003
Elapsed time: 2.984332
Speed: 0.000018 sec/batch
Training ERR:<PHONE_NUMBER>1024
validating...
Validation ERR:<PHONE_NUMBER>6429
check early-stopping...
Found new minima. Saving
Last best epoch: 6, ERR: 101.848845

Epoch #7
training...
-2.1446611597753e-08	embeddings grads
-0.0099087124690413	feature weights grads
-0.000111457935418	feature bias grads
4.289226126275e-06	gru grads
9.2848667918588e-06	gru bias grads
0.033868614584208	output_w grads
0.36384600400925	output_b grads
learning rate:	0.0482500035
Elapsed time: 2.971069
Speed: 0.000018 sec/batch
Training ERR:<PHONE_NUMBER>5153
validating...
Validation ERR: 89.342911911197
check early-stopping...
Found new minima. Saving
Last best epoch: 7, ERR: 89.342912

Epoch #8
training...
-2.4536879195125e-08	embeddings grads
-0.019674839451909	feature weights grads
-0.00012751790927723	feature bias grads
2.5825884222286e-06	gru grads
2.7131845854456e-06	gru bias grads
0.021293396130204	output_w grads
0.52193140983582	output_b grads
learning rate:	0.048000004
Elapsed time: 2.977743
Speed: 0.000018 sec/batch
Training ERR:<PHONE_NUMBER>7828
validating...
Validation ERR: 85.326015817933
check early-stopping...
Found new minima. Saving
Last best epoch: 8, ERR: 85.326016

Epoch #9
training...
-4.5795339076449e-08	embeddings grads
-0.019793825224042	feature weights grads
-0.00023799829068594	feature bias grads
-6.2910985434428e-06	gru grads
-2.7645726731862e-05	gru bias grads
-0.0087647764012218	output_w grads
0.11675848066807	output_b grads
learning rate:	0.0477500045
Elapsed time: 3.058577
Speed: 0.000018 sec/batch
Training ERR:<PHONE_NUMBER>6603
validating...
Validation ERR: 81.433456174098
check early-stopping...
Found new minima. Saving
Last best epoch: 9, ERR: 81.433456

Epoch #10
training...
-1.2227498302764e-07	embeddings grads
-0.079100400209427	feature weights grads
-0.00063546327874064	feature bias grads
2.7701785256795e-06	gru grads
-3.344654396642e-05	gru bias grads
-0.0030312589369714	output_w grads
0.41179794073105	output_b grads
learning rate:	0.047500005
Elapsed time: 3.000976
Speed: 0.000018 sec/batch
Training ERR:<PHONE_NUMBER>6992
validating...
Validation ERR: 79.982634914108
check early-stopping...
Found new minima. Saving
Last best epoch: 10, ERR: 79.982635

You can well see that during first 10 epochs Torch POC loss dropped significantly. Now let's take a look at idential Tensorflow implementation that uses the same dataset, same hyperparameters and has the same number of parameters as well as optimizer.
Tensorflow version training analysis
MODEL params:
(5197, 100)
(4, 100)
(100,)
(200, 1)
(1,)
(300, 400)
(400,)
(300, 200)
(200,)
TOTAL params: 701001
2018-04-06 11:26:30.534418: I tensorflow/core/platform/cpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: SSE4.1 SSE4.2 AVX AVX2 FMA
2018-04-06 11:26:30.592130: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:895] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero
2018-04-06 11:26:30.592438: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1105] Found device 0 with properties:
name: GeForce GTX 1070 major: 6 minor: 1 memoryClockRate(GHz): 1.695
pciBusID: 0000:01:00.0
totalMemory: 7.92GiB freeMemory: 7.61GiB
2018-04-06 11:26:30.592470: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1195] Creating TensorFlow device (/device:GPU:0) -> (device: 0, name: GeForce GTX 1070, pci bus id: 0000:01:00.0, compute capability: 6.1)

ERROR: unable to remove saved_model dir!
saved_model does not exist or locked, remove manually

>>> Start test loss:<PHONE_NUMBER>7460938

Epoch: 1
> lr update: 0.0497500005
#################### DEBUGGING ####################
-8.42829e-09 	 Model/input_layer/embedding:0_grads
-1.0331846e-05 	 Model/input_layer/feature_weigths:0_grads
-6.7426217e-06 	 Model/input_layer/feature_bias:0_grads
0.32880843 	 Model/output_layer/output_w:0_grads
-18.802212 	 Model/output_layer/output_b:0_grads
-2.583741e-07 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
2.0594268e-06 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
1.7847007e-06 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
-1.2758308e-05 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 41251.31823730469
> Valid loss: 4779.414421081543
> Best valid loss so far:<PHONE_NUMBER>7460938
Stopping in (35) epochs if no new minima!
!!! NEW local minima found, saving the model...

Epoch: 2
> lr update: 0.049500001
#################### DEBUGGING ####################
4.380058e-12 	 Model/input_layer/embedding:0_grads
-1.5687052e-09 	 Model/input_layer/feature_weigths:0_grads
3.5040453e-09 	 Model/input_layer/feature_bias:0_grads
1.0858363 	 Model/output_layer/output_w:0_grads
-24.059809 	 Model/output_layer/output_b:0_grads
9.927889e-11 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
-1.6885447e-09 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
7.744753e-11 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
-1.343922e-09 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 36458.438621520996
> Valid loss: 4771.496253967285
> Best valid loss so far: 4779.414421081543
Stopping in (35) epochs if no new minima!
!!! NEW local minima found, saving the model...

Epoch: 3
> lr update: 0.0492500015
#################### DEBUGGING ####################
-9.34557e-13 	 Model/input_layer/embedding:0_grads
-2.8814911e-18 	 Model/input_layer/feature_weigths:0_grads
-7.4764217e-10 	 Model/input_layer/feature_bias:0_grads
1.0264161 	 Model/output_layer/output_w:0_grads
-28.068089 	 Model/output_layer/output_b:0_grads
-3.470961e-10 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
3.2109366e-09 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
-3.8721065e-10 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
3.5263255e-09 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 36571.039489746094
> Valid loss: 5612.627830505371
> Best valid loss so far: 4771.496253967285
Stopping in (35) epochs if no new minima!

Epoch: 4
> lr update: 0.049000002
#################### DEBUGGING ####################
-1.5510707e-08 	 Model/input_layer/embedding:0_grads
-1.9394596e-05 	 Model/input_layer/feature_weigths:0_grads
-1.2408569e-05 	 Model/input_layer/feature_bias:0_grads
0.4255897 	 Model/output_layer/output_w:0_grads
-15.242744 	 Model/output_layer/output_b:0_grads
-2.0200261e-09 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
1.8209105e-08 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
2.867294e-07 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
-2.1903145e-06 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 37006.26306152344
> Valid loss: 4739.623916625977
> Best valid loss so far: 4771.496253967285
Stopping in (34) epochs if no new minima!
!!! NEW local minima found, saving the model...

Epoch: 5
> lr update: 0.0487500025
#################### DEBUGGING ####################
1.2948664e-11 	 Model/input_layer/embedding:0_grads
4.020792e-08 	 Model/input_layer/feature_weigths:0_grads
1.035893e-08 	 Model/input_layer/feature_bias:0_grads
-0.23937465 	 Model/output_layer/output_w:0_grads
-4.5712795 	 Model/output_layer/output_b:0_grads
-1.2125412e-10 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
1.2779661e-09 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
-5.819682e-10 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
3.9421697e-09 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 35687.37390899658
> Valid loss: 4758.33650970459
> Best valid loss so far: 4739.623916625977
Stopping in (35) epochs if no new minima!

Epoch: 6
> lr update: 0.048500003
#################### DEBUGGING ####################
8.107671e-14 	 Model/input_layer/embedding:0_grads
0.0 	 Model/input_layer/feature_weigths:0_grads
6.486137e-11 	 Model/input_layer/feature_bias:0_grads
0.86348265 	 Model/output_layer/output_w:0_grads
-19.398884 	 Model/output_layer/output_b:0_grads
2.4077628e-12 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
-2.4667464e-11 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
-1.07752e-15 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
9.429133e-15 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 34959.51641845703
> Valid loss: 4720.412452697754
> Best valid loss so far: 4739.623916625977
Stopping in (34) epochs if no new minima!
!!! NEW local minima found, saving the model...

Epoch: 7
> lr update: 0.0482500035
#################### DEBUGGING ####################
1.1791363e-14 	 Model/input_layer/embedding:0_grads
0.0 	 Model/input_layer/feature_weigths:0_grads
9.433085e-12 	 Model/input_layer/feature_bias:0_grads
0.46038043 	 Model/output_layer/output_w:0_grads
-18.42015 	 Model/output_layer/output_b:0_grads
-5.90758e-14 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
6.253203e-13 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
-1.6275301e-15 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
1.5087512e-14 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 35122.075828552246
> Valid loss: 4872.291694641113
> Best valid loss so far: 4720.412452697754
Stopping in (35) epochs if no new minima!

Epoch: 8
> lr update: 0.048000004
#################### DEBUGGING ####################
1.5793947e-14 	 Model/input_layer/embedding:0_grads
0.0 	 Model/input_layer/feature_weigths:0_grads
1.26351585e-11 	 Model/input_layer/feature_bias:0_grads
-0.23440647 	 Model/output_layer/output_w:0_grads
-17.745054 	 Model/output_layer/output_b:0_grads
6.400091e-13 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
-6.770721e-12 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
-7.499852e-14 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
6.953364e-13 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 35376.37155151367
> Valid loss: 4934.555885314941
> Best valid loss so far: 4720.412452697754
Stopping in (34) epochs if no new minima!

Epoch: 9
> lr update: 0.0477500045
#################### DEBUGGING ####################
-1.2424676e-13 	 Model/input_layer/embedding:0_grads
0.0 	 Model/input_layer/feature_weigths:0_grads
-9.939738e-11 	 Model/input_layer/feature_bias:0_grads
0.5383458 	 Model/output_layer/output_w:0_grads
-21.300901 	 Model/output_layer/output_b:0_grads
-7.6299974e-13 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
8.020704e-12 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
-7.250712e-16 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
6.68652e-15 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 35422.02657318115
> Valid loss: 4915.4898681640625
> Best valid loss so far: 4720.412452697754
Stopping in (33) epochs if no new minima!

Epoch: 10
> lr update: 0.047500005
#################### DEBUGGING ####################
4.3053272e-14 	 Model/input_layer/embedding:0_grads
0.0 	 Model/input_layer/feature_weigths:0_grads
3.4442636e-11 	 Model/input_layer/feature_bias:0_grads
-0.4148861 	 Model/output_layer/output_w:0_grads
-16.681393 	 Model/output_layer/output_b:0_grads
-3.3981418e-12 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/kernel:0_grads
3.5677305e-11 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/gates/bias:0_grads
-1.0744528e-14 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/kernel:0_grads
9.898426e-14 	 Model/recurrent_cell/multi_rnn_cell/cell_0/gru_cell/candidate/bias:0_grads

==================== debug_var ====================
> Train loss: 35475.495765686035
> Valid loss: 4763.377861022949
> Best valid loss so far: 4720.412452697754
Stopping in (32) epochs if no new minima!

You can well see the gradients are very low in comparison to Torch POC up to the point that  some of them become zero or very close. Additionally, binary cross entropy loss is much higher and basically does not drop. Using standard tf.train.GradientDescentOptimizer(self.lr) does not make the gradients that small and is more stable in general but produces the same garbage predictions after training. We have been trying to figure out the reason for several weeks now and are simply out of clue what could cause such a drastic difference.  We checked our data preprocessing up to the point where we printed out the input matrix values and compared them side by side with Torch. They are identical so it is highly unlikely to be the data feeding mechanism. There is something not right with backpropagation it seems but our lack of experience with Tensorflow does not allow us to proceed further. Maybe somebody here could give us an advice on what could be the reason?
Addtionally attaching Tensorboard output as well.

Thank you for your post. We noticed you have not filled out the following field in the issue template. Could you update them if they are relevant in your case, or leave them as N/A? Thanks.
Have I written custom code
OS Platform and Distribution
TensorFlow installed from
Bazel version
CUDA/cuDNN version
GPU model and memory
Exact command to reproduce

Have I written custom code - yes
OS Platform and Distribution - Linux 4.14.30-1-MANJARO
TensorFlow installed from - pip, tensorflow-gpu 1.7
Bazel version - ???
CUDA/cuDNN version - 9.0
GPU model and memory - NVIDIA GTX 1070 mobile, 8GB
Exact command to reproduce --


Remove DangerousAPI check from appverif

Fixes #2581
Description
Remove DangerousAPI check from appverif for unit_tests.exe
Testing
Existing CICD
Documentation
NA

Closing this PR and the corresponding issue. We currently skip that test in GitHub CICD


"viewInsets.bottom" changes when TextFormField "isObscureText" changes

Steps to reproduce

Create screen with SafeArea -> Scaffold -> SingleChildScrollView -> Column
In the Column add two TextFormFields.

Set the first one with isObscureText: false
Set the second one with isObscureText: true

Add additional child to the column:

Padding with padding value = MediaQuery.of(context).viewInsets.bottom
I'm using it in order to push the widgets up when the keyboard is opened

When moving between the TextFields, there is kind of 'flickering' of the screen due to the changes in the  viewInsets.bottom value.

You can see in the results below how the value changes.
It's more noticeable and annoying with iPhone since the keyboard returns to the same size,
compared to Pixel (Android) where the size just changes so it makes a bit of sense.
How can I avoid it?
Is it a bug?

Expected results
When moving from isObscureText: false to isObscureText: true:
iPhone XR (iOS 17):
flutter: MediaQuery.of(context).viewInsets.bottom: 346.0
flutter: MediaQuery.of(context).viewInsets.bottom: 346.0
Pixel 4 (Android 13):
flutter: MediaQuery.of(context).viewInsets.bottom:<PHONE_NUMBER>5454544
flutter: MediaQuery.of(context).viewInsets.bottom:<PHONE_NUMBER>5454544
Samsung S8 (Android 9): (OK on both cases)
MediaQuery.of(context).viewInsets.bottom: 279.0
MediaQuery.of(context).viewInsets.bottom: 279.0

Actual results
When moving from Username (isObscureText: false) to Password (isObscureText: true):
iPhone XR (iOS 17):
flutter: MediaQuery.of(context).viewInsets.bottom: 346.0
flutter: MediaQuery.of(context).viewInsets.bottom:<PHONE_NUMBER>306885
flutter: MediaQuery.of(context).viewInsets.bottom: 346.0
Pixel 4 (Android 13):
MediaQuery.of(context).viewInsets.bottom:<PHONE_NUMBER>5454544
MediaQuery.of(context).viewInsets.bottom:<PHONE_NUMBER>5454544
Samsung S8 (Android 9): (OK on both cases)
MediaQuery.of(context).viewInsets.bottom: 279.0
MediaQuery.of(context).viewInsets.bottom: 279.0

Screenshots or Video

Screenshots / Video demonstration
Keyboard images:

Username field: isObscureText: false
Password field: isObscureText: true

iPhone XR (iOS 17):

Pixel 4 (Android 13):

Samsung S8 (Android 9): (OK on both cases)

Flutter Doctor output
Doctor output
[✓] Flutter (Channel stable, 3.19.2, on macOS 14.2.1 23C71 darwin-arm64, locale en-IL)
    • Flutter version 3.19.2 on channel stable at /Users/admin/Downloads/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision<PHONE_NUMBER> (12 days ago), 2024-02-27 16:51:22 -0500
    • Engine revision 04817c99c9
    • Dart version 3.3.0
    • DevTools version 2.31.1

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/admin/Library/Android/sdk
    • Platform android-34-ext8, build-tools 34.0.0
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.9+0-17.0.9b1087.7-11185874)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.0.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15A507
    • CocoaPods version 1.15.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2023.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.9+0-17.0.9b1087.7-11185874)

[✓] VS Code (version 1.87.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.84.0

[✓] Connected device (4 available)
    • SM G950F (mobile)     • ce031713eb0288210d        • android-arm64  • Android 9 (API 28)
    • iPhone (mobile) • 00008020-001059A91EE9002E • ios            • iOS 17.3.1 21D61
    • macOS (desktop)       • macos                     • darwin-arm64   • macOS 14.2.1 23C71 darwin-arm64
    • Chrome (web)          • chrome                    • web-javascript • Google Chrome 122.0.6261.112
    ! Error: Browsing on the local area network for Dina's (2). Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)

[✓] Network resources
    • All expected network resources are available.

• No issues found!

I checked this on both Android and iOS but couldn't reproduce the issue with below minimal sample code. Please also try this sample code on your end and confirm.

Sample code
import 'package:flutter/material.dart';

void main() async {
  runApp(
    const MaterialApp(
      title: 'Flutter Demo',
      home: Home(),
    ),
  );
}

class Home extends StatelessWidget {
  const Home({
    super.key,
  });

  @override
  Widget build(BuildContext context) {
    final padding = MediaQuery.of(context).viewInsets.bottom;
    return Scaffold(
      body: Center(
        child: SingleChildScrollView(
            child: Column(
          children: [
            TextFormField(obscureText: false),
            TextFormField(obscureText: true),
            Container(
              padding: EdgeInsets.only(bottom: padding),
              child: Text('padding: $padding', style: TextStyle(fontSize: 16)),
            ),
          ],
        )),
      ),
    );
  }
}

Demo (Pixel 7, Android 14 - issue is not reproduced)
https://github.com/flutter/flutter/assets/104349824/2652e49f-d593-428b-8fdf-ae23e571bd95


Don't apply syntax highlighting on addContext strings

This is a follow-up from my previous issue, #35, where I briefly covered the issue with syntax highlighting on contexts added using addContext.
For example, this is what I am passing in:
addContext(this, {
    title: "HTTP Response",
    value: "HTTP/1.1 403 Forbidden\n...."
});

The following is an example of how syntax highlighting is wrongly applied:

This is what I would expect:

To summarize, there are currently 4 types of contexts that can be added:

Simple string, i.e. addContext(this, 'this is a string'), which will not apply syntax highlighting
Image URL, i.e. addContext(this, 'https://images.com/cheezburger.gif')
URL, i.e. addContext(this, https://google.com)
Object with the following schema:

addContext(this, {
    title: "My Title",
    value: "" // anything here
})

which will render a context with a h4 header, as shown above.

The problem arises when I use the 4th option (using an object) with a string, which causes the string to have JS highlighting when it is not supposed to.
A simple fix would be to turn off syntax highlighting for all string-typed value values by default, until we offer a third "options" argument for addContext (which we also discussed previously).
In other words, the following is my suggested implementation for renderContextContent in components/test/context.jsx:
renderContextContent = (content, title) => {
  // Images
  if (imgRegEx.test(content)) {
    return this.renderImage(content, title);
  }

  // URLs
  if (urlRegEx.test(content)) {
    return this.renderLink(content, title);
  }

  // Simple strings
  if (isString(content)) {
    return <CodeSnippet className={ cx('code-snippet') } code={ content } highlight={ false } />;
  }

  // All other types, including primitives, objects and arrays should have syntax highlighting
  const code = JSON.stringify(content, null, 2);
  return (
    <CodeSnippet className={ cx('code-snippet') } code={ code } highlight />
  );
}

This might make sense because most people might be using this method to be passing in either strings, primitives, objects or arrays. For all types except for strings, applying syntax highlighting is fine and even encouraged, but as for strings, I'm not sure whether users will use it to pass in JavaScript code.
Do correct me if I'm wrong about that. Otherwise, I could create a PR if you are agreeable with this.

@irvinlim I was working on some other additions so I added this as well. Thanks for the write up!

Published v2.2.0 with this change


Feature: Add Maximum Change Limit and Optimization for Lexical History Plugin

Description
After reading this article, I traced where memory usage increases and found that it differs depending on whether the Lexical history plugin is enabled in the production build environment.
It would be helpful if the Lexical history plugin had an option to set a maximum limit on change history. Additionally, optimizing how changes are stored could improve performance.
Use HistoryPlugin

None HistoryPlugin

Impact
This feature would enhance the user experience when editing large documents by providing smoother performance.

It is possible to manage the history size without any additions, since the data structures are public. Something like this (untested):
function pruneHistoryListener({redoStack, undoStack}: HistoryState, maxHistory: number): UpdateListener {
  return () => {
    redoStack.length = Math.max(0, Math.min(maxHistory, redoStack.length));
    undoStack.length = Math.max(0, Math.min(maxHistory - redoStack.length, undoStack.length));
  };
}

function LimitedHistoryPlugin(props: {
  delay?: number = 1000;
  maxHistory?: number = 50;
  externalHistoryState?: HistoryState;
}) {
  const historyState = useMemo(() => externalHistoryState || createEmptyHistoryState(), [externalHistoryState]);
  const [editor] = useLexicalComposerContext();
  useEffect(() => {
    return mergeRegister(
      registerHistory(editor, historyState, delay),
      editor.registerUpdateListener(pruneHistoryListener(historyState, Math.max(0, maxHistory))),
    );
  }, [editor, historyState, delay, maxHistory]);
  return null;
}

Of course if you were looking for something more precise about memory usage you'd probably want to consider the number of nodes in history (weight each history entry by the size of its nodeMap) rather than the number of history entries. Creating a more efficient data structure than simply referencing all EditorStates is an even better option, but with a lot more complexity.

I tested it based on maxHistory 100, and it was very effective!
Thank you! @etrepum


TS1109: Expression expected in Box.d.ts

Duplicates

[X] I have searched the existing issues

Latest version

[X] I have tested the latest version

Steps to reproduce 🕹
Steps:

Run tsc for an application that uses v5.11.5

Current behavior 😯
3 TS errors in node_modules/@mui/material/Box/Box.d.ts:15:
node_modules/@mui/material/Box/Box.d.ts:15:47 - error TS1005: '>' expected.

15 declare const Box: ReturnType<typeof createBox<MaterialTheme>>;
                                                 ~

node_modules/@mui/material/Box/Box.d.ts:15:62 - error TS1109: Expression expected.

15 declare const Box: ReturnType<typeof createBox<MaterialTheme>>;
                                                                ~

node_modules/@mui/material/Box/Box.d.ts:15:63 - error TS1109: Expression expected.

15 declare const Box: ReturnType<typeof createBox<MaterialTheme>>;

Expected behavior 🤔
tsc should complete without errors
Context 🔦
Probably introduced with https://github.com/mui/material-ui/pull/35532/files#diff-427bcf01d3498e79c0ef95d5426b7bdfc0694f490da7ba41cd44f9957c73ead7 where the ReturnType of a generic function is used.
Your environment 🌎

npx @mui/envinfo
 System:
    OS: Linux 5.15 Ubuntu 20.04.5 LTS (Focal Fossa)
  Binaries:
    Node: 16.18.1 - ~/.nvm/versions/node/v16.18.1/bin/node
    Yarn: 3.3.1 - ~/.nvm/versions/node/v16.18.1/bin/yarn
    npm: 8.19.2 - ~/.nvm/versions/node/v16.18.1/bin/npm
  Browsers:
    Chrome: Not Found
    Firefox: Not Found
  npmPackages:
    @emotion/react:  11.10.5
    @emotion/styled:  11.10.5
    @mui/base:  5.0.0-alpha.114
    @mui/core-downloads-tracker:  5.11.5
    @mui/icons-material:  5.11.0
    @mui/lab:  5.0.0-alpha.116
    @mui/material:  5.11.5
    @mui/private-theming:  5.11.2
    @mui/styled-engine:  5.11.0
    @mui/styles:  5.11.2
    @mui/system:  5.11.5
    @mui/types:  7.2.3
    @mui/utils:  5.11.2
    @types/react: ^17.0.44 => 17.0.52
    react: ^17.0.2 => 17.0.2
    react-dom: ^17.0.2 => 17.0.2
    typescript: ~4.6.4 => 4.6.4

tsconfig:
{
  "compilerOptions": {
    "noEmit": true,
    "allowJs": true,
    "target": "esnext",
    "lib": ["es6", "dom", "esnext"],
    "module": "esnext",
    "moduleResolution": "node",
    "strict": true,
    "pretty": true,
    "skipLibCheck": true,
    "experimentalDecorators": true,
    "allowSyntheticDefaultImports": true,
    "esModuleInterop": true,
    "jsx": "react-jsx",
    "noUnusedLocals": true,
    "resolveJsonModule": true,
    "useUnknownInCatchVariables": false,
    "paths": {
      "@mobilexag/webdispo-core": ["./core/src"],
      "@mobilexag/webdispo-test-util": ["./test-util/src"],
      "test-util": ["./core/test-util"],
      "test-util/*": ["./core/test-util/*"],
      "@mobilex/dispatchx-test-and-story-util": ["./test-and-story-util/src"],
      // find type declarations
      "*": ["./@types/*"],
    }
  },
  "include": [
    "**/*",
    // Normally this isn't required and is already covered by "**/*",
    // but IntelliJ seems to need it or opening .eslintrc.js-Files are decorated
    // with an annoying error message about "parserOptions.project has been set"
    "**/.eslintrc.js"
  ],
  "exclude": [
    "node_modules",
    "**/coverage/*",
    "www/**/*",
    "public/**/*",
    "docker/frontend/www/**/*",
    "core/static"
  ]
}

It seems that the aforementioned commit uses Instantiation Expressions which is a TS 4.7 feature. According to the MUI Guide, the minimal supported TS version is 3.5
After upgrading to<EMAIL_ADDRESS>the error disappears.

Hi @tobiaswaltl
I've tried with TS version 4.7.4 (previously it's 4.5.2) in my local application.
node_modules/@mui/material/Box/Box.d.ts:15:47 - error TS1005: '>' expected.
Error is disappeared.

Thanks for the report and pin-pointing the issue. Would you like to create a PR for it? We can use directly the OverridableComponent type there, instead of the ReturnType generic.

It was fixed in #35877 it will be available in the next release.


Chore/linting

:tada: This PR is included in version 4.0.3 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


When filter property type is relation, not retrieving all relation pages now

bolt-app no more than 100 items allowed

So, do not get all pages to show. Then, retrive a filter page on value search modal.

Now this select shows fetched page names, but I have to retrive filter page on this modal.


Order by size

Hi @SaraVieira ,
It would be interesting to sort by ascending or descending size.

Added support to order by size here: https://github.com/pmndrs/market/commit/bc81eea6f7745cecefa41e1a1e3933459dd6a108
You can't toggle the direction but since that's not possible in any I made this issue:  https://github.com/pmndrs/market/issues/65 and will close this one since it's easier to track


Fix Xbox controllers in Bluetooth mode on macOS (3.x)

3.x version of https://github.com/godotengine/godot/pull/51116.
This prevents the D-pad up arrow from being registered as pressed when it isn't, and pressing any direction from activating the next arrow clockwise of it.
Thanks @dsrw for providing this fix :slightly_smiling_face:

@apertureless You can test this pull request by downloading one of the GitHub Actions builds for the macOS editor. Note that it isn't signed, so you have to perform the usual steps to run unsigned applications on macOS.

@Calinou
Yep this seems to fix the issue (for me).
Dpad is working now as expected.

FWIW this fixes the issue for me as well.

Thanks!

Cherry-picked for 3.3.3.


Expose relay over I2P

Is there something about this already implemented? or would it be from 0?

Nothing yet.


Settlement details modal does not contain sufficient information

The settlement details modal does not contain currency or settlement participant account state. This means that a user cannot more deeply visualize the settlement state. Lack of currency is a fundamental inadequacy.

Should be resolved by: https://github.com/mojaloop/finance-portal-v2-ui/pull/76


feat(monorepo): update to angular 11

PR Checklist
Please check if your PR fulfills the following requirements:

[x] The commit message follows our guidelines: https://github.com/scullyio/scully/blob/main/CONTRIBUTING.md#commit
[x] Tests for the changes have been added (for bug fixes / features)
[ ] Docs have been added / updated (for bug fixes / features)

PR Type
What kind of change does this PR introduce?

[ ] Bugfix
[x] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Other... Please describe:

What is the current behavior?
Angular 10

Issue Number: N/A
What is the new behavior?
Angular 11
Does this PR introduce a breaking change?

[ ] Yes
[ ] No

Other information

When I run against Angular11, the schematics ng add @scullyio/init throws an error at the end. We need to address that before we merge any Angular 11 changes. We need to look at the schematics stuff. @jorgeucano


A string type is always assumed when filtering by a field used as a partition

I am trying to read data from a partitioned dataset in S3 where the partition column is defined as an integer:
UnischemaField('partcol', np.int32, (), ScalarCodec(IntegerType()), False),
The code below executes without exceptions but returns nothing:
with make_reader(dataset_path,
                     workers_count=1,
                     predicate=in_lambda(['partcol'], lambda partcol: (partcol == 20190102))
                     ) as reader:

The following code returns the expected data from the partition:
 with make_reader(dataset_path,
                     workers_count=1,
                     predicate=in_lambda(['partcol'], lambda partcol: (partcol == '20190102'))
                     ) as reader:

Yep, we can address this since we know the type from Unischema.

@GregAru - while trying to reproduce the issue locally, I'm actually seeing the opposite (though still incorrect) behavior, where a string passed as the partition column causes no data to be read, but an integer does:
    with make_reader(PETASTORM_DATASET_PATH,
                     workers_count=1,
                     predicate=in_lambda(['partcol'], lambda partcol: (partcol == '2'))
                     ) as reader:
        for schema_view in reader:
            print("This should return a schema_view:")
            print(schema_view)

    with make_reader(PETASTORM_DATASET_PATH,
                     workers_count=1,
                     predicate=in_lambda(['partcol'], lambda partcol: (partcol == 2))
                     ) as reader:
        for schema_view in reader:
            print("This should never be reached.")
            print(schema_view)

outputs the following:
(petastorm_venv3.6) root@computer:/petastorm# python test.py
This should never be reached.
HelloWorldSchema_view(id=2, partcol=2)

Is this at all consistent with what you are seeing (i.e. is the reported issue backwards)?

@jsgoller1 - Not quite. In my case, the following does not return data:
     with make_reader(PETASTORM_DATASET_PATH,
                     workers_count=1,
                     predicate=in_lambda(['partcol'], lambda partcol: (partcol == 2))
                     ) as reader:
        for schema_view in reader:
            print("This should never be reached.")
            print(schema_view)

Please note that I am reading the dataset from S3 and the dataset is partitioned by partcol

@GregAru  - thanks for the follow-up. I'm still having trouble reproducing this issue. I created a dataset with the following schema:
    UnischemaField('id', np.int32, (), ScalarCodec(IntegerType()), False),
    UnischemaField('partcol', np.int32, (), ScalarCodec(IntegerType()), False)
])```
and then executed my code above, which produces no output when the predicate compares `partcol` to a string, but correctly outputs the single schema view when it compares `partcol` to an int.

I have tried this both via python2.7 and python3.6, as well as locally and reading from S3. Are you able to share your dataset with us so that we can investigate the issue further?

@jsgoller1 , I think I am able to reproduce. Can you please take a look here: https://github.com/selitvin/petastorm/pull/new/repro280 ?

@GregAru This issue should be solved now; please feel free to reopen if it resurfaces.


GlobalDiscovery sample broken

The sample has a number of issues:

Failed to load using Visual Studio 2019, had to use VS 2017
There was a issue with the NugGet package where I had to click some Restore button to avoid build issues with VS 2017
The sample was recently updated here to replace the Authority URL.
Old value: https://login.windows.net/common
New value: https://login.microsoftonline.com

Sample wouldn't run until I switched back to the old value

This sample really ought to be updated to use the newer version of ADAL, then remove all the App.Config since this sample isn't using CrmServiceClient anyway.

Addressed with this PR: https://github.com/microsoft/PowerApps-Samples/pull/66 to remove the root issue


ci: force checkout the filter example specified commit

A later stage in the script modifies WORKSPACE in the filter-example directory;
if this directory persists between builds, this may cause the checkout of
a particular commit to fail due to modified local workspace.
Signed-off-by: Greg Greenway<EMAIL_ADDRESS>Risk Level: Low
Testing: Manually tested in broken scenario

It seems odd that the directory would persist between builds. Is this just when run locally?


Improve tests

If we rewrote the various shell scripts in Python, we'd be able to more accurately test things using mocks (e.g. mockfs). Also okay with moving to a different test framework.

Would you be happy with pytest? It's kind of the de facto standard these days.

Yep, totally happy with using pytest.


Enable Retrieving Total Supply Information

Closes https://github.com/bonedaddy/go-indexed/issues/39

Codecov Report

Merging #40 (f9f53a8) into main (6d45d6c) will decrease coverage by 0.49%.
The diff coverage is 2.85%.

@@            Coverage Diff             @@
##             main      #40      +/-   ##
==========================================
- Coverage   21.26%   20.76%   -0.50%
==========================================
  Files          21       21
  Lines        1213     1247      +34
==========================================
+ Hits          258      259       +1
- Misses        911      944      +33
  Partials       44       44

Impacted Files
Coverage Δ

bclient/bclient.go
63.33% <0.00%> (-1.08%)
:arrow_down:

bclient/pool.go
62.71% <ø> (ø)

discord/governance.go
0.00% <0.00%> (ø)

discord/pool.go
0.00% <0.00%> (ø)

discord/discord.go
0.42% <14.28%> (+0.42%)
:arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6d45d6c...f9f53a8. Read the comment docs.

Codecov Report

Merging #40 (f9f53a8) into main (6d45d6c) will decrease coverage by 0.49%.
The diff coverage is 2.85%.

@@            Coverage Diff             @@
##             main      #40      +/-   ##
==========================================
- Coverage   21.26%   20.76%   -0.50%
==========================================
  Files          21       21
  Lines        1213     1247      +34
==========================================
+ Hits          258      259       +1
- Misses        911      944      +33
  Partials       44       44

Impacted Files
Coverage Δ

bclient/bclient.go
63.33% <0.00%> (-1.08%)
:arrow_down:

bclient/pool.go
62.71% <ø> (ø)

discord/governance.go
0.00% <0.00%> (ø)

discord/pool.go
0.00% <0.00%> (ø)

discord/discord.go
0.42% <14.28%> (+0.42%)
:arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6d45d6c...f9f53a8. Read the comment docs.