File indexing completed on 2024-04-28 08:32:03
0001 #!/usr/bin/env python3 0002 # SPDX-FileCopyrightText: 2020 David Faure <faure@kde.org> 0003 # SPDX-License-Identifier: LGPL-2.0-or-later 0004 0005 from PyKOpeningHours import PyKOpeningHours 0006 0007 parser = PyKOpeningHours.OpeningHours() 0008 parser.setExpression('Friday 11:00 am - 11:00 pm') 0009 if parser.error() != PyKOpeningHours.Error.NoError: 0010 print("ERROR parsing expression:" + str(parser.error())) 0011 else: 0012 print(parser.normalizedExpression())