With .replaceAll(), the port of ticket_branch.py builds Python’s slug. The line that tidies the title, title.strip().rstrip("."), drops PAY-2304’s full stop, which both the review bot and git reject. JavaScript’s string toolkit is smaller than Python’s, and this line is where it shows.
Strip the Full Stop From PAY-2304
With strip() as .trim() and rstrip() as .trimEnd(), the port follows the Python code line by line:
Language: JavaScript
const key = "PAY-2304";
const rawTitle = " Retry failed card payments.";
const title = rawTitle.trim().trimEnd(".");
console.log(`Commit: ${key}: ${title}`);
Python prints the subject without the full stop. Predict the port’s line, then run it: