How to Solve NameError: name 'aggregates' is not defined -- nova

Solution: Import the 'aggregates' module

# Add the following line to the top of your code
from nova.policies import aggregates

 

For more information:
nova aggregates