rest-api-samples icon indicating copy to clipboard operation
rest-api-samples copied to clipboard

🐛 fixing RequestField and encode_multipart_formdata imports

Open fiorotticaio opened this issue 2 months ago • 2 comments

Historically, requests "vendorized" urllib3 (and others), and you could import RequestField and encode_multipart_formdata via requests.packages.urllib3....

In recent versions, requests no longer includes urllib3 "inside" itself; it depends on urllib3 installed in the environment.

The requests.packages module is now just a shim, and the type stubs (packages.pyi) don't expose urllib3

fiorotticaio avatar Oct 03 '25 20:10 fiorotticaio

Thanks for the contribution! Before we can merge this, we need @fiorotticaio to sign the Salesforce Inc. Contributor License Agreement.

salesforce-cla[bot] avatar Oct 03 '25 20:10 salesforce-cla[bot]

The label cla:missing is appearing, but I have already authenticated myself in CLA

fiorotticaio avatar Oct 03 '25 20:10 fiorotticaio