Skip to content

Commit e5a930c

Browse files
authored
Merge pull request #106 from k01ek/develop
Develop
2 parents 3132f73 + 34e6420 commit e5a930c

File tree

5 files changed

+13
-6
lines changed

5 files changed

+13
-6
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
PYTHON_VER?=3.8
2-
NETBOX_VER?=v3.2.9
2+
NETBOX_VER?=v3.3.3
33

44
NAME=netbox-bgp
55

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ This plugin provide following Models:
66
* BGP Communities
77
* BGP Sessions
88
* Routing Policy
9-
* Prefix Lists (new in 0.7.0)
9+
* Prefix Lists
1010

1111
## Compatibility
1212

@@ -17,6 +17,7 @@ This plugin provide following Models:
1717
| NetBox 3.0 | 0.4.3 |
1818
| NetBox 3.1 | 0.5.0 |
1919
| NetBox 3.2 | >= 0.6.0 |
20+
| NetBox 3.3 | >= 0.8.1 |
2021

2122
## Installation
2223

netbox_bgp/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ class BGPConfig(PluginConfig):
1212
base_url = 'bgp'
1313
required_settings = []
1414
min_version = '3.2.0'
15-
max_version = '3.2.99'
15+
max_version = '3.3.99'
1616
default_settings = {
1717
'device_ext_page': 'right',
1818
}

netbox_bgp/api/serializers.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,13 @@
11
from rest_framework.serializers import HyperlinkedIdentityField, ValidationError
22
from rest_framework.relations import PrimaryKeyRelatedField
33

4-
from netbox.api import ChoiceField, WritableNestedSerializer
4+
# for netbox 3.3
5+
try:
6+
from netbox.api import ChoiceField, WritableNestedSerializer
7+
except ImportError:
8+
from netbox.api.fields import ChoiceField
9+
from netbox.api.serializers.nested import WritableNestedSerializer
10+
511
from netbox.api.serializers import NetBoxModelSerializer
612
from dcim.api.nested_serializers import NestedSiteSerializer, NestedDeviceSerializer
713
from tenancy.api.nested_serializers import NestedTenantSerializer
@@ -10,7 +16,7 @@
1016

1117
from netbox_bgp.models import (
1218
BGPSession, RoutingPolicy, BGPPeerGroup,
13-
Community, RoutingPolicyRule, PrefixList, PrefixListRule,
19+
Community, RoutingPolicyRule, PrefixList, PrefixListRule,
1420
)
1521

1622
from netbox_bgp.choices import CommunityStatusChoices, SessionStatusChoices

netbox_bgp/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "0.8.0"
1+
__version__ = "0.8.1"

0 commit comments

Comments
 (0)