Page MenuHomeVyOS Platform

Python error when trying to add VLANs - UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 2163: ordinal not in range(128)
Closed, WontfixPublicBUG

Description

I am running VyOS rolling from 2020-12-31, on a EdgeCore SAF51015I box.

I get a Python error (UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 2163: ordinal not in range(128)) when I try to add new VLAN configuration to it.

Here is the new configuration I was trying to add:

vyos@vyos# compare
[edit interfaces ethernet eth5]
+vif 10 {
+    address 10.7.10.1/24
+    description OOB_Management
+}
+vif 17 {
+    address 10.7.17.1/24
+    description ‘VM_Traffic’
+}
+vif 19 {
+    address 10.7.19.1/24
+    description Ceph_Traffic
+}
+vif 21 {
+    address 10.7.21.1/24
+    description Corosync_Traffic
+}
+vif 41 {
+    address 10.7.41.1/24
+    description Surveillance_Cameras
+}
+vif 148 {
+    address 10.7.148.1/24
+    description Printers
+}
[edit service dhcp-server]
+shared-network-name VM_Traffic {
+    subnet 10.7.17.0/24 {
+        dns-server 10.7.17.1
+        range 0 {
+            start 10.7.17.50
+            stop 10.7.17.245
+        }
+    }
+    subnet 10.7.78.0/24 {
+        default-router 10.7.17.1
+    }
+}
[edit service dns forwarding]
+allow-from 10.7.17.0/24
+listen-address 10.7.17.1
[edit]

And here is the full error I receive when trying to commit:

vyos@vyos# commit
[ interfaces ethernet eth5 ]
VyOS had an issue completing a command.

We are sorry that you encountered a problem while using VyOS.
There are a few things you can do to help us (and yourself):
- Make sure you are running the latest version of the code available at
  https://downloads.vyos.io/rolling/current/amd64/vyos-rolling-latest.iso
- Consult the forum to see how to handle this issue
  https://forum.vyos.io
- Join our community on slack where our users exchange help and advice
  https://vyos.slack.com

When reporting problems, please include as much information as possible:
- do not obfuscate any data (feel free to contact us privately if your
  business policy requires it)
- and include all the information presented below

Report Time:      2021-01-01 20:45:58
Image Version:    VyOS 1.3-rolling-202012311144
Release Train:    equuleus

Built by:         [email protected]
Built on:         Thu 31 Dec 2020 11:44 UTC
Build UUID:       1cd99908-259b-428d-a49f-b70c00496fca
Build Commit ID:  ba6dab895279f6

Architecture:     x86_64
Boot via:         installed image
System type:      bare metal

Hardware vendor:  Default string
Hardware model:   Default string
Hardware S/N:     EC1916000675
Hardware UUID:    03000200-0400-0500-0006-000700080009

Traceback (most recent call last):
  File "/usr/libexec/vyos/conf_mode/interfaces-ethernet.py", line 121, in <module>
    c = get_config()
  File "/usr/libexec/vyos/conf_mode/interfaces-ethernet.py", line 51, in get_config
    conf = Config()
  File "/usr/lib/python3/dist-packages/vyos/config.py", line 85, in __init__
    self._config_source = ConfigSourceSession(session_env)
  File "/usr/lib/python3/dist-packages/vyos/configsource.py", line 132, in __init__
    session_config_text = self._run([self._cli_shell_api, '--show-working-only', '--show-show-defaults', '--show-ignore-edit', 'showConfig'])
  File "/usr/lib/python3/dist-packages/vyos/configsource.py", line 164, in _run
    return out.decode('ascii')
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 2163: ordinal not in range(128)



[[interfaces ethernet eth5]] failed
[ service dhcp-server ]
VyOS had an issue completing a command.

We are sorry that you encountered a problem while using VyOS.
There are a few things you can do to help us (and yourself):
- Make sure you are running the latest version of the code available at
  https://downloads.vyos.io/rolling/current/amd64/vyos-rolling-latest.iso
- Consult the forum to see how to handle this issue
  https://forum.vyos.io
- Join our community on slack where our users exchange help and advice
  https://vyos.slack.com

When reporting problems, please include as much information as possible:
- do not obfuscate any data (feel free to contact us privately if your
  business policy requires it)
- and include all the information presented below

Report Time:      2021-01-01 20:45:59
Image Version:    VyOS 1.3-rolling-202012311144
Release Train:    equuleus

Built by:         [email protected]
Built on:         Thu 31 Dec 2020 11:44 UTC
Build UUID:       1cd99908-259b-428d-a49f-b70c00496fca
Build Commit ID:  ba6dab895279f6

Architecture:     x86_64
Boot via:         installed image
System type:      bare metal

Hardware vendor:  Default string
Hardware model:   Default string
Hardware S/N:     EC1916000675
Hardware UUID:    03000200-0400-0500-0006-000700080009

Traceback (most recent call last):
  File "/usr/libexec/vyos/conf_mode/dhcp_server.py", line 291, in <module>
    c = get_config()
  File "/usr/libexec/vyos/conf_mode/dhcp_server.py", line 104, in get_config
    conf = Config()
  File "/usr/lib/python3/dist-packages/vyos/config.py", line 85, in __init__
    self._config_source = ConfigSourceSession(session_env)
  File "/usr/lib/python3/dist-packages/vyos/configsource.py", line 132, in __init__
    session_config_text = self._run([self._cli_shell_api, '--show-working-only', '--show-show-defaults', '--show-ignore-edit', 'showConfig'])
  File "/usr/lib/python3/dist-packages/vyos/configsource.py", line 164, in _run
    return out.decode('ascii')
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 2163: ordinal not in range(128)



[[service dhcp-server]] failed
[ service dns forwarding ]
VyOS had an issue completing a command.

We are sorry that you encountered a problem while using VyOS.
There are a few things you can do to help us (and yourself):
- Make sure you are running the latest version of the code available at
  https://downloads.vyos.io/rolling/current/amd64/vyos-rolling-latest.iso
- Consult the forum to see how to handle this issue
  https://forum.vyos.io
- Join our community on slack where our users exchange help and advice
  https://vyos.slack.com

When reporting problems, please include as much information as possible:
- do not obfuscate any data (feel free to contact us privately if your
  business policy requires it)
- and include all the information presented below

Report Time:      2021-01-01 20:46:00
Image Version:    VyOS 1.3-rolling-202012311144
Release Train:    equuleus
10.5.1.104 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBCoL1IqpzUIUG14btkT64Dz3LdoISPoNOiwVo7ma+0a2GpbD5MNcwzzYa96LUs6THu9levvHrvgNLUUBmLL2JCM=
10.7.78.90 ecdsa-sha2-nistp521 AAAAE2VjZHNhLXNoYTItbmlzdHA1MjEAAAAIbmlzdHA1MjEAAACFBAH5jkaCOL9rHWnuunBF6Jt35xUQOq5BRmwXxSl5HugJbaYiX7aP+jboWEIt8lHsZdGJ/M35JT9oy7vrfEUyFr3R9gD5+Z5OTDOPczh4u5cv5MDYkk21qtRs8DXTsocZ6c2xss+hjERTNzTGUUGNdrs1+NNKafEsGX3gVEvmUhnqjm4wjA==
115.70.43.121 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIvOuk4XNbrCI4BD8fQ8O0/XQafGVgyK/fNtM/9GdtoB
mp1.victorhooi.com ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIvOuk4XNbrCI4BD8fQ8O0/XQafGVgyK/fNtM/9GdtoB
202.161.114.74 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAeWraxbE0WiV9zgR7khkQ9OrCcICo/4csyzNhicZxg7
122.107.84.145 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIG5z5afwaJCeEO2/dMS9DdU8nz4AQcfPVC8L0H7hdAQu
10.7.17.60 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBMT6vmiqjROhVxrFXeCFkRrYSXFZVLEij34E/2kMnBPh7ii8IjnjQthIKKEJ/jauzBrt2Vb9SPAa7RXJpKPIZBA=
27.111.246.206 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIA4XScjpCFvM1KJnwHuoT2QtE7Bi0JO+FOufBsZjLeqo
10.7.78.187 ecdsa-sha2-nistp521 AAAAE2VjZHNhLXNoYTItbmlzdHA1MjEAAAAIbmlzdHA1MjEAAACFBAApWyZC3uqKn62FPPrOiLWAz27ps14yCWkObFunGBV2Qt1m2eoyB1fOuk7ZTt268kCuE/fgoAR5P0waErFHN90hvQEwBChivMeomSNi0PP6lqg1WZTwUS6YRLJngr2QA3u5ZD10vHn0mYljvWPogwY6mRGhHEazKEC+VR7bU0p9m48orQ==
192.168.194.2 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBCXw/k3YtPK5c/SffYzsVylEBZBfwxCTFHTC7FZApyZrZN66Crh4bEBkUnq7uVEgke4I+wvEJ8KRS0Bgw8oueB4=
35.189.25.101 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBN681rkPlmCK30C7fD6G0O2JfB/x+KZoknuDV0uNoiE6rkQrNNzcev/DzdBkcaepifvPcw3HxYYMqdAguSqt2RE=
unifi.victorhooi.com ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBN681rkPlmCK30C7fD6G0O2JfB/x+KZoknuDV0uNoiE6rkQrNNzcev/DzdBkcaepifvPcw3HxYYMqdAguSqt2RE=
4.53.212.170 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINB0iXTSVwqyOz80Vzk6SJrwBlPySYnZYu2hPOdQ/HqX
angusmtv.victorhooi.com ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINB0iXTSVwqyOz80Vzk6SJrwBlPySYnZYu2hPOdQ/HqX
192.168.1.101 ecdsa-sha2-nistp521 AAAAE2VjZHNhLXNoYTItbmlzdHA1MjEAAAAIbmlzdHA1MjEAAACFBAE7jNSVNDBY/KSguGUNdDVvTcl2+t0bDjt+fOW/Cau5ii/fUnXzlpIr0I4sF+HJcJ3TTjy8FUNckhxNpfwTKEae9wD6KNQVyyzIENw422/9SAYFta3H9q/EEl0fwCwheSlWQ4ZLC7Ohgjh1/sXJe7D6IqN3wegSdxWDSVkyMgEFRaoLUA==
10.5.10.54 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBBytuKyk8pw8UHQI69NSSIfUxuGABQ1/3WALhyfCUfY94/yLxHzTdWjfvaZPbMkddApkE2li5H2LBk6M7naZsqg=
2607:7700::1a:0:1:435:d4aa ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINB0iXTSVwqyOz80Vzk6SJrwBlPySYnZYu2hPOdQ/HqX
2607:7700::1a:0:1:1b6f:f6ce ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIA4XScjpCFv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256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBMEgmL1v7woBdFgA/CTZ+cIgzObN45D8EDPU+aXbRY22IoMlB5VyNAcuU/hqcX7FG3bfgvs2T6NCutbI03giS4w=
35.244.122.197 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBDyslTb3qybZF9u4Y/YO83AVCofjONjAuSN7VXGwy1F2cT/yM5rARaU+wHYIu4jyBm1XmkIM8VPGpdPMX1sl3lY=
confluence.victorhooi.com ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBDyslTb3qybZF9u4Y/YO83AVCofjONjAuSN7VXGwy1F2cT/yM5rARaU+wHYIu4jyBm1XmkIM8VPGpdPMX1sl3lY=
:138
10.5.21.31 ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCqUVqGo8jodkkGITehTcCgAor9jkK9cJr43m80ks3srR+SXi7t5EIFUqCkzS8mWdxs9pI1+Uxo+iHRr2DcfA5Oac4nvI/YqM4rC4n9/wOdbSLUlrplkiKfBQ5uGMmu74nPriO/OHyclvOSYyzfS/+/UjFYId1tIw0aihorpJJ2G5dgoei7+XhwDtbIsY9

Built by:         [email protected]
Built on:         Thu 31 Dec 2020 11:44 UTC
Build UUID:       1cd99908-259b-428d-a49f-b70c00496fca
Build Commit ID:  ba6dab895279f6

Architecture:     x86_64
Boot via:         installed image
System type:      bare metal
10.144.125.63 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBA7pr2BQ5X/5AobNdc+vBaEzkYHa2w8EwcLN8LG2psXYEB/y1KHxfAkvJNLWj7DfxSa3GNDP4cmAF/tWJfuYU3M=

Hardware vendor:  Default string
Hardware model:   Default string
Hardware S/N:     EC1916000675
Hardware UUID:    03000200-0400-0500-0006-000700080009

Traceback (most recent call last):
  File "/usr/libexec/vyos/conf_mode/dns_forwarding.py", line 179, in <module>
    c = get_config()
  File "/usr/libexec/vyos/conf_mode/dns_forwarding.py", line 48, in get_config
    conf = Config()
  File "/usr/lib/python3/dist-packages/vyos/config.py", line 85, in __init__
    self._config_source = ConfigSourceSession(session_env)
  File "/usr/lib/python3/dist-packages/vyos/configsource.py", line 132, in __init__
    session_config_text = self._run([self._cli_shell_api, '--show-working-only', '--show-show-defaults', '--show-ignore-edit', 'showConfig'])
  File "/usr/lib/python3/dist-packages/vyos/configsource.py", line 164, in _run
    return out.decode('ascii')
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 2163: ordinal not in range(128)



[[service dns forwarding]] failed
Commit failed
[edit]

Details

Difficulty level
Unknown (require assessment)
Version
1.3-rolling-202012311144
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)

Event Timeline

If you look at vif 17, the description contains matched single quotes: notably, unicode character U+2018 'Left Single Quotation Mark'. Converting to utf-8 following the prescription in 'man utf-8' gives:
0xE2 0x80 0x98
hence the 0xE2 error message. One can reference this at
https://www.compart.com/en/unicode/U+2018, but this value was checked for completeness.

There is an interesting discussion of background regarding keyboards and drivers here:
https://www.cl.cam.ac.uk/~mgk25/ucs/apostrophe.html
https://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
but this does not seem to clearly account for the issue. I am very curious as to the source of these characters in the cited config file.

Regarding a proper fix to this and the related T2941, in both cases these are utf-8, but not ascii, characters. As in vyos-configd, util.py, and elsewhere, configsource.py should use a decode('utf-8'); the residual decode('ascii') was an early implementation detail, and should be fixed. Note however this brings up a second error for these characters, regarding the json default_decoder. Both issues will be opened in child tasks, the former for resolution; the latter for assessment.

Allowing utf-8 in general may be problematical:
(1) utf-8 within, say, a description name (see parent T2941) should be manageable; any restrictions in the legacy backend (I have not confirmed) could be addressed relatively easily
(2) allowing alternative quote characters (this task) is a can of worms for the lexer, and likely a very bad idea

The root cause is diagnosed above; a development decision will require evaluation.

A careful analysis of the error here is provided in the last two comments; the general question of unicode support will be investigated in T3785.