-
Notifications
You must be signed in to change notification settings - Fork 285
Open
Description
On the paragraph Parsing Twitter stream:
After creating the
Tweettype, we parse a single sample tweet and print some details about the tweet. As you can see, thetweet.Userproperty has been inferred as optional (meaning that a tweet might not have an author?) so we unsafely get the value using theValueproperty. TheRetweetCountandTextproperties may be also missing, so we also access them unsafely.
No, all those fields are not optional. If you see the data it contains Tweets and some delete event objects of which structure is vastly different from the one of Tweet.
{"delete":{"status":{"id":3179185988182016,"id_str":"3179185988182016","user_id_str":"126735178","user_id":126735178}}}This causes the type provider mark every field optional, which is not very useful...