Reputation: 157
I'm using scala
and twitter4j
to extract tweets. I'm following this tutorial. I did exactly the same for the location as mentioned in the example as:
val austinBox = Array(Array(-97.8,30.25),Array(-97.65,30.35))
twitterStream.filter(new FilterQuery().locations(austinBox))
I'm getting this error as:
Error:(64, 54) type mismatch;
found : Array[Array[Double]]
required: Array[Double]
I changed the value to Array[Double]
as:
val austinBox = Array(-97.8,30.25)
twitterStream.filter(new FilterQuery().locations(austinBox))
Now i'm getting 406 error code
which is returned only when the search format is not accepted.
Any help would be highly useful.
Upvotes: 1
Views: 269
Reputation: 1035
please check your twitter4j version. it looks like the current version (>+=4.0.X) is still under development. So using 3.0.5 will make the code working.
Upvotes: 1