LightningFlowComponents icon indicating copy to clipboard operation
LightningFlowComponents copied to clipboard

*Datatable* - Configuration error: Screen component contains type mapping 'T' that is not an 'SObject'

Open Duha-H opened this issue 2 years ago • 10 comments

Hi! My team and I have found a great deal of benefit in using your Flow screen components, so thanks for putting together such a helpful resource!

We've oddly been encountering an intermittent issue with the Datatable component, specifically in the configuration of v3.2.1. The component had been behaving as expected, up until ~3 weeks ago when we started noticing the error Screen component contains type mapping 'T' that is not an 'SOBJECT' when configuring the Datatable to work for any Standard object: Screen Shot 2021-08-20 at 6 08 43 AM

We're also encountering the same error when installing the Datatable_Configuration_Wizard Flow into any of our orgs, with the error message being: (Datatable_Configuration_Wizard) WizardTable (Screen Component) - Screen component 'WizardTable' contains type mapping 'T' that is not an 'SOBJECT'. We've noticed that the Configuration Wizard Flow is also configured to use the User object as the default type mapping.

Not entirely sure if this is something you'd be able to help out with, but thought I'd create the issue to see if it's something anyone has encountered or would be able to provide some insight about.

Any help or insight is appreciated!

Steps to reproduce

Steps to reproduce the behavior (not consistently reproducible):

  1. Add the Datatable component to a Flow screen
  2. Select any standard object when configuring the table (Account, Contact, etc.)
  3. Configure any number of columns to display, and save the screen
  4. Save your Flow updates

Expected behaviour

Flow should save updates with no issue, and correctly display the datatable and its contents when run.

Actual behaviour

Flow presents the error below on Save: Screen Shot 2021-08-20 at 6 08 43 AM

Duha-H avatar Sep 02 '21 13:09 Duha-H

@alexed1 Any ideas on what would casue this?

ericrsmith35 avatar Sep 03 '21 22:09 ericrsmith35

Nothing comes to mind right now.... the fact that it's intermittent is troubling

alexed1 avatar Sep 04 '21 01:09 alexed1

Hi @ericrsmith35! Wondering if you could elaborate on that a bit more? Does that mean that it's a known issue? And any ideas on how to go about potentially resolving that?

Duha-H avatar Sep 05 '21 20:09 Duha-H

Sorry that was for a different issue.

ericrsmith35 avatar Sep 05 '21 20:09 ericrsmith35

Try deleting the Datatable Configuration Wizard flow from your org and reinstall Datatable.

ericrsmith35 avatar Sep 05 '21 20:09 ericrsmith35

I've done some additional testing, and I think I've narrowed the behaviour down to something slightly more predictable.

Our team has been deploying the datatable source code itself to our orgs, most of which are namespaced orgs. When using the datatable source code in a namespaced package, that is when installations fail with the error above. However, when installing it via a no-namespace/unmanaged package, installations work as expected.

I believe that what we thought was intermittent behaviour, might have just been the switch between namespace/no-namespace orgs and managed/unmanaged code. Below is a list of the combinations I've tested out:

Org/Package Installation/Deploy Successful
No-namespace org, No-namespace package
No-namespace org, Namespaced package
Namespaced org, Namespaced package

My guess is that the data type mapping mechanism appends the package's namespace to the object name, even when it's a standard object, and consequently fails to recognize it as an sObject. Although I could be way off base and it's something else entirely. However, if this is in fact the culprit here, then this feels like more of a Salesforce issue than a Datatable issue.

Duha-H avatar Sep 07 '21 14:09 Duha-H

We are currently getting the same error when attempting to display a collection of the standard Location object records in sandbox nor production. So far we haven't been able to replicate the error with any other object.

"Screen component 'datatableJobsites' contains type mapping 'T' that is not an 'SOBJECT'."

In Sandbox we're running the following versions: Datatable Version 4.0.8 FlowActionsBaseBack Version 3.1 Managed FlowScreenComponentsBasePack Version 3.0.7 Unmanaged (Currently unable to upgrade to 3.0.8)

Any updates on how to get around this issue?

LBingCoolJ avatar Jul 20 '22 12:07 LBingCoolJ

The Location object is not supported by Datatable. You will need to convert the records to JSON in the flow and use the apex-defined or string methods to display the records.

On Wed, Jul 20, 2022 at 8:32 AM LBingCoolJ @.***> wrote:

We are currently getting the same error when attempting to display a collection of the standard Location object records in sandbox nor production. So far we haven't been able to replicate the error with any other object.

"Screen component 'datatableJobsites' contains type mapping 'T' that is not an 'SOBJECT'."

In Sandbox we're running the following versions: Datatable Version 4.0.8 FlowActionsBaseBack Version 3.1 Managed FlowScreenComponentsBasePack Version 3.0.7 Unmanaged (Currently unable to upgrade to 3.0.8)

Any updates on how to get around this issue?

— Reply to this email directly, view it on GitHub https://github.com/alexed1/LightningFlowComponents/issues/893#issuecomment-1190228892, or unsubscribe https://github.com/notifications/unsubscribe-auth/AF4UHX2UDAWE2AOVR6ORVIDVU7WVLANCNFSM5DJCW4ZA . You are receiving this because you modified the open/close state.Message ID: @.***>

ericrsmith35 avatar Jul 20 '22 13:07 ericrsmith35

Got it. Thank you for the quick reply!! Out of curiosity - why isn't that object supported?

LBingCoolJ avatar Jul 20 '22 13:07 LBingCoolJ

Salesforce “standard” objects aren’t so standard.

On Wed, Jul 20, 2022 at 9:11 AM LBingCoolJ @.***> wrote:

Got it. Thank you for the quick reply!! Out of curiosity - why isn't that object supported?

— Reply to this email directly, view it on GitHub https://github.com/alexed1/LightningFlowComponents/issues/893#issuecomment-1190269221, or unsubscribe https://github.com/notifications/unsubscribe-auth/AF4UHX6EXR5WSCJY2COGBV3VU73I5ANCNFSM5DJCW4ZA . You are receiving this because you modified the open/close state.Message ID: @.***>

ericrsmith35 avatar Jul 20 '22 13:07 ericrsmith35