question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

enable-managed-identity true causes 'ApiManagementServiceResource' object does not support item assignment

See original GitHub issue

This is autogenerated. Please review and update as needed.

Describe the bug

When running az apim create with --enabled-managed-identity true you get the below error

Command Name az apim create

Errors:

'ApiManagementServiceResource' object does not support item assignment
Traceback (most recent call last):
Temp\pip-install-z6h9b3s8\knack\knack\cli.py, ln 215, in invoke
azure\cli\core\commands\__init__.py, ln 631, in execute
azure\cli\core\commands\__init__.py, ln 695, in _run_jobs_serially
azure\cli\core\commands\__init__.py, ln 688, in _run_job
Local\Temp\pip-install-z6h9b3s8\six\six.py, ln 703, in reraise
azure\cli\core\commands\__init__.py, ln 665, in _run_job
azure\cli\core\commands\__init__.py, ln 324, in __call__
azure-cli-core\azure\cli\core\__init__.py, ln 574, in default_command_handler
azure\cli\command_modules\apim\custom.py, ln 31, in create_apim
TypeError: 'ApiManagementServiceResource' object does not support item assignment

To Reproduce:

Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.

  • Put any pre-requisite steps here…
  • az apim create --name "any" --publisher-email "any@example.com" --publisher-name "any" -g "any" --enable-managed-identity true

Expected Behavior

Should deploy a new APIM instance

NOTE: Using az apim update --enable-managed-identity true ... doesn’t return error

Environment Summary

Windows-10-10.0.18362-SP0
Python 3.6.6
Installer: MSI

azure-cli 2.4.0 *

Additional Context

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:8 (1 by maintainers)

github_iconTop GitHub Comments

5reactions
sirezacommented, Oct 14, 2020

Just experienced the same issue, would appreciate an update on this. Thanks

0reactions
jt000commented, Feb 17, 2022

@navba-MSFT, You are correct, I no long am able to reproduce this issue. Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Object does not support item assignment error - Stack Overflow
The error seems clear: model objects do not support item assignment. MyModel.objects.latest('id')['foo'] = 'bar' will throw this same error.
Read more >
Python 'str' object does not support item assignment solution
Let's start by taking a look at our error: Typeerror: 'str' object does not support item assignment. This error message tells us that...
Read more >
Python TypeError: 'str' object does not support item assignment
Python TypeError: 'str' object does not support item assignment.
Read more >
PYTHON : 'str' object does not support item assignment
PYTHON : 'str' object does not support item assignment [ Gift : Animated Search Engine : https://www.hows.tech/p/recommended.html ] PYTHON ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found