Re: [twitter-dev] illegal character in json feed

2011-06-14 Thread Mike McNeil
Same thing's happening to me.  Check out:
 
http://search.twitter.com/search.json?q=%23jimromeisburning&callback=dog

Should look like this:
dog(
{
   
   - -
   results: [
  - -
  {
 - from_user_id_str: "257702817"
 - profile_image_url: "
 
http://a1.twimg.com/profile_images/1364757456/2011-05-22_13.20.33_normal.jpg
 "
 - created_at: "Tue, 14 Jun 2011 20:36:33 +"
 - from_user: "ATLienSince1987"
 - id_str: "80735397449183232"
 - -
 metadata: {
- result_type: "recent"
 }
 - to_user_id: null
 - text: "#JimRomeIsBurning"
 - id: 80735397449183230
 - from_user_id: 257702817
 - geo: null
 - iso_language_code: "is"
 - to_user_id_str: null
 - source: "Plume  "
  } ..
   ]
   - max_id: 80735397449183230
   - since_id: 0
   - refresh_url: "?since_id=80735397449183232&q=%23jimromeisburning"
   - results_per_page: 15
   - page: 1
   - completed_in: 0.185672
   - since_id_str: "0"
   - max_id_str: "80735397449183232"
   - query: "%23jimromeisburning"

}
)


But 3/5 times it doesn't, it looks like this:

dog( �  ݘYo�F ǿʚF݇Z��<  ��&��85b�)�  M�č�]�� 7�w��.ےl� 
҇�A�o�3�oN%��hj���7�_�2nkY�*���r�  A�iH �� U��
 �2 ȸ�
hϛf��X� 75�w�_� ��@ \� ńt��P  �R�2 kS�I�~ 
`���I#�8i`�^+  Ȏ��.󻌡_0|���`�}�{���P:�$
���M�8`�E �  e  K�$Y�$N��� qs=�л��ԍ���i�� NW�E 
�ȯֲ�SU~4�<�_��Vz0Y���,txǧNw��Cg �|VU��H���~MMf�P�sۀ�N��k�V��sP4� �WKk�g�h 
�J ��n�L  �i+�d1��M� � O  �g�E[ʿZ� <���{�m W�g�q ���]؈ � ���9  ���֏A� ] 
v9_��͔wi�CF0 a�qHE�+
Ǧ�P#� Um!�=��Y�`�T��  K+��1�� �c< �2�  =�� t��v߆A� $�� }�   * 
!�H��O� ��4��Dd ���X &�<5ʍ�[0қN���B�|2h#.D�� ��7�� � A@s#  ��  
O��  �Ę��>@љ�@ ��g� Z��"py\ Iw)bA�q(" ; �S$E  � F/e=��"O� �%� dG@*A � 
m���Թ� K�J~B'?�hTɦ�Fu[I��(;c��; � �Gpʇ�E�
dQ�IH�/ �.�p �E$ ��<�&��Q�L��< � ���*��Gb{4 �Y� �S��.�/$���۪ �����υ��P 
�f��8�OP- ���>���Z͏�� `ky�'�� D��Lt���D�I� A~ 'M�[ �Od E'5�#:sڥj��� 
>��Dz9.Z��/��]Q�Y�~�x d3+���f{���,� JIP�M �=� % h$���圜���m���>%|���_M�  
���Q�#,�*Osj�V\ �� 7B���C`�p��  r  odҡ���M n�Z1�N   �p(v)�|p (
�Xd���fȵP�!�@�A �p E��hW �d<��*iP�fPY%5J��  �ٯ���џ�Rܶj �eW P  'ۡ� �a
�   c ��3b�kc� �p��v i�O� 
zB�u��K���r��.r�Do[��uq��zf�ؤ��oSu�� �TM�  ۥ${��R u1 �� 
���>�E�H 5�-(=�7���ZA�   ���ei8*�Tvd�TY���L�� yf�t   �� = ��Z�w1�H�@� 
p�*v� ~Ru�N�ܶ �C5���!jJmVC��\��  s�ptk��[ w�^2�){.��q �}���j�wI
�K�XնY��3m�Am,/o��7x8� ���&�p�`  @>#�ż��ʸ�/� �lv�#�� vi�-���`2娐 
'�aE�Ɗ % � �/m�!�� �
D x );


Stackoverflow question:
http://stackoverflow.com/questions/6348065/sencha-touch-jsonp-error

-- 
Twitter developer documentation and resources: https://dev.twitter.com/doc
API updates via Twitter: https://twitter.com/twitterapi
Issues/Enhancements Tracker: https://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
https://groups.google.com/forum/#!forum/twitter-development-talk


Re: [twitter-dev] illegal character in json feed

2011-06-13 Thread michael hazzard
Taylor,

Firefox 4.01 on Windows Server 2003 and IE8 on Windows Server 2003
 (I believe they are both fully utf-8 compatible)
(using jQuery 1.3.2 js library, I would upgrade but I am stuck at it w/
other dependencies )

Can you not reproduce the error on the jsFiddle?
(I will test on my ubuntu laptop when I get home)

As for the tweetid/url it is happening on multiple but I have
http://search.twitter.com/search.json?q=from:LansdowneResort&rpp=1&callback=?

hard-coded in the jsfiddle example and its showing error after a couple
iterations.

In any event, if you cannot, I am fine w/ the window.onerror error handling
I have implemented and have it working in both browsers now and have
implemented dom caching so as not to make too many requests.

Update:
I just tested in chrome and it threw
search.json:1Uncaught
SyntaxError: Unexpected token ILLEGAL
http://search.twitter.com/search.json?q=from:TrumpSoHo&rpp=1&callback=jsonp1308002393614&_=1308002425423

So I imagine maybe it is an OS/charset thing.

Thanks
//mh

On Mon, Jun 13, 2011 at 5:20 PM, Taylor Singletary <
taylorsinglet...@twitter.com> wrote:

> It would be very helpful if you could provide a specific Tweet ID that
> is exhibiting this behavior -- the test case you're presenting is a bit
> artificial. Do you know if the environment you're doing this consumption is
> fully capable of understanding the UTF-8 character set? Tweets can contain
> just about any UTF-8 character and your parsing should be prepared for
> that.
>
> On a side note, executing a specific query against the Search API every six
> seconds isn't the most efficient use of the API. Have you considered
> increasing the time you wait to poll and using additional Search API feature
> like since_id?
>
> @episod  - Taylor
> Singletary
>
>
> On Mon, Jun 13, 2011 at 12:49 PM, michael hazzard  > wrote:
>
>> Oh answers to #2 and #3
>>
>> 2) I am polling the jsonp api every second in this test but it will be
>> changed for production to like 6 seconds and cached after all 30 feeds are
>> loaded
>>
>> 3) No, I haven't tried outside the browser since this is strictly a jsonp
>> feed and I chose jsonp over server-side xml but now regretting a bit.
>>
>> //mh
>>
>>
>>
>> On Mon, Jun 13, 2011 at 3:43 PM, michael hazzard > > wrote:
>>
>>> Taylor();
>>>
>>> I took a pic of firebug here:
>>>
>>> https://docs.google.com/leaf?id=0B1lcI5OlKM2xNDczZDdmYTMtMjFjZi00Y2E2LWE4MTMtM2YyM2I5ZTM4Njhl&sort=name&layout=list&num=50
>>>
>>>
>>> It is similar to this case (I believe the same chars)
>>>
>>> http://groups.google.com/group/twitter-development-talk/browse_thread/thread/7567404004266db5?pli=1
>>>
>>> It is reproducible on the jsfiddle url if you look at the error console
>>> usually 10-20 iterations.
>>>
>>> http://jsfiddle.net/NBCGf/34/
>>>
>>> (Note: I recently added window.onerror to get around it for now and
>>> continue loading feeds.)
>>>
>>> Thanks,
>>> //mh
>>>
>>>
>>> On Mon, Jun 13, 2011 at 3:13 PM, Taylor Singletary <
>>> taylorsinglet...@twitter.com> wrote:
>>>
 Do you have more details about the specific illegal character(s) you're
 receiving? How frequently are you polling the API? Have you tried
 reproducing your scenario outside of a browser-based environment?

 @episod  - Taylor
 Singletary



 On Mon, Jun 13, 2011 at 11:55 AM, miramardesign <
 miramardes...@gmail.com> wrote:

> All browsers throw error "illegal character" in twitter jsonp feed
>
> http://jsfiddle.net/NBCGf/34/
>
> Please advise,
> //mh
>
> --
> Twitter developer documentation and resources:
> https://dev.twitter.com/doc
> API updates via Twitter: https://twitter.com/twitterapi
> Issues/Enhancements Tracker:
> https://code.google.com/p/twitter-api/issues/list
> Change your membership to this group:
> https://groups.google.com/forum/#!forum/twitter-development-talk
>

  --
 Twitter developer documentation and resources:
 https://dev.twitter.com/doc
 API updates via Twitter: https://twitter.com/twitterapi
 Issues/Enhancements Tracker:
 https://code.google.com/p/twitter-api/issues/list
 Change your membership to this group:
 https://groups.google.com/forum/#!forum/twitter-development-talk

>>>
>>>
>>>
>>> --
>>> Thank You,
>>>
>>> Michael Hazzard
>>> (954) 247-4461 
>>>
>>>
>>>
>>
>>
>> --
>> Thank You,
>>
>> Michael Hazzard
>> (954) 247-4461 
>>
>>
>>  --
>> Twitter developer documentation and resources:
>> https://dev.twitter.com/doc
>> API updates via Twitter: https://twitter.com/twitterapi

Re: [twitter-dev] illegal character in json feed

2011-06-13 Thread Taylor Singletary
It would be very helpful if you could provide a specific Tweet ID that
is exhibiting this behavior -- the test case you're presenting is a bit
artificial. Do you know if the environment you're doing this consumption is
fully capable of understanding the UTF-8 character set? Tweets can contain
just about any UTF-8 character and your parsing should be prepared for
that.

On a side note, executing a specific query against the Search API every six
seconds isn't the most efficient use of the API. Have you considered
increasing the time you wait to poll and using additional Search API feature
like since_id?

@episod  - Taylor
Singletary


On Mon, Jun 13, 2011 at 12:49 PM, michael hazzard
wrote:

> Oh answers to #2 and #3
>
> 2) I am polling the jsonp api every second in this test but it will be
> changed for production to like 6 seconds and cached after all 30 feeds are
> loaded
>
> 3) No, I haven't tried outside the browser since this is strictly a jsonp
> feed and I chose jsonp over server-side xml but now regretting a bit.
>
> //mh
>
>
>
> On Mon, Jun 13, 2011 at 3:43 PM, michael hazzard 
> wrote:
>
>> Taylor();
>>
>> I took a pic of firebug here:
>>
>> https://docs.google.com/leaf?id=0B1lcI5OlKM2xNDczZDdmYTMtMjFjZi00Y2E2LWE4MTMtM2YyM2I5ZTM4Njhl&sort=name&layout=list&num=50
>>
>>
>> It is similar to this case (I believe the same chars)
>>
>> http://groups.google.com/group/twitter-development-talk/browse_thread/thread/7567404004266db5?pli=1
>>
>> It is reproducible on the jsfiddle url if you look at the error console
>> usually 10-20 iterations.
>>
>> http://jsfiddle.net/NBCGf/34/
>>
>> (Note: I recently added window.onerror to get around it for now and
>> continue loading feeds.)
>>
>> Thanks,
>> //mh
>>
>>
>> On Mon, Jun 13, 2011 at 3:13 PM, Taylor Singletary <
>> taylorsinglet...@twitter.com> wrote:
>>
>>> Do you have more details about the specific illegal character(s) you're
>>> receiving? How frequently are you polling the API? Have you tried
>>> reproducing your scenario outside of a browser-based environment?
>>>
>>> @episod  - Taylor
>>> Singletary
>>>
>>>
>>>
>>> On Mon, Jun 13, 2011 at 11:55 AM, miramardesign >> > wrote:
>>>
 All browsers throw error "illegal character" in twitter jsonp feed

 http://jsfiddle.net/NBCGf/34/

 Please advise,
 //mh

 --
 Twitter developer documentation and resources:
 https://dev.twitter.com/doc
 API updates via Twitter: https://twitter.com/twitterapi
 Issues/Enhancements Tracker:
 https://code.google.com/p/twitter-api/issues/list
 Change your membership to this group:
 https://groups.google.com/forum/#!forum/twitter-development-talk

>>>
>>>  --
>>> Twitter developer documentation and resources:
>>> https://dev.twitter.com/doc
>>> API updates via Twitter: https://twitter.com/twitterapi
>>> Issues/Enhancements Tracker:
>>> https://code.google.com/p/twitter-api/issues/list
>>> Change your membership to this group:
>>> https://groups.google.com/forum/#!forum/twitter-development-talk
>>>
>>
>>
>>
>> --
>> Thank You,
>>
>> Michael Hazzard
>> (954) 247-4461 
>>
>>
>>
>
>
> --
> Thank You,
>
> Michael Hazzard
> (954) 247-4461 
>
>
>  --
> Twitter developer documentation and resources: https://dev.twitter.com/doc
> API updates via Twitter: https://twitter.com/twitterapi
> Issues/Enhancements Tracker:
> https://code.google.com/p/twitter-api/issues/list
> Change your membership to this group:
> https://groups.google.com/forum/#!forum/twitter-development-talk
>

-- 
Twitter developer documentation and resources: https://dev.twitter.com/doc
API updates via Twitter: https://twitter.com/twitterapi
Issues/Enhancements Tracker: https://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
https://groups.google.com/forum/#!forum/twitter-development-talk


Re: [twitter-dev] illegal character in json feed

2011-06-13 Thread michael hazzard
Oh answers to #2 and #3

2) I am polling the jsonp api every second in this test but it will be
changed for production to like 6 seconds and cached after all 30 feeds are
loaded

3) No, I haven't tried outside the browser since this is strictly a jsonp
feed and I chose jsonp over server-side xml but now regretting a bit.

//mh


On Mon, Jun 13, 2011 at 3:43 PM, michael hazzard wrote:

> Taylor();
>
> I took a pic of firebug here:
>
> https://docs.google.com/leaf?id=0B1lcI5OlKM2xNDczZDdmYTMtMjFjZi00Y2E2LWE4MTMtM2YyM2I5ZTM4Njhl&sort=name&layout=list&num=50
>
>
> It is similar to this case (I believe the same chars)
>
> http://groups.google.com/group/twitter-development-talk/browse_thread/thread/7567404004266db5?pli=1
>
> It is reproducible on the jsfiddle url if you look at the error console
> usually 10-20 iterations.
>
> http://jsfiddle.net/NBCGf/34/
>
> (Note: I recently added window.onerror to get around it for now and
> continue loading feeds.)
>
> Thanks,
> //mh
>
>
> On Mon, Jun 13, 2011 at 3:13 PM, Taylor Singletary <
> taylorsinglet...@twitter.com> wrote:
>
>> Do you have more details about the specific illegal character(s) you're
>> receiving? How frequently are you polling the API? Have you tried
>> reproducing your scenario outside of a browser-based environment?
>>
>> @episod  - Taylor
>> Singletary
>>
>>
>>
>> On Mon, Jun 13, 2011 at 11:55 AM, miramardesign 
>> wrote:
>>
>>> All browsers throw error "illegal character" in twitter jsonp feed
>>>
>>> http://jsfiddle.net/NBCGf/34/
>>>
>>> Please advise,
>>> //mh
>>>
>>> --
>>> Twitter developer documentation and resources:
>>> https://dev.twitter.com/doc
>>> API updates via Twitter: https://twitter.com/twitterapi
>>> Issues/Enhancements Tracker:
>>> https://code.google.com/p/twitter-api/issues/list
>>> Change your membership to this group:
>>> https://groups.google.com/forum/#!forum/twitter-development-talk
>>>
>>
>>  --
>> Twitter developer documentation and resources:
>> https://dev.twitter.com/doc
>> API updates via Twitter: https://twitter.com/twitterapi
>> Issues/Enhancements Tracker:
>> https://code.google.com/p/twitter-api/issues/list
>> Change your membership to this group:
>> https://groups.google.com/forum/#!forum/twitter-development-talk
>>
>
>
>
> --
> Thank You,
>
> Michael Hazzard
> (954) 247-4461 
>
>
>


-- 
Thank You,

Michael Hazzard
(954) 247-4461 

-- 
Twitter developer documentation and resources: https://dev.twitter.com/doc
API updates via Twitter: https://twitter.com/twitterapi
Issues/Enhancements Tracker: https://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
https://groups.google.com/forum/#!forum/twitter-development-talk


Re: [twitter-dev] illegal character in json feed

2011-06-13 Thread michael hazzard
Taylor();

I took a pic of firebug here:
https://docs.google.com/leaf?id=0B1lcI5OlKM2xNDczZDdmYTMtMjFjZi00Y2E2LWE4MTMtM2YyM2I5ZTM4Njhl&sort=name&layout=list&num=50


It is similar to this case (I believe the same chars)
http://groups.google.com/group/twitter-development-talk/browse_thread/thread/7567404004266db5?pli=1

It is reproducible on the jsfiddle url if you look at the error console
usually 10-20 iterations.
http://jsfiddle.net/NBCGf/34/

(Note: I recently added window.onerror to get around it for now and continue
loading feeds.)

Thanks,
//mh

On Mon, Jun 13, 2011 at 3:13 PM, Taylor Singletary <
taylorsinglet...@twitter.com> wrote:

> Do you have more details about the specific illegal character(s) you're
> receiving? How frequently are you polling the API? Have you tried
> reproducing your scenario outside of a browser-based environment?
>
> @episod  - Taylor
> Singletary
>
>
>
> On Mon, Jun 13, 2011 at 11:55 AM, miramardesign 
> wrote:
>
>> All browsers throw error "illegal character" in twitter jsonp feed
>>
>> http://jsfiddle.net/NBCGf/34/
>>
>> Please advise,
>> //mh
>>
>> --
>> Twitter developer documentation and resources:
>> https://dev.twitter.com/doc
>> API updates via Twitter: https://twitter.com/twitterapi
>> Issues/Enhancements Tracker:
>> https://code.google.com/p/twitter-api/issues/list
>> Change your membership to this group:
>> https://groups.google.com/forum/#!forum/twitter-development-talk
>>
>
>  --
> Twitter developer documentation and resources: https://dev.twitter.com/doc
> API updates via Twitter: https://twitter.com/twitterapi
> Issues/Enhancements Tracker:
> https://code.google.com/p/twitter-api/issues/list
> Change your membership to this group:
> https://groups.google.com/forum/#!forum/twitter-development-talk
>



-- 
Thank You,

Michael Hazzard
(954) 247-4461 

-- 
Twitter developer documentation and resources: https://dev.twitter.com/doc
API updates via Twitter: https://twitter.com/twitterapi
Issues/Enhancements Tracker: https://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
https://groups.google.com/forum/#!forum/twitter-development-talk


Re: [twitter-dev] illegal character in json feed

2011-06-13 Thread Taylor Singletary
Do you have more details about the specific illegal character(s) you're
receiving? How frequently are you polling the API? Have you tried
reproducing your scenario outside of a browser-based environment?

@episod  - Taylor
Singletary


On Mon, Jun 13, 2011 at 11:55 AM, miramardesign wrote:

> All browsers throw error "illegal character" in twitter jsonp feed
>
> http://jsfiddle.net/NBCGf/34/
>
> Please advise,
> //mh
>
> --
> Twitter developer documentation and resources: https://dev.twitter.com/doc
> API updates via Twitter: https://twitter.com/twitterapi
> Issues/Enhancements Tracker:
> https://code.google.com/p/twitter-api/issues/list
> Change your membership to this group:
> https://groups.google.com/forum/#!forum/twitter-development-talk
>

-- 
Twitter developer documentation and resources: https://dev.twitter.com/doc
API updates via Twitter: https://twitter.com/twitterapi
Issues/Enhancements Tracker: https://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
https://groups.google.com/forum/#!forum/twitter-development-talk


[twitter-dev] illegal character in json feed

2011-06-13 Thread miramardesign
All browsers throw error "illegal character" in twitter jsonp feed

http://jsfiddle.net/NBCGf/34/

Please advise,
//mh

-- 
Twitter developer documentation and resources: https://dev.twitter.com/doc
API updates via Twitter: https://twitter.com/twitterapi
Issues/Enhancements Tracker: https://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
https://groups.google.com/forum/#!forum/twitter-development-talk