-
Notifications
You must be signed in to change notification settings - Fork 59
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
NullReferenceException with request parameters #126
Milestone
Comments
I think that I know what is wrong here... 😢 you call it with slack.ChatPostEphemeral(
threadTs = None, // <--- here is null in runtime
blocks = "",
attachments = "",
asUser = None, // <--- here is null in runtime
parse = "",
token = "",
text = "Hello",
user = "UNL9PF6P6",
linkNames = None, // <--- here is null in runtime
channel = "CPDMKJR34") |> Async.Ignore but when I transform it to (!0)new Tuple<string, string>("thread_ts", ((object)threadTs).ToString()), FSharpList.get_Empty())), (IEnumerable<Tuple<string, string>>)FSharpList.Cons(
(!0)new Tuple<string, string>("blocks", ((object)blocks).ToString()), FSharpList.get_Empty())), (IEnumerable<Tuple<string, string>>)FSharpList.Cons(
(!0)new Tuple<string, string>("attachments", ((object)attachments).ToString()), FSharpList.get_Empty())), (IEnumerable<Tuple<string, string>>)FSharpList.Cons(
(!0)new Tuple<string, string>("as_user", ((object)asUser).ToString()), FSharpList.get_Empty())), (IEnumerable<Tuple<string, string>>)FSharpList.Cons(
(!0)new Tuple<string, string>("parse", ((object)parse).ToString()), FSharpList.get_Empty())), (IEnumerable<Tuple<string, string>>)FSharpList.Cons(
(!0)new Tuple<string, string>("text", ((object)text).ToString()), FSharpList.get_Empty())), (IEnumerable<Tuple<string, string>>)FSharpList.Cons((
!0)new Tuple<string, string>("user", ((object)user).ToString()), FSharpList.get_Empty())), (IEnumerable<Tuple<string, string>>)FSharpList.Cons(
(!0)new Tuple<string, string>("link_names", ((object)linkNames).ToString()), FSharpList.get_Empty())), (IEnumerable<Tuple<string, string>>)FSharpList.Cons(
(!0)new Tuple<string, string>("channel", ((object)channel).ToString()), FSharpList.get_Empty()))); there is no workaround rather than provide |
sergey-tihon
added a commit
that referenced
this issue
Oct 30, 2019
Ohh that'd be it. Thank you so much! |
Closed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
I'm getting a NullReferenceException while constructing a request to the Slack API using their Swagger definition.
I'm unfamiliar with Type Providers so I'm not sure how to approach debugging it. Right now I'm poking through decompiled IL (see below).
Repro steps
See this test.
Expected behavior
Constructs a request and sends it (at which point it should get a authorization error).
Actual behavior
Known workarounds
None.
Related information
dev
Decompiled IL of ChatPostEphemeral method
Though I'm not sure how useful this is as even though I've added the DLLs to ILSpy I'm getting...
The text was updated successfully, but these errors were encountered: