get all matches (once the tournament is started)

        |methcoro|

        Args:
            force_update (default=False): True to force an update to the Challonge API

        Returns:
            list[Match]:

        Raises:
            APIException
504041
async def get_matches(self, force_update=False) -> list:
        
        if force_update or self.matches is None:
            res = await self.connection('GET',
                                        'tournaments/{}/matches'.format(self._id),
                                        include_attachments=1)
            self._refresh_matches_from_json(res)
        return self.matches or []
338811
def get_match_history(start_at_match_id=None, player_name=None, hero_id=None,
                      skill=0, date_min=None, date_max=None, account_id=None,
                      league_id=None, matches_requested=None, game_mode=None,
                      min_players=None, tournament_games_only=None,
                      **kwargs):
    

    params = {
        "start_at_match_id": start_at_match_id,
        "player_name": player_name,
        "hero_id": hero_id,
        "skill": skill,
        "date_min": date_min,
        "date_max": date_max,
        "account_id": account_id,
        "league_id": league_id,
        "matches_requested": matches_requested,
        "game_mode": game_mode,
        "min_players": min_players,
        "tournament_games_only": tournament_games_only
    }

    return make_request("GetMatchHistory", params, **kwargs)
1250092
def refresh(self, force_cache=False):
        
        if self.check_if_ok_to_update() or force_cache:
            for sync_name, sync_module in self.sync.items():
                _LOGGER.debug("Attempting refresh of sync %s", sync_name)
                sync_module.refresh(force_cache=force_cache)
            if not force_cache:
                # Prevents rapid clearing of motion detect property
                self.last_refresh = int(time.time())
            return True
        return False
421874
async def parse_update(self, bot):
        
        data = await self.request.json()
        update = types.Update(**data)
        return update
952959
def force_update(self):
        
        if self.disabled or self.terminated or not self.enabled:
            return
        # clear cached_until for each method to allow update
        for meth in self.methods:
            self.methods[meth]["cached_until"] = time()
            if self.config["debug"]:
                self._py3_wrapper.log("clearing cache for method {}".format(meth))
        # set module to update
        self._py3_wrapper.timeout_queue_add(self)
995869
def matches(self, event):
        '''
        
        '''
        ret = []
        self._matches(event, set(), ret)
        return tuple(r[0] for r in ret)
547429
async def update(self, **kwargs):
        '''
        
        '''
        try:
            self.data[self.pk] = self.pk_type(kwargs['pk'])
            updated_obj = await self._meta.object_class().update(self.db, data=self.data)
            if updated_obj is None:
                raise NotFound('Object matching the given {} was not found'.format(self.pk))
            return await updated_obj.serialize()
        except Exception as ex:
            logger.exception(ex)
            raise BadRequest(ex)
733642
public function listing($forceUpdate = false)
    {
        if (empty($this->groups) || $forceUpdate) {
            $this->all();
        }
        $ret = [];
        foreach ($this->groups['groups'] as $e) {
            $ret[$e['name']] = (int) $e['id'];
        }

        return $ret;
    }
568785
def update(self):
        
        if not self._remap:
            return

        with self._remap_lock:
            if not self._remap:
                return

            self._rules.sort(key=lambda x: x.match_compare_key())
            for rules in itervalues(self._rules_by_endpoint):
                rules.sort(key=lambda x: x.build_compare_key())
            self._remap = False
383495
def get_state(self, force_update=False):
        
        if force_update or self._state is None:
            return int(self.basicevent.GetBinaryState()['BinaryState'])
        return self._state
1336054
def get_for_update(self, connection_name='DEFAULT', **kwargs):

        
        if not kwargs:
            raise InvalidQueryError(
                "Can not execute a query without parameters")

        obj = self.pool.connections[connection_name].session.query(
            self._model).with_for_update(
                nowait=True, of=self._model).filter_by(**kwargs).first()
        if not obj:
            raise NotFoundError('Object not found')
        return obj
1227011
def getbugfields(self, force_refresh=False):
        
        if force_refresh or not self._cache.bugfields:
            log.debug("Refreshing bugfields")
            self._cache.bugfields = self._getbugfields()
            self._cache.bugfields.sort()
            log.debug("bugfields = %s", self._cache.bugfields)

        return self._cache.bugfields
661783
def get_order_matchresults(self, order_id, _async=False):
        
        params = {}
        path = f'/v1/order/orders/{order_id}/matchresults'
        return api_key_get(params, path, _async=_async)
145260
def get_events(self, **kwargs):
        """"""
        force = kwargs.pop('force', False)
        response = api.request_sync_events(self.blink,
                                           self.network_id,
                                           force=force)
        try:
            return response['event']
        except (TypeError, KeyError):
            _LOGGER.error("Could not extract events: %s",
                          response,
                          exc_info=True)
            return False
717216
def _from_rest_reject_update(model):
    

    dirty = model.dirty_fields
    fields = model.get_fields_by_prop('reject_update', True)
    reject = []

    for field in fields:
        if field in dirty:
            reject.append(field)

    if reject:
        mod_fail('These fields cannot be updated: %s' % ', '.join(reject))
278637
def update_many(cls, filter, update, upsert=False):
        
        return cls.collection.update_many(filter, update, upsert).raw_result
500631
function getUpdates() {
		return _client.method('WaitForUpdatesEx', {
			_this: _client._updatesCollector,
			version: _client._updatesVersion,
			options: {
				maxWaitSeconds: 0
			}
		})
		.then(function(set) {
			if (set) {

				// update the version
				_client._updatesVersion = set.version;
				
				// get only the updates
				var updates   = [];
				var filterSet = _.get(set, 'filterSet');
				filterSet     = Array.isArray(filterSet) ? filterSet : [filterSet];
				
				// loop through the filter sets
				_.forEach(filterSet, function(f) {
					
					var objectSet = _.get(f, 'objectSet');
					objectSet     = Array.isArray(objectSet) ? objectSet : [objectSet];
					
					// format the objects
					_.forEach(objectSet, function(u) {
						u.obj = {
							type: _.get(u, 'obj.attributes.type'),
							id: _.get(u, 'obj.$value')
						};
						
						// make the change set an array
						u.changeSet = Array.isArray(u.changeSet) ? u.changeSet : [u.changeSet];
						
						// update change set
						_.forEach(u.changeSet, function(c) {
							c.val = _.get(c, 'val.$value');
						});
						
						// push the update
						updates.push(u);
					});
				});

				// emit the results
				_client.emit('updates', updates);
			}
		});
	}