Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

0

ModelOperationFailedDueToInvalidCapacityException for pbix file upload through post import

Hi Team,

 

We have suddenly started getting this ModelOperationFailedDueToInvalidCapacityException error, for last couple of days.

 

I couldnt find anything specific for this error code in documentation.

 

Below is the request we are making:-

URL:-

 

 

 'https://api.powerbi.com/v1.0/myorg/groups/<group_id>/imports?datasetDisplayName=SST1I_visualizations_71161cd5-2066-469c-91af-03195db29577.pbix'

 

 

Headers:- 

 

 

{'User-Agent': 'python-requests/2.22.0', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Authorization': 'Bearer Some Valid Token', 'Content-Type': 'multipart/form-data', 'Content-Length': '590892'}

 

 

file:- bytecode of pbix file 

Request:-

 

 

response = requests.post(
                    endpoint, headers=self._headers, files={'file': file}
                )

 

 

Response:-

 

 

'{"error":{"code":"ModelOperationFailedDueToInvalidCapacityException","pbi.error":{"code":"ModelOperationFailedDueToInvalidCapacityException","parameters":{},"details":[],"exceptionCulprit":1}}}'

 

 

 

Status: Delivered

Hi @ShubhamKapadnis 

I am so glad to hear that you have fixed your issue . I will change the status to "Delivered" so that users with the same problem can use your method to deal with their problem .

 

Best Regards,
Community Support Team _ Ailsa Tao

Comments
v-yetao1-msft
Community Support
Status changed to: Investigating

Hi @ShubhamKapadnis 

Please check whether you violate the relevant restrictions .

https://learn.microsoft.com/en-us/rest/api/power-bi/imports/post-import-in-group#limitations

 

Best Regards,
Community Support Team _ Ailsa Tao

ShubhamKapadnis
Frequent Visitor

Hi, 

Thanks for replying,

 

The templaqte file we are using, we are uploading it from local file system and not importing from one drive, it also dont have sensitive labels to it.

 

I would like to know more about the first limitations

  • Dataflows with service principal aren't supported.

The file we are uploading is same for last couple of months and had no issues, the issue started couple of days back.

 

Can it bt that the issue is with the SKU being paused or any permissions which i read somewhere here in the community, I can share tenant id, group details if required.

ShubhamKapadnis
Frequent Visitor

Hi, 

 

This is resolved now, someone had disablerd the account/SKU in POWERBI embeded, enabling it resolved the issue

v-yetao1-msft
Community Support
Status changed to: Delivered

Hi @ShubhamKapadnis 

I am so glad to hear that you have fixed your issue . I will change the status to "Delivered" so that users with the same problem can use your method to deal with their problem .

 

Best Regards,
Community Support Team _ Ailsa Tao