<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def create_floatingip(self, floating_network, port=None):
        '''
        Creates a new floatingip
        '''
        net_id = self._find_network_id(floating_network)
        body = {'floating_network_id': net_id}
        if port:
            port_id = self._find_port_id(port)
            body['port_id'] = port_id

        return self.network_conn.create_floatingip(body={'floatingip': body})