Tesla did a decent market test on batteries, the test failed and they moved on.
They rolled out this service to a couple of spots in California, which was probably sufficient for the the credit regime, but ended up not expanding the program further and terminating it after a few quarters. The official explanation was that it was not widely used.
https://youtu.be/H5V0vL3nnHY?t=57
There may have been other business reasons. I have no idea what was discussed on the executive level but wouldn't be surprised if they considered some tradeoffs of complexity, costs and customer attractivenes to not be worth it. Honestly, it's very rare that you actually need or strongly prefer to have this kind of service rather than just recharging at 150kW for 15 minutes. So if it adds considerable cost or complexity, I could understand the decision to drop it.
A short time later, they started welding an extra metal shield onto the bottom of the Model S, to act as an extra layer of protection against collisions with highway debris that caused some high-profile battery fires. I had the impression that this precluded battery swap, so at that point the business decision must have been made to not expand the program further.
If the regulatory incentives was key in the decision to do this and then later drop it, that's a fundamental property of incentives to do something that might not be a good idea in isolation.
A short summary of the extra government subsidy Tesla got out of the non-existing battery swaps is here: https://seekingalpha.com/article/2724835-after-earning-tens-...
I understand that the structure of the car's body may be suboptimal and require extra reinforcement but if we're really serious about EV adoption and reducing battery cost then perhaps a trade-off worth making?
So assume your vehicle has 3 packs. You normally run it with just one pack because that's all you need to commute and run errands during the week. When you go visit the relatives in Florida, you install the other two packs to get the additional range. The car needs additional structural elements to meet safety standards when the extra packs aren't installed and they add 5% additional weight. That's weight you're carrying around every day, and that has a range cost.
Could it be worth it to swap out the extra structure elements when you install the extra packs, so at least you aren't taking the range penalty while driving long distance? Yes, but the manufacturer isn't going to want the liability of a customer removing what is a passive safety device, and then forgetting to reinstall it when they go back to city travel using only one pack.
NHTSA will also have input to this. From what I can tell - the applicable FMVSS is this one that deals with EV side impact protection, electrolyte spills, and electric shock.
https://www.nhtsa.gov/document/final-rule-occupant-protectio...
Lots of companies (even Tesla) have attempted the replaceable battery concept but none have been able to make it work efficiently.