This is a autopost bolg frinds we are trying to all latest sports,news,all new update provide for you
Friday, October 6, 2023
Show HN: Use Python docstrings as exception messages https://ift.tt/a2ktRz6
Show HN: Use Python docstrings as exception messages The following exception @dataclass class PodBayDoorsStillClosed(DocumentedError): """ I’m sorry, {self.user_name}. I’m afraid I can’t do that. """ user_name: str when raised as raise PodBayDoorsStillClosed('Dave') will print PodBayDoorsStillClosed: I’m sorry, Dave. I’m afraid I can’t do that. Reduce the boilerplate, use more exception classes to better express the business logic, or invent your own use cases :) Can be tried out as: pip install documented which works for Python ⩾ 3.8.1. https://ift.tt/QWAid4f October 6, 2023 at 11:39PM
Subscribe to:
Post Comments (Atom)
Show HN: WebGPU enables local LLM in the browser – demo site with AI chat https://ift.tt/3P1DTwH
Show HN: WebGPU enables local LLM in the browser – demo site with AI chat Browser LLM demo working on JavaScript and WebGPU. WebGPU is alrea...
-
Show HN: Locksmith – detect locks taken by Postgres migrations https://ift.tt/0cBueJt February 10, 2025 at 02:26AM
-
Show HN: I built a FOSS tool to run your Steam games in the Cloud I wanted to play my Steam games but my aging PC couldn’t keep up, so I bui...
-
Show HN: A directory of 800 free APIs, no auth required Explore reliable free APIs for developers — ideal for web and software development, ...
No comments:
Post a Comment