Skip to main content

We have been putting together a transformer using the FME Packages SDK using FME Packages SDK Guide. As part of the package we are using the fmeobjects.FMEUniversalReader to read features. When we pipe the features to pyoutput to one of the transformers output ports all the attributes are not exposed. As the UnversalReader in our package references parameters in the transformer the attributes will not be consistent. Is there a way to make the attributes exposed on the output?

Thanks

Brad

Hi ​@brad.cartledge 

Are you using a PythonCaller or PythonCreator for this? If so, please share a screenshot of how you set that up. Can you also share a screenshot of your workspace? 


Hi ​@crystalatsafe 

We are using neither of these transformers in our workspace. We have created this transformer using the Transformer Designer. 

The execution instructions for the transformer uses the PythonFactory

FACTORY_DEF {*} TeeFactory
FACTORY_NAME { $(XFORMER_NAME)_ExternalData_CATCHER }
$(INPUT_ExternalData_LINES)
OUTPUT { FEATURE_TYPE $(XFORMER_NAME)_ExternalData_READY
@SupplyAttributes(___XF_VERSION, 1)
$(FME_PARM_VAL_LIST)
}

FACTORY_DEF {*} TeeFactory
FACTORY_NAME { $(XFORMER_NAME)_ExternalSchema_CATCHER }
$(INPUT_ExternalSchema_LINES)
OUTPUT { FEATURE_TYPE $(XFORMER_NAME)_ExternalSchema_READY
@SupplyAttributes(___XF_VERSION, 1)
$(FME_PARM_VAL_LIST)
}

FACTORY_DEF {*} PythonFactory
FACTORY_NAME { $(XFORMER_NAME)_DATA_PROCESSOR }
PY_INPUT_TAGS { ExternalData ExternalSchema }
INPUT { ExternalData FEATURE_TYPE $(XFORMER_NAME)_ExternalData_READY }
INPUT { ExternalSchema FEATURE_TYPE $(XFORMER_NAME)_ExternalSchema_READY }
SYMBOL_NAME fme_datasetvalidator.transformer.DataProcessor
PY_OUTPUT_TAGS { Report Statistics ExternalData LiveData }
OUTPUT { Report FEATURE_TYPE $(OUTPUT_Report_FTYPE)
@RemoveAttributes(fme_regexp_match,^___XF_.*$)
$(OUTPUT_Report_FUNCS) }
OUTPUT { Statistics FEATURE_TYPE $(OUTPUT_Statistics_FTYPE)
@RemoveAttributes(fme_regexp_match,^___XF_.*$)
$(OUTPUT_Statistics_FUNCS) }
OUTPUT { ExternalData FEATURE_TYPE $(OUTPUT_ExternalData_FTYPE)
@RemoveAttributes(fme_regexp_match,^___XF_.*$)
$(OUTPUT_ExternalData_FUNCS) }
OUTPUT { LiveData FEATURE_TYPE $(OUTPUT_LiveData_FTYPE)
@RemoveAttributes(fme_regexp_match,^___XF_.*$)
$(OUTPUT_LiveData_FUNCS) }

It is within our python script located at fme_datasetvalidator.transformer.DataProcessor that we create reader object using FMEObjects.FMEUniversalReader fmeobjects.FMEUniversalReader — Python FME API FME 2024.2 b24791 documentation to read features based on the transformer parameters. The features are then output using pyoutput to the ‘LiveData’ port.

It looks like as we are reading features only within the transformer rather than have them passed through the transformer they are output with unexposed attributes. 

Thanks for taking the time to take a look at this for us, please let us know if there is any other information we can provide.

Thanks

Brad


Hi ​@brad.cartledge 

Thanks for reporting this.
I found a related enhancement request for this in our system (internal reference IDEA-330). There currently isn't a specific timeline for this request, but I've linked this thread as a reference in the ticket.

We will try updating you if and when we implement this enhancement.


Hi ​@crystalatsafe 

Thanks for taking the time and linking this with an existing enhancement request. We will keep an eye out for any updates.

Thanks

Brad


You're welcome ​@brad.cartledge 
Happy to help!