Skip to content

Conversation

@FragmentedPacket
Copy link
Contributor

@FragmentedPacket FragmentedPacket commented Oct 13, 2025

Summary by CodeRabbit

  • Bug Fixes
    • Improved error message when IP Fabric connection details are missing. The message now clearly instructs how to provide the base URL and token via configuration or the IPF_URL/IPF_TOKEN environment variables, making setup issues easier to diagnose.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Oct 13, 2025

Walkthrough

The change updates the error message in infrahub_sync/adapters/ipfabricsync.py within the _create_ipfabric_client function. When either base_url or auth is missing, the raised error message now includes explicit guidance that these can be provided via configuration or through the IPF_URL and IPF_TOKEN environment variables. No functional logic or control flow was modified, and no public interfaces were changed.

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The title succinctly reflects the primary change by stating that the ipfabric adapter’s authentication error message is updated, making it clear and specific without extraneous details.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch may-202510-ipf-msg-update

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 1ce77d1 and 6c48f22.

📒 Files selected for processing (1)
  • infrahub_sync/adapters/ipfabricsync.py (1 hunks)
🔇 Additional comments (1)
infrahub_sync/adapters/ipfabricsync.py (1)

62-62: LGTM! Helpful error message improvement.

The updated error message now explicitly mentions the IPF_URL and IPF_TOKEN environment variables, making it much more actionable for users who encounter this error. This aligns well with the actual implementation logic that checks these environment variables as fallbacks.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@cloudflare-workers-and-pages
Copy link

Deploying infrahub-sync with  Cloudflare Pages  Cloudflare Pages

Latest commit: 6c48f22
Status: ✅  Deploy successful!
Preview URL: https://30fdaf69.infrahub-sync.pages.dev
Branch Preview URL: https://may-202510-ipf-msg-update.infrahub-sync.pages.dev

View logs

@BeArchiTek BeArchiTek added the type/task Body of work related to an epic label Oct 13, 2025
@BeArchiTek BeArchiTek merged commit a8ae669 into main Oct 13, 2025
15 checks passed
@BeArchiTek BeArchiTek deleted the may-202510-ipf-msg-update branch October 13, 2025 14:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type/task Body of work related to an epic

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants