[Sugar-devel] [PATCH sugar 13/21] pylint cleanup: mark some variables as unused
Sascha Silbe
sascha-pgp at silbe.org
Sat Oct 16 18:20:15 EDT 2010
Follow the convention of marking known-unused (but required for
de-marshalling purposes) variables by postfixing them with an underscore.
Signed-off-by: Sascha Silbe <sascha-pgp at silbe.org>
diff --git a/src/jarabe/desktop/favoriteslayout.py b/src/jarabe/desktop/favoriteslayout.py
index 8f15861..a0323bb 100644
--- a/src/jarabe/desktop/favoriteslayout.py
+++ b/src/jarabe/desktop/favoriteslayout.py
@@ -257,13 +257,13 @@ class RingLayout(FavoritesLayout):
self._spiral_mode = True
icon_size = style.STANDARD_ICON_SIZE
- angle, radius = self._calculate_angle_and_radius(children_count,
- icon_size)
+ angle_, radius = self._calculate_angle_and_radius(children_count,
+ icon_size)
while radius > _MAXIMUM_RADIUS:
i = _ICON_SIZES.index(icon_size)
if i < len(_ICON_SIZES) - 1:
icon_size = _ICON_SIZES[i + 1]
- angle, radius = self._calculate_angle_and_radius(
+ angle_, radius = self._calculate_angle_and_radius(
children_count, icon_size)
else:
break
@@ -304,7 +304,7 @@ class RingLayout(FavoritesLayout):
_ICON_SPACING_FACTORS[_ICON_SIZES.index(icon_size)]
angle = _INITIAL_ANGLE
radius = _MINIMUM_RADIUS - (icon_size * _MIMIMUM_RADIUS_ENCROACHMENT)
- for i in range(icon_count):
+ for i_ in range(icon_count):
circumference = radius * 2 * math.pi
n = circumference / icon_spacing
angle += (2 * math.pi / n)
diff --git a/src/jarabe/desktop/schoolserver.py b/src/jarabe/desktop/schoolserver.py
index 5388466..1a10b16 100644
--- a/src/jarabe/desktop/schoolserver.py
+++ b/src/jarabe/desktop/schoolserver.py
@@ -96,8 +96,8 @@ class TimeoutHTTP(httplib.HTTP):
class TimeoutTransport(xmlrpclib.Transport):
def make_connection(self, host):
- host, extra_headers, x509 = self.get_host_info(host)
- return TimeoutHTTP(host, timeout=REGISTER_TIMEOUT)
+ host, extra_headers, x509_ = self.get_host_info(host)
+ return _TimeoutHTTP(host, timeout=REGISTER_TIMEOUT)
def register_laptop(url=REGISTER_URL):
--
1.7.1
More information about the Sugar-devel
mailing list