Details
-
Bug
-
Status: Done (View Workflow)
-
Low
-
Resolution: Complete
-
11.3-RC1
-
None
Description
Problem:
- In Network -> Interfaces -> Edit, blanking out the MTU setting results in a "not an interger" error.
Steps to replicate:
- Go to Network -> Interfaces and edit any interface.
- Enter a number in the MTU section (such as 9000).
- Click Apply.
- Go back to the Edit screen for that same interface.
- Delete the number that you had previously inputted. Leave it blank.
- Click Apply. Error will be observed.
Expected behavior:
- When clearing out the MTU setting in an interface and leaving it blank, it should return the MTU setting to default (1500) without giving an error.
Error: Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/middlewared/main.py", line 128, in call_method
result = await self.middleware.call_method(self, message)
File "/usr/local/lib/python3.7/site-packages/middlewared/main.py", line 1113, in call_method
return await self._call(message['method'], serviceobj, methodobj, params, app=app, io_thread=False)
File "/usr/local/lib/python3.7/site-packages/middlewared/main.py", line 1061, in _call
return await methodobj(*args)
File "/usr/local/lib/python3.7/site-packages/middlewared/service.py", line 403, in update
f'{self._config.namespace}.update', self, self.do_update, [id, data]
File "/usr/local/lib/python3.7/site-packages/middlewared/main.py", line 1061, in _call
return await methodobj(*args)
File "/usr/local/lib/python3.7/site-packages/middlewared/schema.py", line 948, in nf
args, kwargs = clean_and_validate_args(args, kwargs)
File "/usr/local/lib/python3.7/site-packages/middlewared/schema.py", line 906, in clean_and_validate_args
value = attr.clean(args[args_index + i])
File "/usr/local/lib/python3.7/site-packages/middlewared/schema.py", line 594, in clean
data[key] = attr.clean(value)
File "/usr/local/lib/python3.7/site-packages/middlewared/schema.py", line 400, in clean
raise Error(self.name, 'Not an integer')
middlewared.schema.Error: [mtu] Not an integer