Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- UNHANDLED EXCEPTION (2013-02-05 15:32:48.756510)
- Working directory: /opt/noc
- <class 'noc.ip.models.vrf.DoesNotExist'>
- VRF matching query does not exist.
- START OF TRACEBACK
- ------------------------------------------------------------------------
- File: /opt/noc/contrib/lib/django/db/models/query.py (Line: 366)
- Function: get
- 359 if self.query.can_filter():
- 360 clone = clone.order_by()
- 361 num = len(clone)
- 362 if num == 1:
- 363 return clone._result_cache[0]
- 364 if not num:
- 365 raise self.model.DoesNotExist("%s matching query does not exist."
- 366 ==> % self.model._meta.object_name)
- 367 raise self.model.MultipleObjectsReturned("get() returned more than one %s -- it returned %s! Lookup parameters were %s"
- 368 % (self.model._meta.object_name, num, kwargs))
- 369
- 370 def create(self, **kwargs):
- 371 """
- 372 Creates a new object with the given kwargs, saving it to the database
- Variables:
- clone = []
- num = 0
- self = [<VRF: AkadPravovKoll>, <VRF: burokrat>, <VRF: Comcor>, <VRF: holding>, <VRF: Home2com>, <VRF: INcoma>, <VRF: INTERNET>, <VRF: InternetV6>, <VRF: iptv>, <VRF: kipbank>, <VRF: merlion>, <VRF: MetalBez>, <VRF: MGMT>, <VRF: Office2com>, <VRF: OMS>, <VRF: rostbank>, <VRF: sits>, <VRF: sm-clinic>, <VRF: TEL>, <VRF: test-ip-allocation>, '...(remaining elements truncated)...']
- args = ()
- kwargs = {'rd': '0:0'}
- ------------------------------------------------------------------------
- File: /opt/noc/contrib/lib/django/db/models/manager.py (Line: 131)
- Function: get
- 124 def distinct(self, *args, **kwargs):
- 125 return self.get_query_set().distinct(*args, **kwargs)
- 126
- 127 def extra(self, *args, **kwargs):
- 128 return self.get_query_set().extra(*args, **kwargs)
- 129
- 130 def get(self, *args, **kwargs):
- 131 ==> return self.get_query_set().get(*args, **kwargs)
- 132
- 133 def get_or_create(self, **kwargs):
- 134 return self.get_query_set().get_or_create(**kwargs)
- 135
- 136 def create(self, **kwargs):
- 137 return self.get_query_set().create(**kwargs)
- Variables:
- self = <django.db.models.manager.Manager object at 0x303c550>
- args = ()
- kwargs = {'rd': '0:0'}
- ------------------------------------------------------------------------
- File: /opt/noc/ip/models/vrf.py (Line: 95)
- Function: get_global
- 88 return site.reverse("ip:vrf:change", self.id)
- 89
- 90 @classmethod
- 91 def get_global(cls):
- 92 """
- 93 Returns VRF 0:0
- 94 """
- 95 ==> return VRF.objects.get(rd="0:0")
- 96
- 97 @classmethod
- 98 def generate_rd(cls, name):
- 99 """
- 100 Generate unique rd for given name
- 101 """
- Variables:
- cls = <class 'noc.ip.models.vrf.VRF'>
- ------------------------------------------------------------------------
- File: /opt/noc/ip/apps/routeimport/views.py (Line: 31)
- Function: reduce_route
- 24 Reduce task for route import
- 25 :param task:
- 26 :return:
- 27 """
- 28 from noc.ip.models import VRF, Prefix
- 29 from noc.lib.ip import IP
- 30
- 31 ==> vrf = VRF.get_global()
- 32 r = {} # prefix -> (description, objects)
- 33
- 34 for mt in task.maptask_set.filter(status="C"):
- 35 for instance in mt.script_result:
- 36 if instance["type"] == "ip" and instance[
- 37 "forwarding_instance"] == "default":
- Variables:
- IP = <class 'noc.lib.ip.IP'>
- Prefix = <class 'noc.ip.models.prefix.Prefix'>
- task = <ReduceTask: 21885>
- VRF = <class 'noc.ip.models.vrf.VRF'>
- ------------------------------------------------------------------------
- File: /opt/noc/sa/models/reducetask.py (Line: 259)
- Function: reduce
- 252 m.save()
- 253 return r_task
- 254
- 255 ##
- 256 ## Perform reduce script and execute result
- 257 ##
- 258 def reduce(self):
- 259 ==> return PyRule.compile_text(self.script)(self, **self.script_params)
- 260
- 261 ##
- 262 ## Get task result
- 263 ##
- 264 def get_result(self, block=True):
- 265 while True:
- Variables:
- self = <ReduceTask: 21885>
- ------------------------------------------------------------------------
- File: /opt/noc/sa/models/reducetask.py (Line: 267)
- Function: get_result
- 260
- 261 ##
- 262 ## Get task result
- 263 ##
- 264 def get_result(self, block=True):
- 265 while True:
- 266 if self.complete:
- 267 ==> result = self.reduce()
- 268 self.delete()
- 269 return result
- 270 else:
- 271 if block:
- 272 time.sleep(3)
- 273 else:
- Variables:
- self = <ReduceTask: 21885>
- block = False
- ------------------------------------------------------------------------
- File: /opt/noc/lib/app/saapplication.py (Line: 144)
- Function: view_task
- 137 def width(w):
- 138 if not w or not total_tasks:
- 139 return 0
- 140 return MAX_WIDTH * w / total_tasks
- 141
- 142 task = get_object_or_404(ReduceTask, id=int(task_id))
- 143 try:
- 144 ==> result = task.get_result(block=False)
- 145 except ReduceTask.NotReady:
- 146 # Task not ready, refresh
- 147 # Get counts into status -> count dict
- 148 s = task.maptask_set.values("status").annotate(Count("status"))
- 149 counts = dict([(r["status"], r["status__count"]) for r in s])
- 150 total_tasks = sum(counts.values())
- Variables:
- task = <ReduceTask: 21885>
- task_id = u'21885'
- self = <noc.ip.apps.routeimport.views.RouteImportAppplication object at 0x3ccd950>
- request = <WSGIRequest
- path:/ip/routeimport/task/21885/,
- GET:<QueryDict: {}>,
- POST:<QueryDict: {}>,
- COOKIES:{'csrftoken': 'aUGLOhc6xDfUl7geX7gRePD2Nmwm80D0',
- 'sessionid': 'ada51347a126da6a622111e505321d1f',
- 'was_on_site': 'was'},
- META:{'HTTP_ACCEPT': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
- 'HTTP_ACCEPT_CHARSET': 'UTF-8,*;q=0.5',
- 'HTTP_ACCEPT_ENCODING': 'gzip,deflate,sdch',
- 'HTTP_ACCEPT_LANGUAGE': 'ru-RU,ru;q=0.8,en-US;q=0.6,en;q=0.4',
- 'HTTP_CACHE_CONTROL': 'max-age=0',
- 'HTTP_CONNECTION': 'close',
- 'HTTP_COOKIE': 'was_on_site=was; csrftoken=aUGLOhc6xDfUl7geX7gRePD2Nmwm80D0; sessionid=ada51347a126da6a622111e505321d1f',
- 'HTTP_HOST': '127.0.0.1:8000',
- 'HTTP_REFERER': 'http://nocproject.2com.net/ip/routeimport/task/21885/',
- 'HTTP_USER_AGENT': 'Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.57 Safari/537.17',
- 'PATH_INFO': u'/ip/routeimport/task/21885/',
- 'QUERY_STRING': '',
- 'REMOTE_ADDR': '127.0.0.1',
- 'REQUEST_METHOD': 'GET',
- 'SCRIPT_NAME': u'',
- 'SERVER_NAME': '127.0.0.1',
- 'SERVER_PORT': '8000',
- 'SERVER_PROTOCOL': 'HTTP/1.0',
- 'wsgi.errors': <open file '/dev/null', mode 'a+' at 0x16bc8a0>,
- 'wsgi.input': <io.BytesIO object at 0x455c6b0>,
- 'wsgi.multiprocess': True,
- 'wsgi.multithread': False,
- 'wsgi.run_once': False,
- 'wsgi.url_scheme': 'http',
- 'wsgi.version': (1, 0)}>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement