We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
2016-11-16T13:57:46.813518+00:00 app[web.1]: app_id = self.request.swagger_data['appid'] 2016-11-16T13:57:46.813524+00:00 app[web.1]: AttributeError: 'Request' object has no attribute 'swagger_data'
Does anyone know what's going on?
This works
@view_config(route_name='configurationkeys_for_app', request_method="GET") def configurationkeys_GET(self): """ List all configurationkeys with GET method """ app_id = self.request.swagger_data['id'] if Application.get(app_id) is None: print_log(datetime.datetime.now(), 'GET', '/applications/%s/configurationkeys'\ % app_id, 'Get configurationkeys', 'Failed') return self.createResponse(None, 400) app_conf_keys = ConfigurationKey.query().join(Application).filter(Application.id == app_id) return list(map(lambda _: _.as_dict(), app_conf_keys))
And this doesn't
@view_config(route_name='configurationkey', request_method="GET") def configurationkeys_GET_one(self): """ Find and return one configurationkey by id with GET method """ app_id = self.request.swagger_data['appid'] confkey_id = self.request.swagger_data['ckid'] confkey = get_conf_key_by_appid_and_ckid(app_id, confkey_id) if confkey is None: print_log(datetime.datetime.now(), 'GET',\ '/applications/%s/configurationkeys/' % app_id + str(confkey_id), 'Get one configurationkey', 'Failed') return self.createResponse(None, 400) return confkey.as_dict()
Added routes are:
config.add_route('configurationkeys_for_app', '/applications/{id}/configurationkeys') config.add_route('configurationkey', '/applications/{appid}/configurationkeys/{ckid}')
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Does anyone know what's going on?
This works
And this doesn't
Added routes are:
The text was updated successfully, but these errors were encountered: