Troubleshooting Guide

Common issues and solutions for the E-Invoice extension.

E-Invoice Not Generated

Symptoms

  • Invoice created but no e-invoice
  • Status remains "pending" or empty

Solutions

  1. Check if enabled

    • Verify E-Invoicing is enabled for the store view
    • Stores >Configuration > MageB2B > E-Invoice > General Settings > Enable E-Invoicing: Yes
  2. Check generation mode

    • Immediate: Should generate on invoice save
    • Queued: Check queue consumer is running
    • Cron: Wait for cron (hourly/daily) or check cron status
  3. Check logs

    tail -100 var/log/system.log tail -100 var/log/exception.log
  4. Verify company data

    • VAT ID must be configured
    • All required fields must be filled

Validation Errors

"Invalid VAT ID format"

  • VAT ID must include country prefix (e.g., DE123456789)
  • Check for extra spaces or special characters

"IBAN validation failed"

  • IBAN must be valid and include country code
  • Verify with your bank

"Leitweg-ID required"

This extension does not require a Leitweg-ID for XRechnung generation (B2B usage). If you need B2G submission requirements, validate and enrich the XML in your integration layer.

PDF Generation Issues

PDF Not Created (ZUGFeRD/Factur-X)

  1. Check Magento PDF works

    • Try generating a standard invoice PDF
    • If that fails, fix Magento PDF first
  2. Check library installation

    composer show horstoeko/zugferd
  3. Check PHP extensions

    • Ensure zlib extension is enabled
    • Ensure dom extension is enabled
  4. Check memory

    • PDF generation requires memory
    • Increase memory_limit if needed

PDF Corrupted

  • Check file permissions in media/einvoice/
  • Verify disk space is available
  • Check for PHP warnings during generation

Queue/Cron Issues

Queue Not Processing

  1. Check consumer is running

    php bin/magento queue:consumers:list php bin/magento queue:consumers:start mageb2b.einvoice.generate
  2. Check message queue configuration

    • Verify env.php queue settings
    • Verify your queue backend/consumer setup for the mageb2b.einvoice.generate consumer

Cron Not Running

  1. Check cron status

    php bin/magento cron:run --group=default
  2. Verify crontab

    • Ensure Magento cron is configured
    • Check system crontab entries

File Storage Issues

Files Not Saved

  1. Check directory permissions

    ls -la pub/media/einvoice/ chmod -R 775 pub/media/einvoice/ chown -R www-data:www-data pub/media/einvoice/
  2. Check disk space

    df -h
  3. Verify storage path

    • Check configured path in settings
    • Ensure it's relative to media directory

Files Not Found

  • Check Storage Strategy (Permanent vs On-Demand)
  • Check filename pattern settings (Invoice/Credit Memo Filename Pattern)
  • Verify files exist under the configured storage path
  • Check for file system errors

Performance Issues

Slow Invoice Creation (Immediate Mode)

  • Switch to Queued or Cron mode
  • Reduce validation level
  • Review other heavy customizations or integrations running during invoice creation

High Memory Usage

  • Process invoices in smaller batches
  • Increase PHP memory limit
  • Use cron mode for high volume

Debug Checklist

When troubleshooting:

  1. [ ] E-Invoicing is enabled for the store
  2. [ ] Generation mode is correctly configured
  3. [ ] Company data is complete (VAT ID, etc.)
  4. [ ] For queued: consumer is running
  5. [ ] For cron: cron is configured
  6. [ ] File permissions are correct
  7. [ ] Disk space is available
  8. [ ] Checked all log files (system.log, exception.log)

Getting Help

If issues persist:

  1. Collect relevant log excerpts
  2. Note the exact error message
  3. Document steps to reproduce
  4. Contact support at info@softwaresilo.io

Found an issue with this documentation? Let us know