Comments (6)
Checking the API.json for this, their shape doesn't include a body
type, but only querystring
types. Maybe the generator could check this instead? 🤔
from aws-elixir.
I fixed the problem by setting an empty body for GET requests. According to the HTTP specs we shouldn't have a body in case of a GET or HEAD or OPTIONS requests, so I think this is safe. This fix was released in v0.9.1
. Thank you all!
from aws-elixir.
Hi @pranavraja 👋
Perhaps we shouldn't encode when the input
is nil
. Or maybe GET requests shouldn't be encode. I'm not sure :/
I will take a look later this week, but if you don't mind to confirm that and open the PR, it would be awesome! :D
from aws-elixir.
Yeah not sure which option would be cleaner, in any case I checked the repo and all uses of :get
pass in nil
as the input
anyway, whereas other http verbs do pass in an input
, so it seems either way would fix the issue. Do you have a preference?
from aws-elixir.
@pranavraja sorry for the delay. I think we can go with not encoding GET
requests. WDYT?
from aws-elixir.
We have the same issue for describe_input
, describe_channel
. In the meanwhile we resolved it with the following code:
defmodule OurApp.AWS.MediaLive do
def describe_channel(client, id) do
request(client, "/prod/channels/#{AWS.Util.encode_uri(id)}")
end
def describe_input(client, id) do
request(client, "/prod/inputs/#{AWS.Util.encode_uri(id)}")
end
defp request(client, url) do
AWS.Request.request_rest(
client,
AWS.MediaLive.metadata(),
:get,
url,
[],
[],
%{"Body" => ""},
[send_body_as_binary?: true],
200
)
end
end
from aws-elixir.
Related Issues (20)
- nxdomain errror when using AWS.Location.search_place_index_for_text HOT 7
- Loading issue with modules that shouldn't be generated: AWS.Cloudsearchdomain and AWS.Importexport (Instead of CamelCase counterparts) HOT 2
- AWS.ApiGatewayManagementApi, URL and headers with stage HOT 1
- S3 put_object returns {:error, :timeout} but uploads file correctly HOT 5
- `AWS.S3.delete_objects` content md5 header HOT 5
- SelectObjectContent response HOT 1
- `AWS.STS.assume_role_with_web_identity` should not rely on access_key_id and secret_access_key
- Error calling textractor HOT 3
- Setting endpoint to `amazonaws.com` results in different behaviour as not setting an endpoint HOT 1
- AWS.S3.get_object always returns {:error, :timeout} with hackney > 1.18.1 HOT 5
- Streaming response handling HOT 10
- `put_bucket_cors` request is incorrect HOT 5
- Setup pipeline to automatically roll out new releases upon tagging
- S3 ListParts returns wrong types HOT 7
- QLDB Commit Transaction HOT 2
- NXDOMAIN when calling CostExplorer.get_cost_and_usage HOT 5
- Cannot get AWS Polly synthesize_speech to work HOT 3
- :nxdomain when calling AWS.CloudFront.list_distributions HOT 5
- Wrong region for Route53 requests HOT 12
- AWS.TimestreamWrite does not work. HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aws-elixir.