fossasia / open-event-server

Formatted string passed to logging module PYL-W1203
Performance
Minor
2 occurrences in this check
Use lazy % formatting in logging functions
657    except Exception:
658        logging.exception('Error while charging omise')
659    if charge.failure_code is not None:
660        logging.warning(661            f"Omise Failure Message: {charge.failure_message} ({charge.failure_code})"
662        )
663        return jsonify(
Use lazy % formatting in logging functions
294def resize_speaker_images_task(self, speaker_id, photo_url):
295    speaker = Speaker.query.get(speaker_id)
296    try:
297        logging.info(298            f'Speaker image resizing tasks started for speaker with id {speaker_id}'
299        )
300        uploaded_images = create_save_image_sizes(photo_url, 'speaker-image', speaker_id)