Editing the user profile page with additional fields

If you’re just looking to populate the default country field in a registration form, you could intercept the get_user_data function. Something like this should work:

class YourPlugin(IndicoPlugin):
    def __init__(self):
        # Your init code here

        self.connect(signals.plugin.interceptable_function, self._get_user_data, sender=interceptable_sender(get_user_data))

    def _get_user_data(self, sender, func, args, **kwargs):
        user_data = func(*args.args, **args.kwargs)
        # Populate the country field with the user's data
        user_data['country'] = ...
        return user_data