This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author steven.daprano
Recipients jen.soft.master, steven.daprano
Date 2021-01-18.10:05:45
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1610964345.15.0.721053367834.issue42954@roundup.psfhosted.org>
In-reply-to
Content
Use the walrus operator:

    if profile := users.get(uid, None) is not None:
        print(f"user: {profile['name']}")
History
Date User Action Args
2021-01-18 10:05:45steven.dapranosetrecipients: + steven.daprano, jen.soft.master
2021-01-18 10:05:45steven.dapranosetmessageid: <1610964345.15.0.721053367834.issue42954@roundup.psfhosted.org>
2021-01-18 10:05:45steven.dapranolinkissue42954 messages
2021-01-18 10:05:45steven.dapranocreate