"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "keystone/models/receipt_model.py" between
keystone-16.0.1.tar.gz and keystone-17.0.0.tar.gz

About: OpenStack Keystone (Core Service: Identity) provides an authentication and authorization service for other OpenStack services. Provides a catalog of endpoints for all OpenStack services.
The "Ussuri" series (latest release).

receipt_model.py  (keystone-16.0.1):receipt_model.py  (keystone-17.0.0)
skipping to change at line 18 skipping to change at line 18
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations # License for the specific language governing permissions and limitations
# under the License. # under the License.
"""Unified in-memory receipt model.""" """Unified in-memory receipt model."""
from oslo_log import log from oslo_log import log
from oslo_serialization import msgpackutils from oslo_serialization import msgpackutils
from oslo_utils import reflection from oslo_utils import reflection
import six
from keystone.auth import core from keystone.auth import core
from keystone.common import cache from keystone.common import cache
from keystone.common import provider_api from keystone.common import provider_api
from keystone import exception from keystone import exception
from keystone.identity.backends import resource_options as ro from keystone.identity.backends import resource_options as ro
LOG = log.getLogger(__name__) LOG = log.getLogger(__name__)
PROVIDERS = provider_api.ProviderAPIs PROVIDERS = provider_api.ProviderAPIs
skipping to change at line 59 skipping to change at line 58
desc = ('<%(type)s at %(loc)s>') desc = ('<%(type)s at %(loc)s>')
self_cls_name = reflection.get_class_name(self, fully_qualified=False) self_cls_name = reflection.get_class_name(self, fully_qualified=False)
return desc % {'type': self_cls_name, 'loc': hex(id(self))} return desc % {'type': self_cls_name, 'loc': hex(id(self))}
@property @property
def expires_at(self): def expires_at(self):
return self.__expires_at return self.__expires_at
@expires_at.setter @expires_at.setter
def expires_at(self, value): def expires_at(self, value):
if not isinstance(value, six.string_types): if not isinstance(value, str):
raise ValueError('expires_at must be a string.') raise ValueError('expires_at must be a string.')
self.__expires_at = value self.__expires_at = value
@property @property
def issued_at(self): def issued_at(self):
return self.__issued_at return self.__issued_at
@issued_at.setter @issued_at.setter
def issued_at(self, value): def issued_at(self, value):
if not isinstance(value, six.string_types): if not isinstance(value, str):
raise ValueError('issued_at must be a string.') raise ValueError('issued_at must be a string.')
self.__issued_at = value self.__issued_at = value
@property @property
def user(self): def user(self):
if not self.__user: if not self.__user:
if self.user_id: if self.user_id:
self.__user = PROVIDERS.identity_api.get_user(self.user_id) self.__user = PROVIDERS.identity_api.get_user(self.user_id)
return self.__user return self.__user
 End of changes. 3 change blocks. 
3 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)