Project

General

Profile

Bug #27097

Avoid exception when number of maximum swap mirrors is reached

Added by William Grzybowski 10 months ago. Updated 10 months ago.

Status:
Resolved
Priority:
Nice to have
Assignee:
William Grzybowski
Category:
Middleware
Target version:
Seen in:
Sprint:
Severity:
New
Backlog Priority:
Reason for Closing:
Reason for Blocked:
Needs QA:
No
Needs Doc:
Yes
Needs Merging:
Yes
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:
ChangeLog Required:
No

Description

UnboundLocalError: local variable 'name' referenced before assignment
  File "middlewared/main.py", line 150, in call_method
    result = await self.middleware.call_method(self, message)
  File "asyncio/coroutines.py", line 109, in __next__
    return self.gen.send(None)
  File "middlewared/main.py", line 895, in call_method
    return await self._call(message['method'], serviceobj, methodobj, params, app=app)
  File "asyncio/coroutines.py", line 109, in __next__
    return self.gen.send(None)
  File "middlewared/main.py", line 863, in _call
    return await methodobj(*args)
  File "asyncio/coroutines.py", line 109, in __next__
    return self.gen.send(None)
  File "plugins/disk.py", line 616, in swaps_configure
    self.logger.warn(f'Failed to create gmirror {name}', exc_info=True)
RuntimeError: All mirror names are taken
  File "plugins/disk.py", line 613, in swaps_configure
    name = new_swap_name()
  File "plugins/disk.py", line 774, in new_swap_name
    raise RuntimeError('All mirror names are taken')

Associated revisions

Revision d12e6f94 (diff)
Added by William Grzybowski 10 months ago

fix(middlewared/disk): avoid traceback if limit of mirror is reached

Ticket: #27097

Revision 54c47f62 (diff)
Added by William Grzybowski 10 months ago

fix(middlewared/disk): avoid traceback if limit of mirror is reached

Ticket: #27097
(cherry picked from commit d12e6f9434c9b65b91d5f50817a1c49481cacbd9)

Revision 5b9ecf1d (diff)
Added by William Grzybowski 10 months ago

fix(middlewared/disk): avoid traceback if limit of mirror is reached

Ticket: #27097

Revision b17d89f0 (diff)
Added by William Grzybowski 10 months ago

fix(middlewared/disk): avoid traceback if limit of mirror is reached

Ticket: #27097
(cherry picked from commit d12e6f9434c9b65b91d5f50817a1c49481cacbd9)

History

#1 Updated by William Grzybowski 10 months ago

  • Status changed from Screened to Needs Developer Review
  • Assignee changed from William Grzybowski to Vladimir Vinogradenko

#2 Updated by Vladimir Vinogradenko 10 months ago

  • Status changed from Needs Developer Review to Reviewed by Developer
  • Assignee changed from Vladimir Vinogradenko to William Grzybowski

#3 Updated by William Grzybowski 10 months ago

  • Status changed from Reviewed by Developer to Ready For Release
  • Needs QA changed from Yes to No

#4 Updated by Dru Lavigne 10 months ago

  • Status changed from Ready For Release to Resolved

Also available in: Atom PDF