HodorNV / ALOps

ALOps
59 stars 24 forks source link

Urgent: ALOpsAppTest@1 Failing - Unable to find type [AuthenticationScheme] #622

Closed rppwolfs closed 1 year ago

rppwolfs commented 1 year ago

Describe the bug Since 21-03-2023 - Around 4:26 PM CET, ALL our automated test case runs are failing and throwing error messages like

@waldo1001 @AdminHodor

At C:\a_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:18 char:41 $this.Initialize($serviceUrl, ([AuthenticationScheme]::AzureA ...


Unable to find type [AuthenticationScheme].
Unable to find type [ServiceAddressProvider].
Unable to find type [ClientStaticStringControl].

We have not changed anything on our end; but we noticed that ALOps was updated several times yesterday

**the used yaml**

    - task: ALOpsAppTest@1
      timeoutInMinutes: 30
      inputs:
        usedocker: true
        testfilter: "50000..99999"
        import_testtoolkit: false
        failed_test_action: Error
        testpage: 90409
        companyname: AutoTest
        show_available_tests: true
        bc_username: $(ALOPS_DOCKER_ADMINUSER)
        bc_password: $(ALOPS_DOCKER_ADMINPASSWORD)
        bc_authentication: NavUserPassword
        nav_serverinstance: $(ALOPS_DOCKER_NAVSERVERINSTANCE)

And this one:

- task: ALOpsAppTest@1
      timeoutInMinutes: 30
      displayName: "Run TestSuite"
      inputs:
        usedocker: true
        testfilter: "(50000..70099|70301..99999)&<>53051"
        import_testtoolkit: false
        show_available_tests: true
        failed_test_action: Error
        testpage: 90409   

Added two pipeline log's

1. [ALOpsAppTest-Error-01.txt](https://github.com/HodorNV/ALOps/files/11037725/ALOpsAppTest-Error-01.txt)
2. [ALOpsAppTest-Error-02.txt](https://github.com/HodorNV/ALOps/files/11037729/ALOpsAppTest-Error-02.txt)
fvet commented 1 year ago

@waldo1001 @AdminHodor Same here

2023-03-22T07:52:06.2544065Z ##[section]Starting: Run Testsuite Dynavision Advanced Pricing & Discounts-Test
2023-03-22T07:52:06.2674671Z ==============================================================================
2023-03-22T07:52:06.2674942Z Task         : ALOps App Test
2023-03-22T07:52:06.2675143Z Description  : Run AL-TestSuite for Business Central
2023-03-22T07:52:06.2675341Z Version      : 1.455.3529
2023-03-22T07:52:06.2675482Z Author       : Hodor
2023-03-22T07:52:06.2675683Z Help         : Run Business Central Test-Suite and collect results.
2023-03-22T07:52:06.2675962Z ==============================================================================
2023-03-22T07:52:06.9077119Z *** Validate configuration
2023-03-22T07:52:06.9576806Z *** Task Inputs:
2023-03-22T07:52:06.9637145Z 
2023-03-22T07:52:06.9746300Z name                                                            value
2023-03-22T07:52:06.9749205Z ----                                                            -----
2023-03-22T07:52:06.9751848Z usedocker                                                        True
2023-03-22T07:52:06.9754429Z fixed_tag            Dynavision--Dynavision Advanced Pricing--PR_4555
2023-03-22T07:52:06.9756882Z nav_serverinstance                                              BC140
2023-03-22T07:52:06.9759997Z tenant                                                        default
2023-03-22T07:52:06.9761674Z companyname                                                          
2023-03-22T07:52:06.9764004Z profile                                                              
2023-03-22T07:52:06.9766653Z bc_username                                                          
2023-03-22T07:52:06.9769078Z bc_password                                                          
2023-03-22T07:52:06.9772220Z bc_authentication                                     NavUserPassword
2023-03-22T07:52:06.9774729Z bc_webclient_url                                                     
2023-03-22T07:52:06.9776693Z testfilter                                                           
2023-03-22T07:52:06.9778679Z disabledtests                                                        
2023-03-22T07:52:06.9780624Z show_available_tests                                             True
2023-03-22T07:52:06.9782553Z import_testtoolkit                                              False
2023-03-22T07:52:06.9784570Z import_action                                                    Skip
2023-03-22T07:52:06.9786535Z testpage                                                       130455
2023-03-22T07:52:06.9788473Z testsuite                                                     DEFAULT
2023-03-22T07:52:06.9790410Z extensionid                      00627d4f-ef7a-484a-8b22-72ed36b07676
2023-03-22T07:52:06.9792233Z installaltesttool                                               False
2023-03-22T07:52:06.9794139Z failed_test_action                                              Error
2023-03-22T07:52:06.9796059Z override_finsql_path                                                 
2023-03-22T07:52:06.9798155Z resultfilename                                        TestResults.xml
2023-03-22T07:52:06.9801081Z testrunnercodeunitid                                                 
2023-03-22T07:52:06.9801650Z 
2023-03-22T07:52:06.9819527Z 
2023-03-22T07:52:06.9827029Z 
2023-03-22T07:52:06.9971152Z *** For documentation, please visit   : https://www.alops.be/documentation
2023-03-22T07:52:06.9974035Z 
2023-03-22T07:52:07.2519356Z *** ALOps License:
2023-03-22T07:52:07.2536219Z   * Licensed To: Dynavision BV (Project License)
2023-03-22T07:52:07.2540288Z 
2023-03-22T07:52:07.3413393Z *** Memory Status: 25.6/32 (80.02% Free)
2023-03-22T07:52:07.3427029Z *** Importing required PS-Functions
2023-03-22T07:52:07.3667636Z *** Working folder: F:\Build Agents\BUILD-SERVER 1_1\_work\8\s
2023-03-22T07:52:07.3674925Z ***
2023-03-22T07:52:07.3682712Z *** Prepare Docker Session
2023-03-22T07:52:07.4818925Z *** Connect Docker Session
2023-03-22T07:52:07.4891077Z *** Initiate Docker Session
2023-03-22T07:52:07.7013472Z *** Set Docker Container ErrorActionPreference = Stop
2023-03-22T07:52:07.9446575Z *** Copy Modules to Docker
2023-03-22T07:52:10.1126866Z *** Setup Docker Session
2023-03-22T07:52:10.1370429Z *** Checking for container-specific Test Assemblies
2023-03-22T07:52:10.1379869Z *** Using container-specific Test Assemblies
2023-03-22T07:52:10.1546305Z *** Import Modules in Docker Session
2023-03-22T07:52:10.1723245Z *** Import UI Client [C:\Run\DevOps\BCAppTest\bin\Microsoft.Dynamics.Framework.UI.Client.dll]
2023-03-22T07:52:10.1742443Z VERBOSE: Loading module from path 'C:\Run\DevOps\BCAppTest\bin\Microsoft.Dynamics.Framework.UI.Client.dll'.
2023-03-22T07:52:10.5147105Z *** Import NewtonSoft JSON [C:\Program Files\Microsoft Dynamics NAV\210\Service\Newtonsoft.Json.dll]
2023-03-22T07:52:10.5269384Z *** Import Modules in Docker Session: class_ClientContext
2023-03-22T07:52:10.6214993Z ##[error]At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:18 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::AzureA ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:22 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::AzureA ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:26 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::UserNa ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:30 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::UserNa ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:34 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::Window ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:38 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::Window ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:41 char:39
+     Initialize([string] $serviceUrl, [AuthenticationScheme] $authenti ...
+                                       ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:43 char:29
+         $this.addressUri = [ServiceAddressProvider]::ServiceAddress($ ...
+                             ~~~~~~~~~~~~~~~~~~~~~~
Unable to find type [ServiceAddressProvider].

At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:163 char:82
+ ... edControls | Where-Object { $_ -is [ClientStaticStringControl] } | Se ...
+                                         ~~~~~~~~~~~~~~~~~~~~~~~~~
Unable to find type [ClientStaticStringControl].

At F:\Build Agents\BUILD-SERVER 1_1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:169 char:88
+ ... edControls | Where-Object { $_ -is [ClientStaticStringControl] } | Se ...
+                                         ~~~~~~~~~~~~~~~~~~~~~~~~~
Unable to find type [ClientStaticStringControl].

Not all parse errors were reported.  Correct the reported errors and try again.
2023-03-22T07:52:10.6388323Z ##[section]Finishing: Run Testsuite Dynavision Advanced Pricing & Discounts-Test
PeterConijn commented 1 year ago

@waldo1001 Same here

VERBOSE: Loading module from path 'C:\Run\DevOps\BCAppTest\bin\Microsoft.Dynamics.Framework.UI.Client.dll'.
*** Import NewtonSoft JSON [C:\Program Files\Microsoft Dynamics NAV\210\Service\Newtonsoft.Json.dll]
*** Import Modules in Docker Session: class_ClientContext
##[error]At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:18 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::AzureA ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:22 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::AzureA ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:26 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::UserNa ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:30 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::UserNa ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:34 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::Window ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:38 char:41
+         $this.Initialize($serviceUrl, ([AuthenticationScheme]::Window ...
+                                         ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:41 char:39
+     Initialize([string] $serviceUrl, [AuthenticationScheme] $authenti ...
+                                       ~~~~~~~~~~~~~~~~~~~~
Unable to find type [AuthenticationScheme].

At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:43 char:29
+         $this.addressUri = [ServiceAddressProvider]::ServiceAddress($ ...
+                             ~~~~~~~~~~~~~~~~~~~~~~
Unable to find type [ServiceAddressProvider].

At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:163 char:82
+ ... edControls | Where-Object { $_ -is [ClientStaticStringControl] } | Se ...
+                                         ~~~~~~~~~~~~~~~~~~~~~~~~~
Unable to find type [ClientStaticStringControl].

At C:\ADO_agents\agent1\_work\_tasks\ALOpsAppTest_05bf385f-26f1-474d-a993-49930a16de43\1.455.3529\ps_modules\BCAppTest\53c7cbc7-dd57-4695-b567-600120945e9b.ps1:169 char:88
+ ... edControls | Where-Object { $_ -is [ClientStaticStringControl] } | Se ...
+                                         ~~~~~~~~~~~~~~~~~~~~~~~~~
Unable to find type [ClientStaticStringControl].

Not all parse errors were reported.  Correct the reported errors and try again.
kaspermoerch commented 1 year ago

Also experiencing this issue.

rppwolfs commented 1 year ago

@waldo1001 / @AdminHodor: Is this related to the issue #621 ?

NAVFreak commented 1 year ago

Same here

ninjaniels commented 1 year ago

We are also experiencing this issue on pipelines that have been running error free for a long time

AdminHodor commented 1 year ago

Dear @kaspermoerch , @fvet , @NAVFreak , @ninjaniels , @PeterConijn,

We just released a hotfix (v1.455.3559) which should solve the Assembly-Reference issue in all tasks. Please let us know if this release works for you.

Kind regards,

ninjaniels commented 1 year ago

Hotfix is working for us. Thank you for speedy action

acjdekorte commented 1 year ago

Hotfix is working for us as well. Thank you for your work

rppwolfs commented 1 year ago

Hi,

Initial error message is gone; but we are now receiving this error on multiple builds (all with the same error message)

Show form {00016129-0000-0000-0108-0000836BD2D2} Title: MV Test Tool Page Edit - Test Tool - DEFAULT Apply filter for Test-Codeunits: [(50000..70099|70301..99999)&<>53051] ##[error]Run-Test-Exception: Exception calling ".ctor" with "2" argument(s): "Value cannot be null. Parameter name: logicalControl" * Get XUnit Test file from [] to [C:\a\6\s] ##[error]Cannot bind argument to parameter 'Path' because it is null.**

PS: BC version we use is V14. (Is this why you did not mention me when posting that a fix was released ?)

@AdminHodor @waldo1001

NAVFreak commented 1 year ago

image

PeterConijn commented 1 year ago

It works again! \o/

image

AdminHodor commented 1 year ago

Dear @rppwolfs,

Fix for v14 is on its way, we will release a couple of hotfixes concerning the Test-Module. We'll ping you about this as soon as this specific fix is online

Kind regards,

AdminHodor commented 1 year ago

Dear @rppwolfs ,

Please try our latest release v1.455.3571.

Kind regards,

rppwolfs commented 1 year ago

Dear @rppwolfs ,

Please try our latest release v1.455.3571.

Kind regards,

@AdminHodor: Just tested the latest version (v1.455.3571) and i it is working for our generic builds; but not for the extensions we create. We are investigating if we can find out what is happening there. Seems like way more test cases are running for every extension as before.

rppwolfs commented 1 year ago

Dear @rppwolfs , Please try our latest release v1.455.3571. Kind regards,

@AdminHodor: Just tested the latest version (v1.455.3571) and i it is working for our generic builds; but not for the extensions we create. We are investigating if we can find out what is happening there. Seems like way more test cases are running for every extension as before.

Checked the issue and it seems like the testfilter (50000..70099|70301..99999)&<>53051 is not validated. It is running test cases like 53051 / 70202 / 70280 etc which are not in the range set in the testfilter; but it is as well not running the test cases 54763, 54775, 54810, 54812, 54853, 59343 which were running before.

i added the logs of both

Run-TestSuite - Current - ERR.txt Run-TestSuite - Previous - OK.txt

@AdminHodor / @waldo1001

AdminHodor commented 1 year ago

Dear @rppwolfs,

Thanks for detailed description, we managed to replicate the issue based on this. Could you try again with v1.455.3577 ? The test should run exactly as before.

Kind regards,

rppwolfs commented 1 year ago

Dear @rppwolfs,

Thanks for detailed description, we managed to replicate the issue based on this. Could you try again with v1.455.3577 ? The test should run exactly as before.

Kind regards,

Hi, we just tested it (ran a few builds) and everything seems to be back to normal Thanks for the solution / fix.

rppwolfs commented 1 year ago

Issue can be closed - it's solved.