test_create_playlist_from_songs_tab test fails on phone: ToolkitException: No actions in overflow

Bug #1338935 reported by Martin Pitt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu Music App
Won't Fix
Undecided
Unassigned

Bug Description

I just ran current lp:music-app (r516) on the phone (image 117, music click app version 1.3.511) and got this failure:

======================================================================
ERROR: music_app.tests.test_music.TestMainWindow.test_create_playlist_from_songs_tab(with touch)
----------------------------------------------------------------------
[long log, see attachment]
Traceback (most recent call last):
  File "/tmp/adt-run.tKozYP/tree/tests/autopilot/music_app/tests/test_music.py", line 461, in test_create_playlist_from_songs_tab
    self.main_view.tap_new_playlist_action()
  File "/tmp/adt-run.tKozYP/tree/tests/autopilot/music_app/emulators.py", line 83, in tap_new_playlist_action
    header.click_action_button('newplaylistButton')
  File "/tmp/adt-run.tKozYP/deps/usr/lib/python3/dist-packages/ubuntuuitoolkit/_custom_proxy_objects/_header.py", line 172, in click_action_button
    button = self._get_action_button(action_object_name)
  File "/tmp/adt-run.tKozYP/deps/usr/lib/python3/dist-packages/ubuntuuitoolkit/_custom_proxy_objects/_header.py", line 184, in _get_action_button
    action_object_name)
  File "/tmp/adt-run.tKozYP/deps/usr/lib/python3/dist-packages/ubuntuuitoolkit/_custom_proxy_objects/_header.py", line 197, in _get_action_button_in_overflow
    raise _common.ToolkitException('No actions in overflow')
ubuntuuitoolkit._custom_proxy_objects._common.ToolkitException: No actions in overflow

Revision history for this message
Martin Pitt (pitti) wrote :
Revision history for this message
Victor Thompson (vthompson) wrote :

This test ran just fine for me on the same image (#117) from trunk--I ran it a few times: http://paste.ubuntu.com/7767875/

Is this a consistent failure that you're seeing? Or is it intermittent?

Revision history for this message
Martin Pitt (pitti) wrote :

I ran it three times now, both the whole test suite and that individual test. I upgraded to image 121 now, and still the same.

I ran this with autopkgtest:

bzr checkout --lightweight lp:music-app
PHABLET_TOOLS_PATH=~/ubuntu/phablet-tools adt-run music-app/ --click=com.ubuntu.music --- ssh -s /usr/share/autopkgtest/ssh-setup/adb

I wanted to try with phablet-test-run, but I seem to have trouble with that. phablet-click-test-setup succeeded, but then "phablet-test-run -v music_app.tests.test_music.TestMainWindow.test_create_playlist_from_songs_tab" just fails with

  sh: 1: /usr/bin/python: not found

If I just run "./phablet-test-run -v music_app" this doesn't happen, so I wonder how your command works for you? If I sh -x it, I see

+ adb shell cd /home/phablet/autopilot; /usr/bin/python3 -c 'import music_app.tests.test_music.TestMainWindow.test_create_playlist_from_songs_tab'
+ import_error=The ubuntuuitoolkit.emulators module is deprecated. Import the autopilot helpers from the top-level ubuntuuitoolkit module.
Traceback (most recent call last):
  File "<frozen importlib._bootstrap>", line 2218, in _find_and_load_unlocked
AttributeError: 'module' object has no attribute '__path__'

and then it falls back to python2 which is (deliberately) not installed.

So both methods (autopkgtest and phablet-test-run) eventually call "python3 -m autopilot.run run <test>", but apparently in a slightly different environment. Weird that it only affects this one test though, do you know whether that does something special that depends on another package to be installed, or an environment variable or so?

Revision history for this message
Victor Thompson (vthompson) wrote :

Actually, I think I have my phablet-test-run script modified to intentionally use python3 when running individual tests. I'm AFK right now, but I think the change was just to one line in the script to use python3.

I was unable to use autopkgtest previously, due to a timeout issue. I can try to run again later tonight. I'm unsure why there'd be a difference in the two methods of running the test.

David Planella (dpm)
Changed in music-app:
status: New → Incomplete
Changed in music-app:
status: Incomplete → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.