Thank you so much Tim for calling my attention to this issue and all the valuable research you did on your end, and the insight you provided me with to help me understand where this issue could be coming from!
I can’t say with certainty that everyone here is experiencing the same problem, although they look similar. My guess is that the issue happens when there is a paid trial term for a subscription, and the subscription creation fails but the invoice item for the initial term succeeded. Each time the subscription is attempted, a new invoice item was created, until the subscription finally succeeds and all items from the previous attempts are charged.
Tim told me that he’s seeing the problem with a paid trial sub. I also see the invoice item in Alan’s log. I think James’ is also the case. I don’t have enough info from Tim or Corey to say if their cases are the same.
I was able to reproduce the duplicate invoice item behavior with paid trials in my tests. I found how to avoid duplicates, and fixed the problem in my tests.
I’m attaching the updated file for you to test if you can, please. 200413b-stripe-utilities.inc.zip (11.6 KB)
It’s not a full release of s2Member Pro, it’s just the relevant file for s2Member Pro v200301. It goes here: s2member-pro/src/includes/classes/gateways/stripe/stripe-utilities.inc.php
I look forward to your feedback.