Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- UNHANDLED EXCEPTION (2013-04-11 10:10:44.825943)
- Working directory: /usr/local/noc
- <class 'mongoengine.queryset.InvalidQueryError'>
- Cannot resolve field "is_bridge"
- START OF TRACEBACK
- ------------------------------------------------------------------------
- File: build/bdist.freebsd-8.2-STABLE-amd64/egg/mongoengine/queryset.py (Line: 639)
- Function: _lookup_field
- 632 if field_name in document._fields:
- 633 field = document._fields[field_name]
- 634 elif document._dynamic:
- 635 from fields import DynamicField
- 636 field = DynamicField(db_field=field_name)
- 637 else:
- 638 raise InvalidQueryError('Cannot resolve field "%s"'
- 639 ==> % field_name)
- 640 else:
- 641 from mongoengine.fields import ReferenceField, GenericReferenceField
- 642 if isinstance(field, (ReferenceField, GenericReferenceField)):
- 643 raise InvalidQueryError('Cannot perform join in mongoDB: %s' % '__'.join(parts))
- 644 if hasattr(getattr(field, 'field', None), 'lookup_member'):
- 645 new_field = field.field.lookup_member(field_name)
- Variables:
- fields = []
- field = None
- parts = ['is_bridge']
- document = <class 'noc.inv.models.subinterface.SubInterface'>
- field_name = 'is_bridge'
- cls = <class 'mongoengine.queryset.QuerySet'>
- ------------------------------------------------------------------------
- File: build/bdist.freebsd-8.2-STABLE-amd64/egg/mongoengine/queryset.py (Line: 701)
- Function: _transform_query
- 694 negate = False
- 695 if parts[-1] == 'not':
- 696 parts.pop()
- 697 negate = True
- 698
- 699 if _doc_cls:
- 700 # Switch field names to proper names [set in Field(name='foo')]
- 701 ==> fields = QuerySet._lookup_field(_doc_cls, parts)
- 702 parts = []
- 703
- 704 cleaned_fields = []
- 705 for field in fields:
- 706 append_field = True
- 707 if isinstance(field, basestring):
- Variables:
- mongo_query = {}
- _field_operation = False
- geo_operators =
- ['within_distance',
- 'within_spherical_distance',
- 'within_box',
- 'within_polygon',
- 'near',
- 'near_sphere']
- match_operators =
- ['contains',
- 'icontains',
- 'startswith',
- 'istartswith',
- 'endswith',
- 'iendswith',
- 'exact',
- 'iexact']
- p = 'is_bridge'
- i = 0
- operators =
- ['ne',
- 'gt',
- 'gte',
- 'lt',
- 'lte',
- 'in',
- 'nin',
- 'mod',
- 'all',
- 'size',
- 'exists',
- 'not']
- parts = ['is_bridge']
- value = True
- indices = []
- _doc_cls = <class 'noc.inv.models.subinterface.SubInterface'>
- part = 'is_bridge'
- cls = <class 'mongoengine.queryset.QuerySet'>
- key = 'is_bridge'
- negate = False
- query = {'is_bridge': True, 'managed_object': 34}
- custom_operators = ['match']
- op = None
- ------------------------------------------------------------------------
- File: build/bdist.freebsd-8.2-STABLE-amd64/egg/mongoengine/queryset.py (Line: 162)
- Function: visit_query
- 155 if combination.operation == combination.OR:
- 156 return {'$or': combination.children}
- 157 elif combination.operation == combination.AND:
- 158 return self._mongo_query_conjunction(combination.children)
- 159 return combination
- 160
- 161 def visit_query(self, query):
- 162 ==> return QuerySet._transform_query(self.document, **query.query)
- 163
- 164 def _mongo_query_conjunction(self, queries):
- 165 """Merges Mongo query dicts - effectively &ing them together.
- 166 """
- 167 combined_query = {}
- 168 for query in queries:
- Variables:
- query = <mongoengine.queryset.Q object at 0x80953e850>
- self = <mongoengine.queryset.QueryCompilerVisitor object at 0x80953e4d0>
- ------------------------------------------------------------------------
- File: build/bdist.freebsd-8.2-STABLE-amd64/egg/mongoengine/queryset.py (Line: 270)
- Function: accept
- 263 query structures.
- 264 """
- 265
- 266 def __init__(self, **query):
- 267 self.query = query
- 268
- 269 def accept(self, visitor):
- 270 ==> return visitor.visit_query(self)
- 271
- 272 @property
- 273 def empty(self):
- 274 return not bool(self.query)
- 275
- 276
- Variables:
- visitor = <mongoengine.queryset.QueryCompilerVisitor object at 0x80953e4d0>
- self = <mongoengine.queryset.Q object at 0x80953e850>
- ------------------------------------------------------------------------
- File: build/bdist.freebsd-8.2-STABLE-amd64/egg/mongoengine/queryset.py (Line: 205)
- Function: to_query
- 198
- 199 AND = 0
- 200 OR = 1
- 201
- 202 def to_query(self, document):
- 203 query = self.accept(SimplificationVisitor())
- 204 query = query.accept(QueryTreeTransformerVisitor())
- 205 ==> query = query.accept(QueryCompilerVisitor(document))
- 206 return query
- 207
- 208 def accept(self, visitor):
- 209 raise NotImplementedError
- 210
- 211 def _combine(self, other, operation):
- Variables:
- query = <mongoengine.queryset.Q object at 0x80953e850>
- self = <mongoengine.queryset.Q object at 0x80953e850>
- document = <class 'noc.inv.models.subinterface.SubInterface'>
- ------------------------------------------------------------------------
- File: build/bdist.freebsd-8.2-STABLE-amd64/egg/mongoengine/queryset.py (Line: 379)
- Function: _query
- 372 setattr(c, prop, copy.deepcopy(val))
- 373
- 374 return c
- 375
- 376 @property
- 377 def _query(self):
- 378 if self._mongo_query is None:
- 379 ==> self._mongo_query = self._query_obj.to_query(self._document)
- 380 if self._class_check:
- 381 self._mongo_query.update(self._initial_query)
- 382 return self._mongo_query
- 383
- 384 def ensure_index(self, key_or_list, drop_dups=False, background=False,
- 385 **kwargs):
- Variables:
- self = repr() failed
- ------------------------------------------------------------------------
- File: build/bdist.freebsd-8.2-STABLE-amd64/egg/mongoengine/queryset.py (Line: 583)
- Function: _cursor
- 576 cursor_args['fields'] = self._loaded_fields.as_dict()
- 577 return cursor_args
- 578
- 579 @property
- 580 def _cursor(self):
- 581 if self._cursor_obj is None:
- 582
- 583 ==> self._cursor_obj = self._collection.find(self._query,
- 584 **self._cursor_args)
- 585 # Apply where clauses to cursor
- 586 if self._where_clause:
- 587 self._cursor_obj.where(self._where_clause)
- 588
- 589 # apply default ordering
- Variables:
- self = .. queryset mid-iteration ..
- ------------------------------------------------------------------------
- File: build/bdist.freebsd-8.2-STABLE-amd64/egg/mongoengine/queryset.py (Line: 990)
- Function: rewind
- 983
- 984 def rewind(self):
- 985 """Rewind the cursor to its unevaluated state.
- 986
- 987 .. versionadded:: 0.3
- 988 """
- 989 self._iter = False
- 990 ==> self._cursor.rewind()
- 991
- 992 def count(self):
- 993 """Count the selected elements in the query.
- 994 """
- 995 if self._limit == 0:
- 996 return 0
- Variables:
- self = .. queryset mid-iteration ..
- ------------------------------------------------------------------------
- File: build/bdist.freebsd-8.2-STABLE-amd64/egg/mongoengine/queryset.py (Line: 1517)
- Function: __iter__
- 1510
- 1511 if ret is not None and 'n' in ret:
- 1512 return ret['n']
- 1513 except pymongo.errors.OperationFailure, e:
- 1514 raise OperationError(u'Update failed [%s]' % unicode(e))
- 1515
- 1516 def __iter__(self):
- 1517 ==> self.rewind()
- 1518 return self
- 1519
- 1520 def _get_scalar(self, doc):
- 1521
- 1522 def lookup(obj, name):
- 1523 chunks = name.split('__')
- Variables:
- self = .. queryset mid-iteration ..
- ------------------------------------------------------------------------
- File: /usr/local/noc/inv/apps/interface/views.py (Line: 129)
- Function: api_get_interfaces
- 122 {
- 123 "name": i.name,
- 124 "description": i.description,
- 125 "untagged_vlan": i.untagged_vlan,
- 126 "tagged_vlans": i.tagged_vlans
- 127 } for i in
- 128 SubInterface.objects.filter(managed_object=o.id,
- 129 ==> is_bridge=True)
- 130 ]
- 131 # L3 interfaces
- 132 q = Q(is_ipv4=True) | Q(is_ipv6=True)
- 133 l3 = [
- 134 {
- 135 "name": i.name,
- Variables:
- get_style = <function get_style at 0x809840938>
- j = <Interface: CAT3560: Gi 0/38>
- get_link = <function get_link at 0x80983dd70>
- i = <Interface: CAT3560: Po 1>
- self =
- <noc.inv.apps.interface.views.InterfaceAppplication object at 0x80896a390>
- lag =
- [{'description': u'etherchanel_888_vnesnik_112_ett',
- 'members': [u'Gi 0/35', u'Gi 0/36', u'Gi 0/37', u'Gi 0/38'],
- 'name': u'Po 1'}]
- request =
- <WSGIRequest
- path:/inv/interface/34/,
- GET:<QueryDict: {u'_dc': [u'1365664265252']}>,
- POST:<QueryDict: {}>,
- COOKIES:{'csrftoken': 'lE7aU1X8dYl5XeCHA4ZNiPYnrhaUb3fY',
- 'sessionid': 'f1cc12b53458ad565b20b8613c761534'},
- META:{'HTTP_ACCEPT': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
- 'HTTP_ACCEPT_ENCODING': 'gzip, deflate',
- 'HTTP_ACCEPT_LANGUAGE': 'uk-UA,uk,ru-RU,ru;q=0.9,en-US;q=0.9,en;q=0.9,en-gb;q=0.9,de-DE;q=0.8,de;q=0.8,es-EC;q=0.8,es;q=0.7,en-US-x-Hixie;q=0.7,ru-ru;q=0.7,en-gb;q=0.7,en-us;q=0.6,uk-ua;q=0.6,fr-FR;q=0.6,fr;q=0.6,pl-PL;q=0.5,pl;q=0.5,lv-LV;q=0.5,lv;q=0.5,se-SE;q=0.4,se;q=0.4,ja-JP;q=0.4,ja;q=0.4,de-LI;q=0.3,de-CH;q=0.3,hu-HU;q=0.3,hu;q=0.3,nl-NL;q=0.2,nl;q=0.2,ru-RU.UTF-8;q=0.2,en-AU;q=0.2,it-IT;q=0.1,it;q=0.1,br-FR;q=0.1,br;q=0.1,ro-RO;q=0.0,ro;q=0.0',
- 'HTTP_CONNECTION': 'close',
- 'HTTP_COOKIE': 'csrftoken=lE7aU1X8dYl5XeCHA4ZNiPYnrhaUb3fY; sessionid=f1cc12b53458ad565b20b8613c761534',
- 'HTTP_HOST': '127.0.0.1:8000',
- 'HTTP_USER_AGENT': 'Mozilla/5.0 (X11; FreeBSD i386; rv:17.0) Gecko/17.0 Firefox/17.0',
- 'PATH_INFO': u'/inv/interface/34/',
- 'QUERY_STRING': '_dc=1365664265252',
- '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 0x8042349c0>,
- 'wsgi.input': <_io.BytesIO object at 0x8097a2050>,
- 'wsgi.multiprocess': True,
- 'wsgi.multithread': False,
- 'wsgi.run_once': False,
- 'wsgi.url_scheme': 'http',
- 'wsgi.version': (1, 0)}>
- managed_object = u'34'
- o = <ManagedObject: CAT3560>
- style_cache = {ObjectId('500a5ee4bcf4b15bb7000000'): ''}
- sorted_iname = <function sorted_iname at 0x8096d0578>
- l1 =
- [{'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000026',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:01',
- 'name': u'Gi 0/1',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000038',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:0A',
- 'name': u'Gi 0/10',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200003a',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:0B',
- 'name': u'Gi 0/11',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'VPNS_INET',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200003c',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:0C',
- 'name': u'Gi 0/12',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200003e',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:0D',
- 'name': u'Gi 0/13',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000040',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:0E',
- 'name': u'Gi 0/14',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000042',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:0F',
- 'name': u'Gi 0/15',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000044',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:10',
- 'name': u'Gi 0/16',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'ubr7114-1',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000046',
- 'ifindex': None,
- 'lag': '',
- 'link': {'id': '5072b8f2bcf4b14513000002', 'label': u'ubr7114-1:Fa 0/0'},
- 'mac': u'00:19:55:E0:C9:11',
- 'name': u'Gi 0/17',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000048',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:12',
- 'name': u'Gi 0/18',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'ubr7114-3',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200004a',
- 'ifindex': None,
- 'lag': '',
- 'link': {'id': '5072b8febcf4b14513000003', 'label': u'ubr7114-3:Fa 0/0'},
- 'mac': u'00:19:55:E0:C9:13',
- 'name': u'Gi 0/19',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000028',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:02',
- 'name': u'Gi 0/2',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'K.Marksa_11b (GT)',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200004c',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:14',
- 'name': u'Gi 0/20',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200004e',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:15',
- 'name': u'Gi 0/21',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000050',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:16',
- 'name': u'Gi 0/22',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000052',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:17',
- 'name': u'Gi 0/23',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000054',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:18',
- 'name': u'Gi 0/24',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'Souzinform',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000056',
- 'ifindex': None,
- 'lag': '',
- 'link': {'id': '5072bc53bcf4b1484a000000',
- 'label': u'\u041d\u044c\u044e\u0442\u043e\u043d\u0430 42:1'},
- 'mac': u'00:19:55:E0:C9:19',
- 'name': u'Gi 0/25',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'Privet Bank',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000058',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:1A',
- 'name': u'Gi 0/26',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200005a',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:1B',
- 'name': u'Gi 0/27',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200005c',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:1C',
- 'name': u'Gi 0/28',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200005e',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:1D',
- 'name': u'Gi 0/29',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200002a',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:03',
- 'name': u'Gi 0/3',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000060',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:1E',
- 'name': u'Gi 0/30',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000062',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:1F',
- 'name': u'Gi 0/31',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000064',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:20',
- 'name': u'Gi 0/32',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000066',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:21',
- 'name': u'Gi 0/33',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000068',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:22',
- 'name': u'Gi 0/34',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP', u'LACP'],
- 'id': '4eeb514cbcf4b106d200006a',
- 'ifindex': None,
- 'lag': u'Po 1',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:23',
- 'name': u'Gi 0/35',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP', u'LACP'],
- 'id': '4eeb514cbcf4b106d200006c',
- 'ifindex': None,
- 'lag': u'Po 1',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:24',
- 'name': u'Gi 0/36',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP', u'LACP'],
- 'id': '4eeb514cbcf4b106d200006e',
- 'ifindex': None,
- 'lag': u'Po 1',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:25',
- 'name': u'Gi 0/37',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP', u'LACP'],
- 'id': '4eeb514cbcf4b106d2000070',
- 'ifindex': None,
- 'lag': u'Po 1',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:26',
- 'name': u'Gi 0/38',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'Gagarina',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000072',
- 'ifindex': None,
- 'lag': '',
- 'link': {'id': '5072b8b8bcf4b14513000001',
- 'label': u'\u0413\u0430\u0433\u0430\u0440\u0438\u043d\u0430:24'},
- 'mac': u'00:19:55:E0:C9:27',
- 'name': u'Gi 0/39',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'Loopback for TRK switches',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200002c',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:04',
- 'name': u'Gi 0/4',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000074',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:28',
- 'name': u'Gi 0/40',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'niko->kirova12',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000076',
- 'ifindex': None,
- 'lag': '',
- 'link': {'id': '5076b2c6bcf4b127a400000b',
- 'label': u'\u041a\u0438\u0440\u043e\u0432\u0430 12-1:1'},
- 'mac': u'00:19:55:E0:C9:29',
- 'name': u'Gi 0/41',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000078',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:2A',
- 'name': u'Gi 0/42',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200007a',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:2B',
- 'name': u'Gi 0/43',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200007c',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:2C',
- 'name': u'Gi 0/44',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'fenomen->lisovogo',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200007e',
- 'ifindex': None,
- 'lag': '',
- 'link': {'id': '5076b28bbcf4b127a4000008',
- 'label': u'\u041b\u0438\u0441\u043e\u0432\u043e\u0433\u043e 41:1'},
- 'mac': u'00:19:55:E0:C9:2D',
- 'name': u'Gi 0/45',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000080',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:2E',
- 'name': u'Gi 0/46',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000082',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:2F',
- 'name': u'Gi 0/47',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000084',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:30',
- 'name': u'Gi 0/48',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'Bluhera_3',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000086',
- 'ifindex': None,
- 'lag': '',
- 'link': {'id': '5076b2a1bcf4b127a4000009',
- 'label': u'\u0411\u043b\u044e\u0445\u0435\u0440\u0430:1'},
- 'mac': u'00:19:55:E0:C9:31',
- 'name': u'Gi 0/49',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200002e',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:05',
- 'name': u'Gi 0/5',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'vishka_wnet_gt_reklama',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000088',
- 'ifindex': None,
- 'lag': '',
- 'link': {'id': '5076b4b0bcf4b127a4000010',
- 'label': u'\u0422\u0435\u043b\u0435\u0432\u044b\u0448\u043a\u0430:Gi 0/8'},
- 'mac': u'00:19:55:E0:C9:32',
- 'name': u'Gi 0/50',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'Makulan',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200008a',
- 'ifindex': None,
- 'lag': '',
- 'link': {'id': '5076b2b5bcf4b127a400000a',
- 'label': u'\u041c\u0430\u043a\u0443\u043b\u0430\u043d:1'},
- 'mac': u'00:19:55:E0:C9:33',
- 'name': u'Gi 0/51',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'Muhinoy_3',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d200008c',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:34',
- 'name': u'Gi 0/52',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': u'Office DES-3010G',
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000030',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:06',
- 'name': u'Gi 0/6',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000032',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:07',
- 'name': u'Gi 0/7',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000034',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:08',
- 'name': u'Gi 0/8',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''},
- {'description': None,
- 'enabled_protocols': [u'LLDP'],
- 'id': '4eeb514cbcf4b106d2000036',
- 'ifindex': None,
- 'lag': '',
- 'link': None,
- 'mac': u'00:19:55:E0:C9:09',
- 'name': u'Gi 0/9',
- 'profile': '500a5ee4bcf4b15bb7000000',
- 'profile__label': u'default',
- 'row_class': ''}]
- ------------------------------------------------------------------------
- File: /usr/local/noc/lib/app/site.py (Line: 232)
- Function: inner
- 225 for k, v in request.POST.lists())
- 226 elif request.method == "GET":
- 227 a = dict((k, v[0] if len(v) == 1 else v)
- 228 for k, v in request.GET.lists())
- 229 logging.debug("API %s %s %s" % (request.method,
- 230 request.path, a))
- 231 # Call handler
- 232 ==> r = v(request, *args, **kwargs)
- 233 # Dump SQL statements
- 234 if self.log_sql_statements:
- 235 from django.db import connections
- 236 tsc = 0
- 237 sc = defaultdict(int)
- 238 for conn in connections.all():
- Variables:
- args = ()
- view_map =
- {'GET': <bound method InterfaceAppplication.api_get_interfaces of <noc.inv.apps.interface.views.InterfaceAppplication object at 0x80896a390>>}
- Form = <class 'django.forms.forms.Form'>
- DictParameter = <class 'noc.sa.interfaces.base.DictParameter'>
- self = <noc.lib.app.site.Site object at 0x806624590>
- v =
- <bound method InterfaceAppplication.api_get_interfaces of <noc.inv.apps.interface.views.InterfaceAppplication object at 0x80896a390>>
- request =
- <WSGIRequest
- path:/inv/interface/34/,
- GET:<QueryDict: {u'_dc': [u'1365664265252']}>,
- POST:<QueryDict: {}>,
- COOKIES:{'csrftoken': 'lE7aU1X8dYl5XeCHA4ZNiPYnrhaUb3fY',
- 'sessionid': 'f1cc12b53458ad565b20b8613c761534'},
- META:{'HTTP_ACCEPT': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
- 'HTTP_ACCEPT_ENCODING': 'gzip, deflate',
- 'HTTP_ACCEPT_LANGUAGE': 'uk-UA,uk,ru-RU,ru;q=0.9,en-US;q=0.9,en;q=0.9,en-gb;q=0.9,de-DE;q=0.8,de;q=0.8,es-EC;q=0.8,es;q=0.7,en-US-x-Hixie;q=0.7,ru-ru;q=0.7,en-gb;q=0.7,en-us;q=0.6,uk-ua;q=0.6,fr-FR;q=0.6,fr;q=0.6,pl-PL;q=0.5,pl;q=0.5,lv-LV;q=0.5,lv;q=0.5,se-SE;q=0.4,se;q=0.4,ja-JP;q=0.4,ja;q=0.4,de-LI;q=0.3,de-CH;q=0.3,hu-HU;q=0.3,hu;q=0.3,nl-NL;q=0.2,nl;q=0.2,ru-RU.UTF-8;q=0.2,en-AU;q=0.2,it-IT;q=0.1,it;q=0.1,br-FR;q=0.1,br;q=0.1,ro-RO;q=0.0,ro;q=0.0',
- 'HTTP_CONNECTION': 'close',
- 'HTTP_COOKIE': 'csrftoken=lE7aU1X8dYl5XeCHA4ZNiPYnrhaUb3fY; sessionid=f1cc12b53458ad565b20b8613c761534',
- 'HTTP_HOST': '127.0.0.1:8000',
- 'HTTP_USER_AGENT': 'Mozilla/5.0 (X11; FreeBSD i386; rv:17.0) Gecko/17.0 Firefox/17.0',
- 'PATH_INFO': u'/inv/interface/34/',
- 'QUERY_STRING': '_dc=1365664265252',
- '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 0x8042349c0>,
- 'wsgi.input': <_io.BytesIO object at 0x8097a2050>,
- 'wsgi.multiprocess': True,
- 'wsgi.multithread': False,
- 'wsgi.run_once': False,
- 'wsgi.url_scheme': 'http',
- 'wsgi.version': (1, 0)}>
- to_log_api_call = False
- InterfaceTypeError = <class 'noc.sa.interfaces.base.InterfaceTypeError'>
- PermissionDenied = <class 'noc.lib.app.access.PermissionDenied'>
- kwargs = {'managed_object': u'34'}
- app =
- <noc.inv.apps.interface.views.InterfaceAppplication object at 0x80896a390>
- ------------------------------------------------------------------------
- END OF TRACEBACK
Advertisement
Add Comment
Please, Sign In to add comment