python code does not pass the flake8 static checks

Bug #1444170 reported by Leo Arias
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
camera-app
Fix Released
Undecided
Leo Arias
qakit
New
Undecided
Federico Gimenez
ubuntu-keyboard
Fix Released
Undecided
Leo Arias
address-book-app (Ubuntu)
Fix Released
Undecided
Federico Gimenez
camera-app (Ubuntu)
Fix Released
Undecided
Unassigned
ubuntu-keyboard (Ubuntu)
Vivid
New
Undecided
Unassigned
unity8 (Ubuntu)
Fix Released
Medium
Unity UI Team
webbrowser-app (Ubuntu)
Fix Released
Undecided
Leo Arias
Vivid
New
Undecided
Unassigned

Bug Description

Flake8 checks that the python code follows the right code style, and does some static checks for errors.

This branch is not passing the static tests.

Related branches

Michał Sawicz (saviq)
Changed in unity8 (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
Michał Sawicz (saviq)
Changed in unity8 (Ubuntu):
status: Triaged → In Progress
assignee: nobody → Michał Sawicz (saviq)
Leo Arias (elopio)
Changed in webbrowser-app (Ubuntu):
status: New → In Progress
assignee: nobody → Leo Arias (elopio)
Revision history for this message
Olivier Tilloy (osomon) wrote :

Leo, how is flake8 invoked to check for errors/warnings? I’m asking because webbrowser-app has a unit test that runs flake8 on its autopilot tests, so any error/warning should prevent it from landing. See http://bazaar.launchpad.net/~phablet-team/webbrowser-app/trunk/view/head:/tests/unittests/sanity/CMakeLists.txt.

Revision history for this message
Leo Arias (elopio) wrote :

Hey osomon.

The problem on that script is that it's using the py2 version of flake8. You need to run it like this:

python3 -m flake8 <dir>

I'll add that to my branch. Please check it, because I'm not sure if on cmake I should be calling python3 directly; I have seen some fancier things in some other projects.

Leo Arias (elopio)
Changed in qakit:
assignee: nobody → Federico Gimenez (fgimenez)
Changed in address-book-app (Ubuntu):
assignee: nobody → Federico Gimenez (fgimenez)
status: New → In Progress
Leo Arias (elopio)
Changed in camera-app:
assignee: nobody → Leo Arias (elopio)
status: New → In Progress
Leo Arias (elopio)
Changed in ubuntu-keyboard:
status: New → In Progress
assignee: nobody → Leo Arias (elopio)
Michał Sawicz (saviq)
Changed in unity8 (Ubuntu):
assignee: Michał Sawicz (saviq) → Unity Team (unity-team)
assignee: Unity Team (unity-team) → Unity UI Team (unity-ui-team)
Olivier Tilloy (osomon)
Changed in webbrowser-app (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package unity8 - 8.02+15.04.20150511-0ubuntu1

---------------
unity8 (8.02+15.04.20150511-0ubuntu1) vivid; urgency=medium

  [ Albert Astals Cid ]
  * Workarounds for concierge mode.

  [ CI Train Bot ]
  * New rebuild forced.
  * Resync trunk.

unity8 (8.02+15.04.20150505-0ubuntu1) vivid; urgency=medium

  [ Albert Astals Cid ]
  * Make runtests fake a test error if make fails
  * Make the test more stable
  * Use dbus-test-runner instead of dbus-launch

  [ Daniel d'Andrada ]
  * DirectionalDragArea: improvements & API grooming (LP: #1417920)
  * Fix EdgeDragEvaluator when a drag can happen both ways
    (Direction.Horizontal)

  [ Josh Arenson ]
  * Remove panelHeight property as it is unused.

  [ Leo Arias ]
  * Initial clean up of the autopilot tests set up. Removed the touch
    device from the test case. Moved the restart of unity to a fixture.
    Removed the unused DragMixin. Updated the setUpClass to use
    process_helpers. Removed the workaround for bug #1238417, already
    fixed. Use the toolkit helper to set the testability environment
    variable. Fixed the indicators base class that was restarting unity
    twice. (LP: #1238417, #1447206)
  * Use the base class from the toolkit in autopilot tests.

  [ Michael Zanetti ]
  * emit application-stop when we're going down (LP: #1326513)

  [ Michał Sawicz ]
  * UNITY_SCOPES_LIST is no more

  [ handsome_feng<email address hidden> ]
  * When click the favorite scope in Dash Manager , it just return to
    the corresponding scope page. (LP: #1447056)

unity8 (8.02+15.04.20150422-0ubuntu1) vivid; urgency=medium

  [ Albert Astals Cid ]
  * Compile with Qt 5.5 (LP: #1437238)
  * Different way of top aligning labels when the other one in the row
    is multiline (LP: #1442085)
  * make pot_file

  [ Andrea Cimitan ]
  * Set sourceSize for DashBackground.qml Image

  [ CI Train Bot ]
  * New rebuild forced.
  * Resync trunk. added: po/sk.po

  [ Daniel d'Andrada ]
  * Move handling of command line options to a separate class
  * Refactor tst_PhysicalKeysMapper.qml

  [ Leo Arias ]
  * For autopilot tests, use the device simulation scenarios from the
    toolkit.

  [ Leonardo Arias Fonseca ]
  * For autopilot tests, use the device simulation scenarios from the
    toolkit.

  [ Michael Zanetti ]
  * Make sure dnd mode is ended properly when drag gesture is cancelled
    (LP: #1444949)

  [ Michał Sawicz ]
  * Fix flake8 warnings (LP: #1444170)
  * Move mock indicator service to unity8-fake-env, as it's a binary-
    dependent package.

  [ Nick Dedekind ]
  * Use asynchronous dbus requests for property updates. (LP: #1436982)

 -- CI Train Bot <email address hidden> Mon, 11 May 2015 08:29:58 +0000

Changed in unity8 (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package address-book-app - 0.2+15.10.20150528-0ubuntu1

---------------
address-book-app (0.2+15.10.20150528-0ubuntu1) wily; urgency=medium

  [ CI Train Bot ]
  * Resync trunk. added: po/ia.po

  [ Sebastien Bacher ]
  * Specify the gettext domain to use, the contact widgets are imported
    by other components (like the dialer) and trying to load the
    translations from the current domain is not working then. (LP:
    #1447516)

 -- CI Train Bot <email address hidden> Thu, 28 May 2015 13:18:13 +0000

Changed in address-book-app (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package camera-app - 3.0.0+15.10.20150707-0ubuntu1

---------------
camera-app (3.0.0+15.10.20150707-0ubuntu1) wily; urgency=medium

  [ Brendan Donegan ]
  * Use pointing_device from self.app instead of the testCase passed in

  [ CI Train Bot ]
  * New rebuild forced.

  [ Florian Boucault ]
  * Remove hardcoded actions in GalleryViewHeader to make it extensible.
  * Set desktop file flags informing Unity that the camera app is doing
    its own content rotation when the device rotates. Manually
    rotate/position depending on device orientation: photo roll bottom
    edge indicators and content first photo roll hint snapshot animation
    countdown timer (LP: #1467461, #1466409, #1467658, #1467661,
    #1447694, #1468269, #1367792, #1468284)

  [ Leo Arias ]
  * Fixed the static errors reported by flake8. Added the check to the
    debian build tests. Added python3-flake8 as a build dependency. (LP:
    #1444170)
  * Use pointing_device from self.app instead of the testCase passed in

  [ Olivier Tilloy ]
  * Updated application icon. removed: camera-app.svg added: camera-
    app.png

camera-app (3.0.0+15.04.20150514-0ubuntu1) vivid; urgency=medium

  [ CI Train Bot ]
  * Resync trunk.

  [ Leo Arias ]
  * Use the base class from the toolkit in autopilot tests.

  [ Omer Akram ]
  * Autopilot: Ensure the media directories exist before trying to
    delete data from them. (LP: #1444650)

 -- CI Train Bot <email address hidden> Tue, 07 Jul 2015 11:09:20 +0000

Changed in camera-app (Ubuntu):
status: New → Fix Released
Changed in ubuntu-keyboard:
status: In Progress → Fix Released
Changed in camera-app:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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