engine/process.py
def polygon_manual(self, message):
        """Control the message length. In the case of the successful
           text input validation, call the append_poly_points method.
           Return the proper answer"""
        if len(message.text) > 25:
            return answers['LONG']
        else:
            try:
                lat, long = message.text.lower().split(',')
                lat, long = float(lat), float(long)
                if -90 <= lat <= 90 and -180 <= long <= 180:
                    self.append_poly_points(message, lat, long)
                    return answers['VERTEX_DONE']
                elif not -90 <= lat <= 90 and not -180 <= long <= 180:
                    return answers['INVALID_COORD']
                elif not -90 <= lat <= 90:
                    return answers['INVALID_LAT']
                else:
                    return answers['INVALID_LONG']
            except ValueError:
                return answers['FOLLOW_TEMPLATE']
Control the message length. In the case of the successful
           text input validation, call the append_poly_points method.
           Return the proper answer
Control the message length. In the case of the successful
text input validation, call the append_poly_points method.
Return the proper answer
Control the message length . In the case of the successful text input validation call the append_poly_points method . Return the proper answer
def polygon_manual(self, message):
        if len(message.text) > 25:
            return answers['LONG']
        else:
            try:
                lat, long = message.text.lower().split(',')
                lat, long = float(lat), float(long)
                if -90 <= lat <= 90 and -180 <= long <= 180:
                    self.append_poly_points(message, lat, long)
                    return answers['VERTEX_DONE']
                elif not -90 <= lat <= 90 and not -180 <= long <= 180:
                    return answers['INVALID_COORD']
                elif not -90 <= lat <= 90:
                    return answers['INVALID_LAT']
                else:
                    return answers['INVALID_LONG']
            except ValueError:
                return answers['FOLLOW_TEMPLATE']
def polygon_manual ( self , message ) : if len ( message . text ) > 25 : return answers [ 'LONG' ] else : try : lat , long = message . text . lower ( ) . split ( ',' ) lat , long = float ( lat ) , float ( long ) if - 90 <= lat <= 90 and - 180 <= long <= 180 : self . append_poly_points ( message , lat , long ) return answers [ 'VERTEX_DONE' ] elif not - 90 <= lat <= 90 and not - 180 <= long <= 180 : return answers [ 'INVALID_COORD' ] elif not - 90 <= lat <= 90 : return answers [ 'INVALID_LAT' ] else : return answers [ 'INVALID_LONG' ] except ValueError : return answers [ 'FOLLOW_TEMPLATE' ]
Control the message length.
Control the message length .
"""Control the message length. In the case of the successful
           text input validation, call the append_poly_points method.
           Return the proper answer"""
self
message