python

Back Open Paginator
15.10.2025 09:17
GripNews (@GripNews@mastodon.social)

🌘 TIL:Python 的 splitlines() 功能遠不止換行符
➤ 解鎖 Python 字串處理的隱藏功能:splitlines() 的廣泛應用
yossarian.net/til/post/python-
這篇文章介紹了 Python 字串方法 `splitlines()` 的實際功能,作者原本以為它只處理常見的換行符號,但經過查閱文件後發現,`splitlines()` 實際上支援多達十種不同的行分隔符號,包括一般的換行符、水平定位符、換頁符,甚至 Unicode 中的行分隔符和段落分隔符。這使得 `splitlines()` 的應用範圍比預期更廣泛,能夠處理更多樣化的文本格式。文章最後提醒讀者,Unicode 並不只代表可列印字元,許多控制碼在不同的系統中仍有其特定的語義。
+ 原來 `splitlines()` 這麼強大!我一直都只拿來處理基本的換行,以後要多注意其他分隔符號了。
+ 這篇文章很有啟發性。Uni




Show Original Post


15.10.2025 08:40
jeeger (@jeeger@mastodon.social)

Tryhard pytest...

github.com/pytest-dev/pytest/b




Show Original Post


15.10.2025 08:22
habr (@habr@zhub.link)

Как перестать бояться и полюбить собеседования. От синдрома самозванца до офферов

Как вы чувствуете себя на собеседованиях? Ужасно? Мне тоже было ужасно. А если что‑то сложно, что нужно делать? Правильно - поставить себе челлендж. Итак, мой год собеседований: 112 интервью на позицию Python Developer (от middle до senior) в 51 компанию, 10 офферов и увеличение дохода почти в 2 раза. Это было тяжело: пришлось бороться со страхом провала, синдромом самозванца и рынком труда. Зато теперь я, кажется, умею получать офферы senior‑уровня. В этой статье хочется подвести итоги и отрефлексировать этот путь, а также привести статистику с графиками, цифрами (и офферами!). Возможно, кто‑то научится на моих ошибках, и пройдёт этот путь гораздо быстрее.

habr.com/ru/articles/956638/

#собеседование #python #карьера #синдром_самозванца #оффер #интервью #middle #senior #developer #тренировка




Show Original Post


15.10.2025 08:01
treyhunner (@treyhunner@mastodon.social)

So when writing a file using Python's csv module, you're expected to always specify newline="" when opening the file you're writing to, to make sure that you don't accidentally double up your carriage returns on Windows.

Read more 👉 trey.io/ca0qyn





Show Original Post


15.10.2025 07:57
r (@r@fed.brid.gy)

It's over. uv had more PyPI downloads than Poetry last month, surpassing every other workflow or packaging tool for Python. And that doesn't include GitHub or Crates downloads. In just 1.5 years, uv has solved the Python packaging DX of consumers. #python





Show Original Post


15.10.2025 07:57
r (@r@bsky.brid.gy)

It's over. uv had more PyPI downloads than Poetry last month, surpassing every other workflow or packaging tool for Python. And that doesn't include GitHub or Crates downloads. In just 1.5 years, uv has solved the Python packaging DX of consumers. #python





Show Original Post


15.10.2025 07:06
treyhunner (@treyhunner@mastodon.social)

uv supports an exclude-newer feature as a sort of "pin to versions available as of a specific date" feature!

I'm wondering whether I should add support for that OR simply enable it by default. 🤔

If you have thoughts, I'd love to hear them: github.com/treyhunner/uvrs/iss




Show Original Post


15.10.2025 06:45
CuratedHackerNews (@CuratedHackerNews@mastodon.social)

Python's splitlines does more than just newlines

yossarian.net/til/post/python-




Show Original Post


15.10.2025 06:39
teguhteja (@teguhteja@mastodon.social)

Unlock the power of Odoo API Returns in Odoo 18! Learn to build robust integrations & improve code quality. A must-read for Odoo devs!

teguhteja.id/odoo-18-api-retur




Show Original Post


15.10.2025 06:21
philip (@philip@mastodon.mallegolhansen.com)

I just finished working my way through @kentbeck’s TDD book.

The exercise of writing a test framework to run the tests driving the development of my test framework in Python was truly a joy to work through.

Code here in case anyone is curious: github.com/Hanse00/TDD/blob/ma

#TDD #Programming #Python




Show Original Post


15.10.2025 05:27
qlp (@qlp@linh.social)

The day that I deploy Python 3.13.8 to my personal production servers, Python 3.13.9 is released.

Yay! 😜

#Python




Show Original Post


15.10.2025 05:00
botticelli (@botticelli@mastodon.social)

🤖: SjoSjo 🐘️ ☑️ 🇺🇦 🇵🇸
@sjosjo
Joined: Nov 07, 2022
Bio: FOSS only! No more Windows or MicrosoftCloud for me, that ship has sailed#ProductivityCloud are my own, both Private and Commercial.I explicitly forbid the use of my toots for profiling me, train AI models with or for any other purpose without my explicit consent. ...





Show Original Post


1 ...1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 ...1560
UP