postman-to-k6 icon indicating copy to clipboard operation
postman-to-k6 copied to clipboard

The "path" argument must be of type string. Received type object

Open qite-poper opened this issue 2 years ago • 5 comments

{
									"name": "xxx",
									"request": {
										"method": "POST",
										"header": [],
										"body": {
											"mode": "formdata",
											"formdata": [
												{
													"key": "file",
													"description": "required",
													"type": "file",
													"src": []
												}
											]
										},
										"url": {
											"raw": "xxx",
											"host": [
												"xxx"
											],
											"path": [
												"xxx"
											]
										}
									},
									"response": []
								}

The default value is of src is []. If I replace it with a string, then the postman-to-k6 will work fine.

qite-poper avatar Sep 08 '22 07:09 qite-poper

Linked to #28

thim81 avatar Sep 13 '22 09:09 thim81

Correct, currently the postman-to-k6 library is not fully capable of handling "files". I still have to investigate if this is a bug or feature.

thim81 avatar Sep 13 '22 09:09 thim81

I think it is a bug of Postman.

qite-poper avatar Sep 13 '22 09:09 qite-poper

hi @qite-poper

We just released v.18.7 of postman-to-k6, which introduces the support for file uploads. The conversion from Postman uploads can take various shapes, so I tried to bring support for the binary upload.

If the issue is resolved, feel free to close this item. Let me know if you have other use cases or run into other issues.

thim81 avatar Jan 14 '23 15:01 thim81

Hi @thim81 I have the same problem with my collection

For_k6.postman_collection.json

bugaeva98 avatar Dec 04 '23 06:12 bugaeva98