[PR #16697] [MERGED] Closes #16307: Enable calling log_* methods on Script without a log message #14885

Closed
opened 2025-12-29 23:27:16 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netbox-community/netbox/pull/16697
Author: @jeremystretch
Created: 6/24/2024
Status: Merged
Merged: 6/24/2024
Merged by: @jeremystretch

Base: developHead: 16307-scripts-log-message-optional


📝 Commits (1)

  • 40027b4 Closes #16307: Enable calling log_* methods on Script without a log message

📊 Changes

2 files changed (+23 additions, -19 deletions)

View changed files

📝 docs/customization/custom-scripts.md (+7 -5)
📝 netbox/extras/scripts.py (+16 -14)

📄 Description

Fixes: #16307

  • Convert the message argument on all Script log_*() methods to an optional keyword argument
  • Record test method logs only if message is not null/empty
  • Update documentation

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netbox-community/netbox/pull/16697 **Author:** [@jeremystretch](https://github.com/jeremystretch) **Created:** 6/24/2024 **Status:** ✅ Merged **Merged:** 6/24/2024 **Merged by:** [@jeremystretch](https://github.com/jeremystretch) **Base:** `develop` ← **Head:** `16307-scripts-log-message-optional` --- ### 📝 Commits (1) - [`40027b4`](https://github.com/netbox-community/netbox/commit/40027b498e94b19bcb03089875cffc1e93bf8291) Closes #16307: Enable calling log_* methods on Script without a log message ### 📊 Changes **2 files changed** (+23 additions, -19 deletions) <details> <summary>View changed files</summary> 📝 `docs/customization/custom-scripts.md` (+7 -5) 📝 `netbox/extras/scripts.py` (+16 -14) </details> ### 📄 Description ### Fixes: #16307 - Convert the `message` argument on all Script `log_*()` methods to an optional keyword argument - Record test method logs only if `message` is not null/empty - Update documentation --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-29 23:27:16 +01:00
adam closed this issue 2025-12-29 23:27:16 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#14885