Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Content-Type header expects duplicate values #302

Open
mefellows opened this issue Jul 27, 2023 · 3 comments
Open

Content-Type header expects duplicate values #302

mefellows opened this issue Jul 27, 2023 · 3 comments
Labels
bug Indicates an unexpected problem or unintended behavior smartbear-supported SmartBear engineering team will support this issue. See https://docs.pact.io/help/smartbear

Comments

@mefellows
Copy link
Member

Rather than repeat the repro/details, this is an upstream issue to track pact-foundation/pact-js#1106.

@mefellows mefellows added bug Indicates an unexpected problem or unintended behavior smartbear-supported SmartBear engineering team will support this issue. See https://docs.pact.io/help/smartbear labels Jul 27, 2023
@github-actions
Copy link

👋 Hi! The 'smartbear-supported' label has just been added to this issue, which will create an internal tracking ticket in PactFlow's Jira (PACT-1220). We will use this to prioritise and assign a team member to this task. All activity will be public on this ticket. For now, sit tight and we'll update this ticket once we have more information on the next steps.

See our documentation for more information.

@YOU54F
Copy link
Member

YOU54F commented Aug 9, 2023

Yes also seen this

#305 (comment)

Should be actually be warning the user on the consumer side that they have duplicate values in the content-type header.

I think it stems from setting a request header with content type and a body in which you need to set the content_type header, it states that it should use the content_type header if set.

Is there ever a case for a multi-value content-type header that has the same value as both indexes? or would you expect to have something else like a variant application/json+problem;

@mefellows
Copy link
Member Author

It's a bug, in that prior to this version the behaviour was different. Any implementation that allows a user to specify the content-type header (which would be all of them) will have this problem, and you actually want to be able to do this to make the test explicit. Guarding this in the FFI client libraries means a lot of duplication.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Indicates an unexpected problem or unintended behavior smartbear-supported SmartBear engineering team will support this issue. See https://docs.pact.io/help/smartbear
Projects
None yet
Development

No branches or pull requests

2 participants