-
Couldn't load subscription status.
- Fork 12
fix: retrieve object states using concrete models #60
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Parent:
feat: diode data plugin 1.0 rc
mfiedorowicz
merged 9 commits into
feat-diode-data-plugin
from
fix-object-state-retrieval
Feb 14, 2025
Merged
fix: retrieve object states using concrete models #60
mfiedorowicz
merged 9 commits into
feat-diode-data-plugin
from
fix-object-state-retrieval
Feb 14, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Search backend/CachedValue is global and doesn't seem to be reliable with branching Signed-off-by: Michal Fiedorowicz <mfiedorowicz@netboxlabs.com>
Signed-off-by: Michal Fiedorowicz <mfiedorowicz@netboxlabs.com>
Signed-off-by: Michal Fiedorowicz <mfiedorowicz@netboxlabs.com>
Signed-off-by: Michal Fiedorowicz <mfiedorowicz@netboxlabs.com>
☂️ Python Coverage
Overall Coverage
New FilesNo new covered files... Modified Files
|
leoparente
approved these changes
Feb 13, 2025
* fix: add backwards compatible support for mac_address field
Signed-off-by: Michal Fiedorowicz <mfiedorowicz@netboxlabs.com>
Signed-off-by: Michal Fiedorowicz <mfiedorowicz@netboxlabs.com>
ltucker
approved these changes
Feb 14, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request includes several updates to the
netbox_diode_pluginto improve compatibility with the latest NetBox version, enhance serializers, and refactor API views for better performance and maintainability. The most important changes include upgrading the NetBox version, modifying serializers to handle site fields dynamically, and refactoring API views to improve query handling and validation.Compatibility Updates:
docker/Dockerfile-diode-netbox-plugin: Updated the base image tonetboxcommunity/netbox:v4.2.3-3.1.1to ensure compatibility with the latest NetBox version.docker/docker-compose.yaml: Updated the image version tonetboxcommunity/netbox:v4.2.3-3.1.1-diode-netbox-plugin.netbox_diode_plugin/__init__.py: Updated the minimum NetBox version to4.2.3in theNetBoxDiodePluginConfigclass.Serializer Enhancements:
netbox_diode_plugin/api/serializers.py: ModifiedDiodePrefixSerializerandDiodeClusterSerializerto useSerializerMethodFieldfor thesitefield and added methods to dynamically get the site from the instance scope. [1] [2]API View Refactoring:
netbox_diode_plugin/api/views.py: Refactored the_search_querysetmethod to use search index classes and added validation for query fields. Introduced new helper methods for dynamic imports and field validation. [1] [2]netbox_diode_plugin/api/views.py: Added_transform_object_datamethod to handle object data transformations based on object type, including handling IP address assigned objects and scope objects.Test Adjustments:
netbox_diode_plugin/tests/test_api_apply_change_set.py: Added setup for virtual machines to support new test cases for the updated API views.