Pybites (@pybites) 's Twitter Profile
Pybites

@pybites

Helping people worldwide to improve their #Python + #developer + #mindset skills.
Created by @bbelderbos & @juliansequeira.
Join us: pybit.es/community/

ID: 812103603116613632

linkhttps://pybitesplatform.com calendar_today23-12-2016 01:12:41

11,11K Tweet

30,30K Followers

242 Following

Charlie Marsh (@charliermarsh) 's Twitter Profile Photo

The ty diagnostics are getting so good. If you reference a symbol or module that was defined in a more recent Python version, we tell you that, and also tell you where/why we inferred the supported Python version.

The ty diagnostics are getting so good.

If you reference a symbol or module that was defined in a more recent Python version, we tell you that, and also tell you where/why we inferred the supported Python version.
Bob Belderbos (@bbelderbos) 's Twitter Profile Photo

The other day I wanted to group countries by continent. I used: βœ… Use pycountry-convert for mapping. βœ… Use defaultdict(list) to skip key checks. βœ… pprint or pp() for a clean output. (By the way, what is new in my imports? πŸπŸ’‘)

The other day I wanted to group countries by continent. 

I used:

βœ… Use pycountry-convert for mapping.

βœ… Use defaultdict(list) to skip key checks.

βœ… pprint or pp() for a clean output. 

(By the way, what is new in my imports? πŸπŸ’‘)
Bob Belderbos (@bbelderbos) 's Twitter Profile Photo

πŸš€ Want faster & leaner #Python objects? Use __slots__: ``` class Point: __slots__ = ('x', 'y') ``` βœ… Saves memory (no __dict__) βœ… Prevents new attrs (p.z = 3 β†’ πŸ’₯) Great for tight loops & cleaner models.

πŸš€ Want faster & leaner #Python objects?

Use __slots__:

```
class Point:
    __slots__ = ('x', 'y')
```

βœ… Saves memory (no __dict__)
βœ… Prevents new attrs (p.z = 3 β†’ πŸ’₯)

Great for tight loops & cleaner models.
Bob Belderbos (@bbelderbos) 's Twitter Profile Photo

Like Unix piping, you can build function pipelines in #Python by overriding theΒ `__or__`Β method. This lets you chain operations where each function’s output feeds into the next -> clean, readable, and composable. Simple example below πŸ‘‡

Like Unix piping, you can build function pipelines in #Python by overriding theΒ `__or__`Β method.

This lets you chain operations where each function’s output feeds into the next -> clean, readable, and composable.

Simple example below πŸ‘‡
Charlie Marsh (@charliermarsh) 's Twitter Profile Photo

LLMs are a tool just like anything else. You have to learn to use them, and you get better with time and practice. If you tried ChatGPT once, got a bad answer, and churned off the entire technology, it may have just been a skill issue (respectfully).

Bob Belderbos (@bbelderbos) 's Twitter Profile Photo

I just migrated one of my last projects to #uv so I thought it would be useful to share the steps here - see image below. πŸ’‘πŸ“ˆ Are you also usingΒ uv for all your #Python projects now? πŸ€”

I just migrated one of my last projects to #uv so I thought it would be useful to share the steps here - see image below. πŸ’‘πŸ“ˆ

Are you also usingΒ uv for all your #Python projects now? πŸ€”
Pybites (@pybites) 's Twitter Profile Photo

New video on our channel: Learn #Github Actions - Building an Automated Video Summary Pipeline youtu.be/pcPE0PFdUK0?si… via YouTube