SharePoint Data Source Environment variables Choices field issue

%3CLINGO-SUB%20id%3D%22lingo-sub-2527348%22%20slang%3D%22en-US%22%3ESharePoint%20Data%20Source%20Environment%20variables%20Choices%20field%20issue%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2527348%22%20slang%3D%22en-US%22%3E%3CP%3EHi%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EWe%20are%20trying%20to%20create%20a%20solution%20package%20for%20our%20SharePoint%20list%20based%20Canvas%20app%20so%20that%20we%20can%20deploy%20this%20solution%20from%20Dev%20to%20Prod%20environment%20by%20just%20updating%20the%20environment%20variables%20SharePoint%20Site%20and%20List%20data%20source%20while%20importing%20the%20solution.%20We%20are%20using%26nbsp%3BSharePoint%20Data%20Source%20Environment%20variables%20for%20this%20task%20so%20that%20there%20would%20not%20be%20any%20need%20to%20update%20the%20data%20source%20after%20the%20app%20is%20imported%20to%20production.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ERef%20Link%3A%26nbsp%3B%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fmatthewdevaney.com%2Fsimplify-importing-exporting-power-apps-with-datasource-environment-variables%2F%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fmatthewdevaney.com%2Fsimplify-importing-exporting-power-apps-with-datasource-environment-variables%2F%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EEverything%20works%20fine%20but%20when%20we%20are%20tested%20our%20app%20deployed%20in%20the%20production%2C%20we%20found%20Choices%20fields%20in%20the%20app%20were%20creating%20issues%20for%20us.%20It%20seems%20choice%20field%20is%20still%20trying%20to%20get%20the%20reference%20from%20old%20dev%20site%20list%20GUID.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22ChoicesError.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F294250iE420AD80D0BEF790%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22ChoicesError.png%22%20alt%3D%22ChoicesError.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAny%20help%20will%20be%20appreciated%20to%20resolve%20this%20issue.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2527348%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3ESharePoint%20Data%20Source%20Environment%20Variable%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2531855%22%20slang%3D%22en-US%22%3ERe%3A%20SharePoint%20Data%20Source%20Environment%20variables%20Choices%20field%20issue%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2531855%22%20slang%3D%22en-US%22%3EI%20have%20the%20same%20Issue%2C%3CBR%20%2F%3ELooking%20a%20little%20bit%20deeper%20with%20the%20Monitor%20offers%20the%20following%20Information%20when%20calling%20Operation%20%22%20getLookupResults%22.%3CBR%20%2F%3E%3CBR%20%2F%3E%7B%3CBR%20%2F%3E%22Message%22%3A%20%22Missing%20Authorization%20header%20for%20a%20privileged%20call%20on%20connection.%22%2C%3CBR%20%2F%3E%22Source%22%3A%20%22product%20policy%22%3CBR%20%2F%3E%7D%3CBR%20%2F%3E%3CBR%20%2F%3EIn%20DEV%20Environment%20Result%20is%20200%2C%20using%20the%20Same%20in%20PROD%20environment%20the%20result%20is%20404.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2541413%22%20slang%3D%22en-US%22%3ERe%3A%20SharePoint%20Data%20Source%20Environment%20variables%20Choices%20field%20issue%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2541413%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F850845%22%20target%3D%22_blank%22%3E%40Matthias%3C%2FA%3E%26nbsp%3BThanks%20for%20the%20response.%20We%20are%20also%20exactly%20getting%20404%20for%20prod%20and%20200%20for%20dev%20environment.%20It%20seems%20we%20have%20to%20wait%20for%20a%20fix%20for%20this%20from%20PowerApps%20team%20before%20using%20this%20feature%20in%20solutions.%3C%2FP%3E%3C%2FLINGO-BODY%3E
New Contributor

Hi,

 

We are trying to create a solution package for our SharePoint list based Canvas app so that we can deploy this solution from Dev to Prod environment by just updating the environment variables SharePoint Site and List data source while importing the solution. We are using SharePoint Data Source Environment variables for this task so that there would not be any need to update the data source after the app is imported to production.

 

Ref Link: 

https://matthewdevaney.com/simplify-importing-exporting-power-apps-with-datasource-environment-varia...

 

Everything works fine but when we are tested our app deployed in the production, we found Choices fields in the app were creating issues for us. It seems choice field is still trying to get the reference from old dev site list GUID.

 

ChoicesError.png

 

Any help will be appreciated to resolve this issue.

 

Thanks

 

2 Replies
I have the same Issue,
Looking a little bit deeper with the Monitor offers the following Information when calling Operation " getLookupResults".

{
"Message": "Missing Authorization header for a privileged call on connection.",
"Source": "product policy"
}

In DEV Environment Result is 200, using the Same in PROD environment the result is 404.

@Matthias Thanks for the response. We are also exactly getting 404 for prod and 200 for dev environment. It seems we have to wait for a fix for this from PowerApps team before using this feature in solutions.