diff --git a/docs/en/migration-guides/release-6.x/6.0/tools.rst b/docs/en/migration-guides/release-6.x/6.0/tools.rst index 043e6e4da8..349b6c05b2 100644 --- a/docs/en/migration-guides/release-6.x/6.0/tools.rst +++ b/docs/en/migration-guides/release-6.x/6.0/tools.rst @@ -23,3 +23,10 @@ On Linux or MacOS, you can use Python 3.11 or 3.12 and gdbgui version 0.15.2.0. Please be aware that these recommendations may change over time and for an up-to-date list of issues refer to `the official issue tracker `_. We recommend to use ``idf.py gdb`` instead of ``idf.py gdbgui``, or debug in Eclipse/Vscode if you encounter an issue with the installation. + +``idf.py efuse*`` Commands Require Port +--------------------------------------- + +All commands with eFuse functionality now require a serial port to be specified. This was done to prevent accidental use of the wrong port, as these operations are irreversible. + +For all ``idf.py efuse*`` commands, you now need to specify the serial port with the ``--port`` argument (or ``ESPPORT`` environment variable). If the port is not specified, the command will fail with an error message. diff --git a/tools/idf_py_actions/serial_ext.py b/tools/idf_py_actions/serial_ext.py index e503f7cffd..d670ca20cc 100644 --- a/tools/idf_py_actions/serial_ext.py +++ b/tools/idf_py_actions/serial_ext.py @@ -515,7 +515,10 @@ def action_extensions(base_actions: Dict, project_path: str) -> Dict: if args.port: efuse_args += ['-p', args.port] elif not args.port and not extra_args['virt']: # if --virt, no port will be found and it would cause error - efuse_args += ['-p', get_default_serial_port()] + raise FatalError( + 'Error: Port is required for espefuse. ' + 'Please specify the port with the --port argument.' + ) efuse_args += ['--chip', _get_project_desc(ctx, args)['target']] if extra_args['virt']: efuse_args += ['--virt'] @@ -712,7 +715,7 @@ def action_extensions(base_actions: Dict, project_path: str) -> Dict: }, { 'names': ['--flash-crypt-conf'], - 'help': ('Override FLASH_CRYPT_CONF efuse value (default is 0XF).'), + 'help': ('Override FLASH_CRYPT_CONF eFuse value (default is 0XF).'), }, ], 'arguments': [