mycroft-core icon indicating copy to clipboard operation
mycroft-core copied to clipboard

mycroft-config using deprecated --tempfile when falling back to nano

Open smokejohn opened this issue 3 years ago • 0 comments

Describe the bug In the case where mycroft-config tries to use nano because sensible-editor is not available on the system it uses the deprecated --tempfile parameter which newer versions of nano don't recognize anymore.

To Reproduce Steps to reproduce the behavior:

  1. Fresh install ArchLinuxARM-rpi-armv7-latest or any system without sensible-editor and nano >= 5.0
  2. mycroft-config edit user
  3. nano doesn't start and prints error about unrecognized option
nano: unrecognized option '--tempfile'
Type 'nano -h' for a list of available options.
Configuration unchanged.

Expected behavior Open mycroft config with nano without erroring out.

Fix

  • replace deprecated --tempfile with --saveonexit
  • https://www.nano-editor.org/news.php (was deprecated and changed on July 29, 2020)

Environment:

  • Device type: Raspberry PI 3b
  • OS: ArchLinuxARM-rpi-armv7-latest
  • Mycroft-core version: [21, 2, 2]

smokejohn avatar Aug 09 '22 22:08 smokejohn