dynasist / ALStudio

Development Productivity Suite for Business Central
https://al.studio
6 stars 1 forks source link

Opening page designer fails #23

Open SimonOfHH opened 3 years ago

SimonOfHH commented 3 years ago

Hi @martonsagi

Used version: v0.9.868

I'm having troubles using the page designer (both on existing objects and on newly created ones). If I click on any page in the "object designer" it fails with below error message.

image

The same happens when I'm using the "New" --> "Page" action from the main window:

image

I tested it in an existing workspace and on a newly created one (just used "AL: Go" for a blank app).

Are there any debug-information I can share to help you find the problem?

Cheers Simon

martonsagi commented 3 years ago

Can you send me the output from the Output Window / AL Studio section? Mostly the recent translation manager updates caused some regressions on Page designer. Do you have the generated xlf file in the workspace or it's the state before the first compilation?

SimonOfHH commented 3 years ago

Sorry for not being quicker - I didn't expect such a fast response 😅

Here is the output

[AL Studio][2021-03-03T13:56:40.376Z][Debug]: dbug: Microsoft.AspNetCore.SignalR.Internal.DefaultHubDispatcher[1]
      Received hub invocation: InvocationMessage { InvocationId: "11", Target: "HasValidLicense", Arguments: [  ], StreamIds: [  ] }.

[AL Studio][2021-03-03T13:56:41.185Z][Debug]: dbug: Microsoft.AspNetCore.SignalR.Internal.DefaultHubDispatcher[1]
      Received hub invocation: InvocationMessage { InvocationId: "12", Target: "GetSettings", Arguments: [  ], StreamIds: [  ] }.

[AL Studio][2021-03-03T13:56:41.253Z][Debug]: dbug: Microsoft.AspNetCore.SignalR.Internal.DefaultHubDispatcher[1]
      Received hub invocation: InvocationMessage { InvocationId: "13", Target: "QueryProperties", Arguments: [ ALObjectDesigner.Library.SymbolData ], StreamIds: [  ] }.

[AL Studio][2021-03-03T13:56:41.261Z][Debug]: dbug: Microsoft.AspNetCore.SignalR.Internal.DefaultHubDispatcher[1]
      Received hub invocation: InvocationMessage { InvocationId: "14", Target: "QueryPageDesign", Arguments: [ ALObjectDesigner.Library.SymbolData ], StreamIds: [  ] }.

[AL Studio][2021-03-03T13:56:41.436Z][Debug]: fail: Microsoft.AspNetCore.SignalR.Internal.DefaultHubDispatcher[8]
      Failed to invoke hub method 'QueryPageDesign'.
      System.ArgumentNullException: Value cannot be null. (Parameter 'source')
         at System.Linq.ThrowHelper.ThrowArgumentNullException(ExceptionArgument argument)
         at System.Linq.Enumerable.Where[TSource](IEnumerable`1 source, Func`2 predicate)
         at ALObjectParser.Pro.Converters.DesignConverterService.GetTranslationEntries(IEnumerable`1 filter)
         at ALObjectParser.Pro.Converters.DesignConverterService.UpdatePageDesign(ALPage page)
         at ALStudio.Server.Services.ALObjectService.GetPageDesign(SymbolData info, Boolean skipSourceTable, ALTable parentTable)
         at ALStudio.Server.ALStudioHub.QueryPageDesign(SymbolData info)
         at Microsoft.AspNetCore.SignalR.Internal.DefaultHubDispatcher`1.ExecuteMethod(ObjectMethodExecutor methodExecutor, Hub hub, Object[] arguments)
         at Microsoft.AspNetCore.SignalR.Internal.DefaultHubDispatcher`1.<>c__DisplayClass16_0.<<Invoke>g__ExecuteInvocation|0>d.MoveNext()
SimonOfHH commented 3 years ago

Oh, and I don't have a translation file in that workspace. It's really just a Table.al-file and the app.json basically. Also I didn't build the project before I tested, but the result is the same even if I did build it before trying to access the designer.

SimonOfHH commented 3 years ago

And the next answer: it was a good hint with the translation file 😅 As soon as I activate the feature and generate the Xliff the Designer works 👍

So the problem only comes up, when translations are not active.

martonsagi commented 3 years ago

Thanks for the update. OK, so this is the same bug I'm working on. It'll be fixed this week (before BCBeerinar 😀)