Refactor to trigger curl only explicitly via URL to avoid accidental commiting of curl logging to production. Fix bug in layer detection. Transmit error traces as strings when available.