Add fix-up for trailing comma with trailing space (#1409)
## Summary
Closes https://github.com/astral-sh/uv/issues/1361.
## Test Plan
```text
Resolved 3 packages in 243ms
Downloaded 3 packages in 193ms
Installed 3 packages in 6ms
+ et-xmlfile==1.1.0
+ jdcal==1.4.1
+ openpyxl==3.0.5
```