pb&j taste like soap
It seems likely that there was some form of residue left behind in the container; whether this was actual soap or just the scent is difficult to determine.  I have found that soap scents do tend to cling a bit more stubbornly to plastic than they do to other materials, but that's just my experience.

Next time you might try rinsing the container and drying it out with a clean towel after washing.

Alternatively, you might simply discontinue using this particular soap.  It may be particularly clingy or perhaps you're just sensitive to its scent.