Troubleshooting

Order Daemon Docs

8. Troubleshooting

This page helps you diagnose common issues and quickly get back to a healthy, automated workflow. It uses plain language and links to other guides when deeper steps are needed.


Quick checks (start here)

  • WooCommerce is active
  • Order Daemon depends on WooCommerce. If WooCommerce is deactivated, Order Daemon will not fully initialize.
  • Correct user role
  • Use a Shop Manager or Administrator account to see menus and run diagnostics.
  • Rule is enabled
  • Draft rules do not run. Open the rule and ensure it’s published/enabled.
  • Test with a new order
  • Place a fresh test order to avoid confusion with older data and timelines.

Common installation issues

  • WooCommerce missing or outdated
    Symptom: You don’t see “Order Daemon” menu with “All Order Rules” or “Insight Dashboard”; some features don’t appear.
    Fix: Install/activate WooCommerce and update to a supported version. Then reload your admin.
  • Pro is active but Core is missing
    Symptom: Pro says it’s active but nothing is unlocked.
    Fix: Install and activate the free Order Daemon plugin (Core). Pro is an add‑on and depends on Core.
  • Menus not visible (no access)
    Symptom: You can’t find Order Daemon → All Order Rules or Order Daemon → Insight Dashboard.
    Fix: Ensure your account can manage WooCommerce (Shop Manager or Administrator). Log out and back in if roles were just changed.

A rule didn’t run (rule not firing)

Checklist

  1. Trigger happened: Confirm the event you picked actually occurred (e.g., status changed to Processing, payment completed).
  2. Conditions match: If you added conditions (categories, product types, totals), all of them must pass.
  3. Rule is enabled: Draft rules won’t run.
  4. New test order: Use a new order that clearly meets (or does not meet) your conditions.

Use the Audit Log to investigate

  1. Go to Order Daemon → Insight Dashboard.
  2. Find the entry around the time of your test.
  3. Open the details panel to see which conditions passed or failed and why.
  4. Guide: /docs/audit-log/

Special cases

  1. Payment gateways that delay confirmations may use webhooks; rules run after the confirmation arrives. See /docs/webhooks-and-integrations/.

Orders not completing as expected

  • Interference from other plugins
    Payment, fulfillment, fraud, or status‑management plugins may alter order status. Temporarily disable non‑essential plugins to test.
  • Gateway behavior differences
    Some gateways set status directly; others rely on a webhook. If your gateway needs a webhook, configure it and test. See /docs/webhooks-and-integrations/.
  • Conflicting rules
    If multiple rules might apply, refine conditions so each rule targets a distinct scenario.

Translation and language issues

  • Strings appear in English
    Set your Site Language under Settings → General.
    Ensure you’re on the latest plugin version so translation files are current.
  • Script/UI strings
    Admin screens load JSON translations for the Rule Builder and Insight dashboard automatically when available.
  • More help
    See Security & Privacy notes on data handling and localization: /docs/security-and-privacy/

Performance and scaling

  • Large number of rules
    Keep rules focused and avoid heavy, overlapping conditions. Start simple and expand gradually.
  • Checkout impact
    Rules generally run after order events. If you notice slowdowns, test on a staging site and check the Audit Log timestamps. Use the Diagnostics Dashboard to review environment health.
  • Cron/Background processing
    Ensure your site can run scheduled tasks (WP‑Cron). Your host or a cron service can help ensure reliability.

Diagnostics Dashboard

  • Where to find it
    Order Daemon → Diagnostics.
  • What it does
    Runs health checks for environment, permissions, REST endpoints, and translations.
  • When to use it
    Before contacting support or after changing settings. It often points directly to the root cause.
  • Guide: /docs/diagnostics-dashboard/

Frequently asked questions (FAQ)

  • Does this modify past orders?
    Rules run when their trigger happens. To change older orders, create a clear rule and run “Reprocess Pending Orders” from the Insight Dashboard settings.
  • Will this affect checkout speed?
    The plugin is designed to process events efficiently. Use the Diagnostics Dashboard and Audit Log to monitor behavior.
  • Where are logs stored?
    The plugin writes structured entries for the Insight dashboard. See /docs/audit-log/ for how to read them.

Getting support

Share helpful details

  • A copy-paste of the Diagnostics summary and any specific issues.
  • Order numbers used for testing and approximate timestamps.
  • Your WordPress, WooCommerce, and plugin versions.
  • Relevant Audit Log entries (screenshots or copied summaries). Timeline events raw json payloads are good for this.

Where to look before contacting support

  • Diagnostics Dashboard: /docs/diagnostics-dashboard/
  • Audit Log: /docs/audit-log/
  • Getting Started: /docs/getting-started/

Developer Troubleshooting (including Pro plugin features)

Common Development Issues

CLI Commands Not Found

  • Issue: wp odcm commands not available
  • Solution: Ensure Pro plugin is installed and active. Core plugin does not include CLI commands.
  • Verification:
  wp plugin list --field=name,status | grep -E 'order-daemon|completion'

Rule Execution Problems

  • Issue: Rules not firing as expected
  • Debugging Steps:
  1. Check rule status: wp odcm rule list
  2. Verify triggers and conditions match the test scenario
  3. Examine audit logs: wp odcm log list --type=rule_execution --format=json
  4. Test with simple rule first, then add complexity

Capability and Permission Issues

  • Issue: “Permission denied” errors in CLI or admin
  • Solution: Ensure user has manage_woocommerce capability
  • Verification:
  // Check capability programmatically
  if (current_user_can('manage_woocommerce')) {
      // User has required capability
  }

Advanced Debugging Techniques

Audit Log Analysis

# List recent logs with filtering
wp odcm log list --limit=50 --format=json

# Filter by specific criteria
wp odcm log list --order-id=123 --type=error --format=json

# View detailed log entry
wp odcm log view --id=456 --format=json

Rule Configuration Validation

# List all rules to verify configuration
wp odcm rule list --format=json

# Check rule status and details
wp odcm rule list --status=active --format=table

Performance Monitoring

# Run health check to identify performance issues
wp odcm health check --format=json

# Check specific performance category
wp odcm health check --category=performance --format=table

Integration Troubleshooting

Webhook Issues

  • Verification: Check webhook payloads and signatures
  • Debugging:
  # List webhook-related logs
  wp odcm log list --type=webhook --format=json

  # Check system health for webhook configuration
  wp odcm health check --category=api

Custom Component Problems

  • Issue: Custom triggers, conditions, or actions not working
  • Debugging Steps:
  1. Verify component registration in code
  2. Check capability requirements
  3. Test with minimal configuration
  4. Examine component-specific logs

Configuration Management

Environment Differences

  • Issue: Rules behave differently between staging and production
  • Solution: Export and compare configurations
  # Export current configuration for comparison
  wp odcm config export --format=json --output=current-config.json

  # Compare with reference configuration
  wp odcm config diff --local=reference-config.json

Migration Problems

  • Issue: Issues after migrating between environments
  • Solution: Validate configuration before and after migration
  # Validate current configuration
  wp odcm health check --format=summary

  # Export configuration for migration
  wp odcm config export --format=json --output=migration-config.json

Best Practices for Development

  1. Start Simple: Test with basic rules before adding complexity
  2. Use Dry-Run Mode: Preview changes before applying them
   wp odcm rule activate 123 --dry-run
  1. Monitor Logs: Regularly check audit logs during development
   wp odcm log list --limit=20 --format=table
  1. Version Control: Track configuration changes in version control
  2. Environment Parity: Keep development, staging, and production environments similar

Common Error Patterns

Rule Not Found (404)

  • Verify rule ID exists: wp odcm rule list
  • Check rule status (active vs inactive)

Capability Denied

  • Ensure Pro license is active for premium features
  • Verify user has required capabilities

Configuration Validation Errors

  • Check JSON syntax in configuration files
  • Verify all required fields are present
  • Ensure component IDs are valid

Performance Issues

  • Monitor rule execution times with health checks
  • Limit complex conditions in high-volume stores
  • Use batch processing for large operations

Resources for Developers

  • CLI Documentation: /docs/developers/cli-and-automation/
  • Audit Log Extensions: /docs/developers/audit-log-extensions/
  • Extending Rules: /docs/developers/extending-rules/
  • API Reference: /docs/api/rest-api/

For advanced issues, consult the developer documentation or contact support with detailed logs and configuration information.

Was this article helpful?

  • Loading...
Table of Contents
  • Loading...