After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 615506 - totem: Youtube Search lasts forever while playing Video
totem: Youtube Search lasts forever while playing Video
Status: RESOLVED FIXED
Product: totem
Classification: Core
Component: YouTube plugin
2.30.x
Other Linux
: Normal normal
: ---
Assigned To: General Totem maintainer(s)
General Totem maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2010-04-12 09:34 UTC by kojiroak
Modified: 2010-04-19 12:02 UTC
See Also:
GNOME target: ---
GNOME version: 2.29/2.30


Attachments
Add network timeout support to the YouTube plugin (2.36 KB, patch)
2010-04-16 18:57 UTC, Philip Withnall
committed Details | Review

Description kojiroak 2010-04-12 09:34:48 UTC
1.)Open Totem
2.)chose Youtube in the dropdown-list
3.)Search for a video
4.)play a video
5.)while the video is playing, search for an other video.

The search-bar keeps running but no video appears in the video-list. Also a click on abbort (german: abbrechen) has no effect.
Once it helped to click on search again when the "active" video finished, a second time it didn't work.

Also the Title in the window-decoration stayed from an other video.

Further informations can be found here https://bugs.launchpad.net/ubuntu/+source/totem/+bug/559862

(Note: I use totem under xfce/xfwm)
Comment 1 Philip Withnall 2010-04-12 10:20:51 UTC
What version of libgdata do you have installed?
Comment 2 kojiroak 2010-04-12 10:30:37 UTC
Oh I have to correct me, I thought Ubuntu Lucid uses 2.30 but it does use 2.28. (at least gnome-core is in this version) I hate when such a thing happens.

However 
libgdata1.2-1 is 2.8.3.1-0ubuntu1
libgdata6 is 0.5.1-1
Comment 3 Philip Withnall 2010-04-12 12:14:23 UTC
Can you get a network log of you reproducing the problem (i.e. the first working search plus a search which doesn't complete and some attempts to cancel it) please? You'll need to use Wireshark with a "tcp port http" filter (open Wireshark, press Ctrl+K, enter that filter, press "Start", then press Ctrl+E once you've finished and save the log). Thanks.
Comment 4 kojiroak 2010-04-12 13:11:53 UTC
It's near the end, it lastet a while till it occured. 

Beside of abbort I also tried to hit search again. (Which also had no effect).
I hope that helps you, otherwise let me know.

I hit abbort a few times more than I would normaly.

Since the file is to big for the upload as attachment, you can find it here
https://docs.google.com/leaf?id=0B3RwfteayBpVNTM2MjJkOTItODRjNS00OTJkLWIwNjEtYzUxOTMxNzNkMTk2&hl=en
Comment 5 Philip Withnall 2010-04-12 15:53:54 UTC
I can see a lot of searches in that log. Which ones demonstrated the problem? I see:
 * "gnome"
 * "Like a surgeon"
 * "in the middle of all that trouble again"
 * "Flying by your side"
 * "Flying through the air"
 * "YMCA"
 * "Amish Paradise"
 * "Test"

It looks like you're dropping a lot of packets too. You might want to check your network connection's working OK, since almost all of those queries had to be retransmitted to the server, according to this log.
Comment 6 kojiroak 2010-04-12 16:12:44 UTC
It should be Test.

This time I had really to do a lot searches for it to appear.
Before it was the second search or at lattest the third.

I'm directly connected to a UMTS-Stick, so I can't do much about the connection. That's on the side of the Provider.

At the time I ran the test, the connection was good, in the evening it gets worse.
Comment 7 Philip Withnall 2010-04-14 18:12:34 UTC
I think it's the fact that your connection is very lossy which is causing problems. If you can get me a stack trace of where the code is hanging, I might be able to improve how it copes with such network conditions.

Could you make sure you have the Totem and libgdata debug symbols installed (there should be packages of them called totem-dbg and libgdata-dbg, or something similar), then run Totem under gdb with these commands in a terminal:

gdb totem
run

Once Totem's running, reproduce the bug but *don't cancel the query*! Switch to the terminal and press Ctrl+C, then run the following command and copy the output here:

t a a bt

That should hopefully tell me where the code's hanging on a network response. Thanks.
Comment 8 kojiroak 2010-04-16 09:32:44 UTC
[New Thread 0xb43ffb70 (LWP 1723)]
^C
Program received signal SIGINT, Interrupt.
0x0012d422 in __kernel_vsyscall ()
(gdb) t
[Current thread is 1 (Thread 0xb7fde750 (LWP 1617))]
(gdb) a
Ambiguous command "a": actions, add-inferior, add-symbol-file, add-symbol-file-from-memory, advance, aliases, append...
(gdb) a
Ambiguous command "a": actions, add-inferior, add-symbol-file, add-symbol-file-from-memory, advance, aliases, append...
(gdb) t
[Current thread is 1 (Thread 0xb7fde750 (LWP 1617))]
(gdb) bt
  • #0 __kernel_vsyscall
  • #1 poll
    from /lib/tls/i686/cmov/libc.so.6
  • #2 g_poll
    from /lib/libglib-2.0.so.0
  • #3 ??
    from /lib/libglib-2.0.so.0
  • #4 g_main_loop_run
    from /lib/libglib-2.0.so.0
  • #5 gtk_main
    from /usr/lib/libgtk-x11-2.0.so.0
  • #6 main

@[New Thread 0xb43ffb70 (LWP 1723)] it hanged but it didn't display any further Information, do I have to give gdb some more arguments?

For sorry I have only libgdata6-dgbsym. I think that's the cause for the error with a.
Comment 9 Philip Withnall 2010-04-16 12:01:35 UTC
(In reply to comment #8)
> [New Thread 0xb43ffb70 (LWP 1723)]
> ^C
> Program received signal SIGINT, Interrupt.
> 0x0012d422 in __kernel_vsyscall ()
> (gdb) t
> [Current thread is 1 (Thread 0xb7fde750 (LWP 1617))]
> (gdb) a
> Ambiguous command "a": actions, add-inferior, add-symbol-file,
> add-symbol-file-from-memory, advance, aliases, append...
> (gdb) a
> Ambiguous command "a": actions, add-inferior, add-symbol-file,
> add-symbol-file-from-memory, advance, aliases, append...
> (gdb) t
> [Current thread is 1 (Thread 0xb7fde750 (LWP 1617))]
> (gdb) bt
> 

"t a a bt" is all one command, short for "thread apply all backtrace". Enter it all at once into gdb and then press enter, and you should get a much longer backtrace, spanning several pages. Thanks.
Comment 10 kojiroak 2010-04-16 16:30:41 UTC


Thread 20 (Thread 0xb45fcb70 (LWP 11698))

  • #0 __kernel_vsyscall
  • #1 read
    from /lib/tls/i686/cmov/libpthread.so.0
  • #2 ??
    from /lib/libglib-2.0.so.0
  • #3 g_io_channel_read_chars
    from /lib/libglib-2.0.so.0
  • #4 ??
    from /usr/lib/libsoup-2.4.so.1
  • #5 soup_socket_read_until
    from /usr/lib/libsoup-2.4.so.1
  • #6 ??
    from /usr/lib/libsoup-2.4.so.1
  • #7 ??
    from /usr/lib/libsoup-2.4.so.1
  • #8 soup_message_send_request
    from /usr/lib/libsoup-2.4.so.1
  • #9 soup_connection_send_request
    from /usr/lib/libsoup-2.4.so.1
  • #10 soup_session_send_queue_item
    from /usr/lib/libsoup-2.4.so.1
  • #11 ??
    from /usr/lib/libsoup-2.4.so.1
  • #12 ??
    from /usr/lib/libsoup-2.4.so.1
  • #13 soup_session_send_message
    from /usr/lib/libsoup-2.4.so.1
  • #14 _gdata_service_query
    at gdata-service.c line 986
  • #15 gdata_service_query

This time the connection is just bad. So I don't know if that's help you a lot, I will try to get an other one, while the connection is near to normal.
Comment 11 Philip Withnall 2010-04-16 18:55:46 UTC
I've just added support in libgdata for network timeouts. If this can be utilised in Totem, the YouTube plugin will behave more gracefully with dodgy network connections, which I think is the crux of the problem you're having.

commit e54748533b841ffa9decbb0245b1bdb39a86ae3e
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Fri Apr 16 19:45:30 2010 +0100

    Bug 615506 — totem: Youtube Search lasts forever while playing Video
    
    Add a #GDataService:timeout property, proxying the #SoupSession:timeout
    property, and allowing network requests to return with
    %GDATA_SERVICE_ERROR_NETWORK_ERROR if the timeout is exceeded.
    Helps: bgo#615506

 docs/reference/gdata-sections.txt |    2 +
 gdata/gdata-service.c             |   76 ++++++++++++++++++++++++++++++++++++-
 gdata/gdata-service.h             |    3 +
 gdata/gdata.symbols               |    2 +
 4 files changed, 81 insertions(+), 2 deletions(-)
Comment 12 Philip Withnall 2010-04-16 18:57:23 UTC
Created attachment 158917 [details] [review]
Add network timeout support to the YouTube plugin

Bastien, does this patch look sane? I can't up the libgdata dependency to 0.7.0, since it hasn't been released yet, and probably won't make the GNOME external dependency list, since it's a massive API break. Still, this code will work once 0.7.0 is released.
Comment 13 Philip Withnall 2010-04-19 12:01:51 UTC
commit 540aaa7a104de22128218dd96be2c1078d2a3f8c
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Fri Apr 16 19:54:06 2010 +0100

    Bug 615506 — totem: Youtube Search lasts forever while playing Video
    
    Use a network timeout of 30 seconds if it's supported by the version of
    libgdata we're building against. This will error out of queries if they take
    longer than 30 seconds. Closes: bgo#615506

 configure.in                        |    7 +++++++
 src/plugins/youtube/totem-youtube.c |    6 ++++++
 2 files changed, 13 insertions(+), 0 deletions(-)