Troubleshooting

Why Your Fetch Order Tracking Loop-Updates the Same 25 Rows

You've configured Fetch Order Tracking to automate your eBay × AliExpress order tracking, expecting a seamless flow of data into your Google Sheet. However, you notice a recurring issue: the auto-update process consistently re-processes and updates the same 25 rows, often without pulling new orders or resolving existing tracking discrepancies. This isn't just inefficient; it can lead to missed updates, slow down your sheet, and hit your API limits unnecessarily.

This behavior typically indicates a problem with how your sheet is requesting data or how the Fetch Order Tracking API is interpreting those requests. It's rarely a 'bug' in the system, but rather a misconfiguration or a misunderstanding of the underlying data synchronization logic.

Understanding the 25-Row Update Cycle

Fetch Order Tracking processes updates in batches. The '25 rows' you're seeing is often a default or a consequence of how your sheet is configured to identify which orders need attention. The system isn't arbitrarily picking these rows; it's responding to a specific query from your sheet.

Common Causes for Looping Updates

  1. Incorrect Status Filtering: Your sheet might be configured to only request updates for orders with specific, unresolved statuses (e.g., ORDER_PLACED, IN_TRANSIT) that never fully resolve to a 'final' state due to a data mismatch or an unhandled edge case.
  2. Missing 'Last Updated' Timestamp: If your sheet doesn't correctly record or use a gmt_modified or last_sync_timestamp for each row, the system might repeatedly treat the same rows as 'needing an update'.
  3. API Rate Limits & Throttling: While less common for 25 specific rows, if your sheet is hitting API limits, subsequent requests might time out or return partial data, leading to a retry loop on the same set.
  4. Data Inconsistencies: Sometimes, the AliExpress data itself can be stuck in an ambiguous state (e.g., logistics_status not changing, order_status not advancing) which prevents Fetch Order Tracking from marking it as 'resolved' in your sheet.
  5. Google Sheets Script Logic Errors: If you're using custom Google Apps Script to trigger or filter updates, there might be a bug in your script that always returns the same 25 order IDs for processing.

Diagnosing the Problem

The first step is to pinpoint why those specific 25 rows are being targeted repeatedly.

1. Inspect Your Google Sheet's Update Logic

Examine the formulas or scripts you're using to trigger Fetch Order Tracking. Are you filtering by a specific column? For instance, if you're only updating rows where order_status is AWAITING_SHIPMENT and those orders are genuinely stuck, they will always be included.

Check columns like:

  • order_status: Is it stuck in a non-final state?
  • logistics_status: Is it perpetually IN_TRANSIT without resolution?
  • gmt_refund: Are you trying to update rows with pending refunds that aren't resolving?
  • end_reason: Is this column not being populated, indicating an unresolved state?

2. Review Fetch Order Tracking Logs

Your Fetch Order Tracking dashboard provides logs for each API call. Look for repeated requests for the same order IDs. Pay attention to the payload of the request – what filters are being sent? Are the same 25 order_id values consistently present in the requests?

The system updates what you tell it to update. If you repeatedly ask for updates on the same 25 orders, it will repeatedly attempt to provide them, even if the underlying data hasn't changed.

3. Manual Spot Check on AliExpress

For a few of the problematic order IDs, manually check their status on AliExpress. Is the status on AliExpress different from what's in your sheet? This can highlight if the issue is with data retrieval or with how your sheet interprets the retrieved data.

Solutions to Break the Loop

Once you've identified the root cause, applying the fix is usually straightforward.

1. Implement a 'Last Updated' Timestamp

A robust solution involves tracking when each row was last successfully updated. Add a new column to your sheet, e.g., Fetch_Last_Updated. When an order is successfully updated by Fetch Order Tracking, populate this column with the current timestamp.

Then, modify your update logic to only request updates for:

  • Orders where Fetch_Last_Updated is older than X hours (e.g., 24 hours).
  • Orders that are in a non-final state (e.g., order_status is not FINISH, CANCELED, REFUND_COMPLETED, BUYER_ACCEPT_GOODS).

This ensures that orders are re-checked periodically, but not incessantly.

2. Refine Your Status Filtering

Ensure your update queries are intelligent about order statuses. If an order has reached a final state like BUYER_ACCEPT_GOODS or FINISH, it generally doesn't need further tracking updates unless you're specifically monitoring for post-delivery issues like refunds.

Consider a filter like: WHERE order_status NOT IN ('FINISH', 'CANCELED', 'REFUND_COMPLETED', 'BUYER_ACCEPT_GOODS') AND logistics_status NOT IN ('DELIVERED', 'COMPLETED').

3. Handle Edge Cases for Refunds

If the 25 rows are related to refunds, ensure your sheet correctly processes the gmt_refund and refund_status fields. An order might be FINISH but still have a pending refund. Your logic needs to account for these specific refund statuses to mark them as resolved.

4. Optimize Google Apps Script (if applicable)

If you're using custom scripts:

  • Batch Requests: Instead of making individual API calls for each order, batch your requests to Fetch Order Tracking. This is more efficient and less likely to hit rate limits.
  • Error Handling: Implement robust error handling. If an API call fails, log the error and decide whether to retry immediately or mark it for a later retry.
  • Conditional Updates: Only trigger updates for rows that genuinely require them, based on the 'Last Updated' timestamp and current status.

5. Manually Mark Resolved Orders

For particularly stubborn orders that are genuinely resolved on AliExpress but remain active in your sheet's update queue, manually mark them as 'resolved' in your sheet or exclude them from the auto-update scope for a cycle.

Example Workflow for Breaking the Loop

  1. Add a 'Sync Status' Column: Create a new column, say D:SyncStatus, and a E:LastSyncTime column.
  2. Initial Update Query: Your Fetch Order Tracking query should target orders where SyncStatus is not 'Complete' AND LastSyncTime is older than 24 hours (or empty).
  3. Update Processing: When Fetch Order Tracking returns data, update the relevant fields.
  4. Conditional Completion: If order_status is FINISH or BUYER_ACCEPT_GOODS, AND logistics_status is DELIVERED or COMPLETED, AND there's no pending gmt_refund, set SyncStatus to 'Complete'.
  5. Timestamp Update: Always update LastSyncTime for any row that was processed, regardless of whether its status changed or not.

By implementing a clear mechanism to mark orders as 'complete' and only re-checking orders that are either incomplete or haven't been checked recently, you can break the repetitive 25-row update cycle and ensure your Fetch Order Tracking works efficiently.

If you continue to experience issues after reviewing these points, consult the detailed documentation or reach out to support with specific order IDs and your sheet's setup details to get tailored assistance. For more information on optimizing your tracking workflow, visit Fetch Order Tracking.


Try the fetcher More guides