Skip to content

Commit cca1b0a

Browse files
Merge pull request netbox-community#16132 from netbox-community/develop
Release v4.0.2
2 parents a3f7dc0 + 70c0aec commit cca1b0a

File tree

53 files changed

+2253
-2111
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+2253
-2111
lines changed

.github/ISSUE_TEMPLATE/bug_report.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ body:
2626
attributes:
2727
label: NetBox Version
2828
description: What version of NetBox are you currently running?
29-
placeholder: v4.0.1
29+
placeholder: v4.0.2
3030
validations:
3131
required: true
3232
- type: dropdown

.github/ISSUE_TEMPLATE/feature_request.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ body:
1414
attributes:
1515
label: NetBox version
1616
description: What version of NetBox are you currently running?
17-
placeholder: v4.0.1
17+
placeholder: v4.0.2
1818
validations:
1919
required: true
2020
- type: dropdown

.github/workflows/close-stale-issues.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ on:
77
workflow_dispatch:
88

99
permissions:
10+
actions: write
1011
issues: write
1112
pull-requests: write
1213

base_requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ social-auth-app-django
131131
strawberry-graphql
132132

133133
# Strawberry GraphQL Django extension
134-
# https://github.com/strawberry-graphql/strawberry-django/blob/main/CHANGELOG.md
134+
# https://github.com/strawberry-graphql/strawberry-django/releases
135135
strawberry-graphql-django
136136

137137
# SVG image rendering (used for rack elevations)

docs/configuration/security.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -159,9 +159,12 @@ Note that enabling this setting causes NetBox to update a user's session in the
159159

160160
## LOGIN_REQUIRED
161161

162-
Default: False
162+
Default: True
163+
164+
When enabled, only authenticated users are permitted to access any part of NetBox. Disabling this will allow unauthenticated users to access most areas of NetBox (but not make any changes).
163165

164-
Setting this to True will permit only authenticated users to access any part of NetBox. By default, anonymous users are permitted to access most data in NetBox but not make any changes.
166+
!!! info "Changed in NetBox v4.0.2"
167+
Prior to NetBox v4.0.2, this setting was disabled by default.
165168

166169
---
167170

docs/configuration/system.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,3 +198,11 @@ If `STORAGE_BACKEND` is not defined, this setting will be ignored.
198198
Default: UTC
199199

200200
The time zone NetBox will use when dealing with dates and times. It is recommended to use UTC time unless you have a specific need to use a local time zone. Please see the [list of available time zones](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
201+
202+
---
203+
204+
## TRANSLATION_ENABLED
205+
206+
Default: True
207+
208+
Enables language translation for the user interface. (This parameter maps to Django's [USE_I18N](https://docs.djangoproject.com/en/stable/ref/settings/#std-setting-USE_I18N) setting.)

docs/release-notes/version-4.0.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,28 @@
11
# NetBox v4.0
22

3+
## v4.0.2 (2024-05-14)
4+
5+
!!! warning "Important"
6+
This release includes an important security fix, and is a strongly recommended update for all users. More details will follow.
7+
8+
### Enhancements
9+
10+
* [#15119](https://github.com/netbox-community/netbox/issues/15119) - Add cluster & cluster group UI filter fields for VLAN groups
11+
* [#16090](https://github.com/netbox-community/netbox/issues/16090) - Include current NetBox version when an unsupported plugin is detected
12+
* [#16096](https://github.com/netbox-community/netbox/issues/16096) - Introduce the `ENABLE_TRANSLATION` configuration parameter
13+
* [#16107](https://github.com/netbox-community/netbox/issues/16107) - Change the default value for `LOGIN_REQUIRED` to True
14+
* [#16127](https://github.com/netbox-community/netbox/issues/16127) - Add integration point for unsupported settings
15+
16+
### Bug Fixes
17+
18+
* [#16077](https://github.com/netbox-community/netbox/issues/16077) - Fix display of parameter values when viewing configuration revisions
19+
* [#16078](https://github.com/netbox-community/netbox/issues/16078) - Fix integer filters mistakenly marked as required for GraphQL API
20+
* [#16101](https://github.com/netbox-community/netbox/issues/16101) - Fix initial loading of pagination widget for dynamic object tables
21+
* [#16123](https://github.com/netbox-community/netbox/issues/16123) - Fix custom script execution via REST API
22+
* [#16124](https://github.com/netbox-community/netbox/issues/16124) - Fix GraphQL API support for querying virtual machine interfaces
23+
24+
---
25+
326
## v4.0.1 (2024-05-09)
427

528
### Enhancements

netbox/dcim/views.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2093,7 +2093,6 @@ class DeviceVirtualMachinesView(generic.ObjectChildrenView):
20932093
child_model = VirtualMachine
20942094
table = VirtualMachineTable
20952095
filterset = VirtualMachineFilterSet
2096-
template_name = 'generic/object_children.html'
20972096
tab = ViewTab(
20982097
label=_('Virtual Machines'),
20992098
badge=lambda obj: VirtualMachine.objects.filter(cluster=obj.cluster, device=obj).count(),
@@ -2986,7 +2985,6 @@ class InventoryItemChildrenView(generic.ObjectChildrenView):
29862985
child_model = InventoryItem
29872986
table = tables.InventoryItemTable
29882987
filterset = filtersets.InventoryItemFilterSet
2989-
template_name = 'generic/object_children.html'
29902988
tab = ViewTab(
29912989
label=_('Children'),
29922990
badge=lambda obj: obj.child_items.count(),

netbox/extras/api/views.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -240,9 +240,9 @@ def post(self, request, pk):
240240
raise RQWorkerNotRunningException()
241241

242242
if input_serializer.is_valid():
243-
script.result = Job.enqueue(
243+
Job.enqueue(
244244
run_script,
245-
instance=script.module,
245+
instance=script,
246246
name=script.python_class.class_name,
247247
user=request.user,
248248
data=input_serializer.data['data'],

netbox/extras/tables/tables.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
import json
22

33
import django_tables2 as tables
4-
from django.conf import settings
54
from django.utils.translation import gettext_lazy as _
65

76
from extras.models import *
7+
from netbox.constants import EMPTY_TABLE_TEXT
88
from netbox.tables import BaseTable, NetBoxTable, columns
99
from .template_code import *
1010

@@ -550,7 +550,7 @@ class ScriptResultsTable(BaseTable):
550550
)
551551

552552
class Meta(BaseTable.Meta):
553-
empty_text = _('No results found')
553+
empty_text = _(EMPTY_TABLE_TEXT)
554554
fields = (
555555
'index', 'time', 'status', 'message',
556556
)
@@ -581,7 +581,7 @@ class ReportResultsTable(BaseTable):
581581
)
582582

583583
class Meta(BaseTable.Meta):
584-
empty_text = _('No results found')
584+
empty_text = _(EMPTY_TABLE_TEXT)
585585
fields = (
586586
'index', 'method', 'time', 'status', 'object', 'url', 'message',
587587
)

0 commit comments

Comments
 (0)