-2
我正在網站上使用此代碼示例來搜索庫中的特定短語。奇怪的Twitter4J錯誤 - 「JSONObject [」座標「]不是一個字符串。」
Twitter twitter = TwitterFactory.getSingleton();
Query query = new Query("source:twitter4j yusukey");
QueryResult result = twitter.search(query);
for (Status status : result.getTweets()) {
System.out.println("@" + status.getUser().getScreenName() + ":" + status.getText());
}
然而,我似乎得到一個Twitter例外:
JSONObject["coordinates"] not a string.
Relevant discussions can be found on the Internet at:
http://www.google.co.jp/search?q=8c005e6e or
http://www.google.co.jp/search?q=c45cf3de
TwitterException{exceptionCode=[8c005e6e-c45cf3de 8c005e6e-c45cf3d6], statusCode=-1, message=null, code=-1, retryAfter=-1, rateLimitStatus=null, version=3.0.0}
at twitter4j.internal.json.z_T4JInternalJSONImplFactory.createGeoLocation(z_T4JInternalJSONImplFactory.java:96)
at twitter4j.internal.json.StatusJSONImpl.init(StatusJSONImpl.java:110)
at twitter4j.internal.json.StatusJSONImpl.<init>(StatusJSONImpl.java:76)
at twitter4j.internal.json.QueryResultJSONImpl.<init>(QueryResultJSONImpl.java:87)
at twitter4j.internal.json.z_T4JInternalJSONImplFactory.createQueryResult(z_T4JInternalJSONImplFactory.java:155)
at twitter4j.TwitterImpl.search(TwitterImpl.java:260)
at GrammarChecker.checkStatuses(GrammarChecker.java:70)
at GrammarChecker$1.actionPerformed(GrammarChecker.java:42)
at java.awt.Button.processActionEvent(Unknown Source)
at java.awt.Button.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.awt.EventQueue.access$200(Unknown Source)
at java.awt.EventQueue$3.run(Unknown Source)
at java.awt.EventQueue$3.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)
at java.awt.EventQueue$4.run(Unknown Source)
at java.awt.EventQueue$4.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
行號表示的點到呼叫 「twitter.search(查詢)」。
有沒有人有任何想法?