home.social

#ruff — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #ruff, aggregated by home.social.

  1. New paper: #ClimateChange has made #storm #floods more common in Baltic Sea Finland & they are washing away #wader #nests. Land use planning can help, artificial eggs and incubation used only as a last resort. @[email protected] #HannaAlgora #ruff #dunlin #climateaction

    Rising storm floods are washin...

  2. #CodeQuality of the lazy developer 🛠️

    Updating an educational #Python repo, I looked into what to automate for code quality.

    🔮 Spoiler: I landed on uv, ruff, pyright and pre-commit.

    In the article: the picks, why, and the make patch that broke on the first try 😄

    alessandra.bilardi.net/diary/a

    #DiaryOfALazyDeveloper #pytest #ruff #pyright #uv

  3. Was waiting for CI, so gave this an update after being parked for years. I'd love to have this as a #ruff plugin...

    github.com/marcgibbons/flake8-

  4. Я хотел оживить голема, но получил галлюцинирующего идиота

    В игре Warcraft есть такая тварь — железный голем. Здоровенная кукла, слепленная из глины и металла, которую оживляют магическим словом. Тупой, но мощный исполнитель. Сказали бить — бьёт. Сказали охранять — стоит насмерть. Я захотел такого же, но в коде. Телом пусть будет Telegram-бот. А мозгом — нейросеть. Не просто очередной «чат с ИИ», а настоящий кодинг-агент. Чтобы кидаешь ему проект, а он: «Тут у тебя SQL-инъекция, тут гонка данных, тут ты импорт забыл, и вообще у тебя в зависимостях дыра». Идея казалась простой: берём aiogram , прикручиваем DeepSeek, пишем промпт «ты senior-разработчик, разбери этот код» — и готово. Первая версия была готова за вечер. Я кинул Голему свой проект. Он задумался на пару секунд и выдал:

    habr.com/ru/articles/1027038/

    #telegrambot #анализ #python #go #ruff #golem #llmагент

  5. Я хотел оживить голема, но получил галлюцинирующего идиота В игре Warcraft есть такая тварь — железный голем. З...

    #telegrambot #анализ #python #go #ruff #golem #llm-агент

    Origin | Interest | Match
  6. Практики разработки на Python

    Привет, Хабр! Меня зовут Роман, я программист в команде «Гравитон» и моя задача в компании — разработка API/CLI интерфейсов и приложений на языке Python. Цель данной статьи в том, чтобы показать как через внедрение «типовых подходов» и вспомогательных библиотек/утилит очень сильно упрощается поддержка проекта в настоящем (при передаче другому человеку или разработке в команде) и в будущем (возобновили проект спустя время). Первое, что нужно сказать — проект на Python это не только сам Python , но и множество технологий используемых вместе (Git, Docker, и т.д.). В этой статье мы сконцентрируемся на самом проекте, а именно с чего начать, что прикрутить, что учитывать при разработке.

    habr.com/ru/companies/graviton

    #бэкенд #Python #uv #ruff #mypy #практики

  7. Things hard to differentiate, as it seems:

    A software getting a new onwer does not make the software insecure, non-free, or otherwise bad.

    A tool getting a new database field does not make the tool a surveillance tool.

    ---

    A new owner changing the license of a software makes the software non-free.

    A system operator abusing a database field for surveilannce makes them a supporter of surveillance.

    #systemd #ruff

  8. RE: fedi.simonwillison.net/@simon/

    I like what Simon is writing in his blog about this. In particular about the forkability of the tools. Backed up by quoting Armin Ronacher:

    - "even in the worst possible future this is a very forkable and maintainable thing"

  9. I don't trust anything that say or promise. Now they're buying openai.com/index/openai-to-acq - and gains control over , and .

    That the "Astral team will join the Codex team at OpenAI and over time, we’ll explore deeper integrations" - makes me wonder how well these really great tools will keep functioning stand alone in the future.

    Can I keep being depended on them for managing my :python: projects?

    AI companies are gaining al the more control of the toolchain!

  10. I use #ruff as my #Python linter for the speed #flake8 lacked (with a foot still in the other camp for custom rules), was looking at #ty, but hadn’t had any incentive to try #uv.

    Others in the #Python ecosystem might be getting rather more nervous… Looks like the venture capitalists backing #Astral will get their payoff: openai.com/index/openai-to-acq 💰

  11. Well, fuck. Will my favorite Python development tooling smell like pipi now? 🫣

    astral.sh/blog/openai

    #python #uv #ty #ruff

  12. OMG openai.com/index/openai-to-acq

    #openai is acquiring Astral, the author's of #uv, #ruff and #ty

    Well, I'll probably now defer adopting more of the astral tech stack. Or at least until openAI fixes their insane cash burn rate

  13. When installing dependencies, formatting code, linting it, type-checking it, and building docs with or , , , and would previously take from 2min to several more, it now takes less than 15 seconds for the whole thing, thanks to , , and .

    This is for 5 versions (3.10 to 3.15).

    The DX got much better 🥰

  14. When installing dependencies, formatting code, linting it, type-checking it, and building docs with #Poetry or #PDM, #Black, #Flake8, #Mypy and #MkDocs would previously take from 2min to several more, it now takes less than 15 seconds for the whole thing, thanks to #uv, #Ruff, #ty and #Zensical.

    This is for 5 #Python versions (3.10 to 3.15).

    The DX got much better 🥰

  15. When installing dependencies, formatting code, linting it, type-checking it, and building docs with #Poetry or #PDM, #Black, #Flake8, #Mypy and #MkDocs would previously take from 2min to several more, it now takes less than 15 seconds for the whole thing, thanks to #uv, #Ruff, #ty and #Zensical.

    This is for 5 #Python versions (3.10 to 3.15).

    The DX got much better 🥰

  16. When installing dependencies, formatting code, linting it, type-checking it, and building docs with #Poetry or #PDM, #Black, #Flake8, #Mypy and #MkDocs would previously take from 2min to several more, it now takes less than 15 seconds for the whole thing, thanks to #uv, #Ruff, #ty and #Zensical.

    This is for 5 #Python versions (3.10 to 3.15).

    The DX got much better 🥰

  17. @caten #Linux comes with #CPython - #Rust is not a requirement to use #python at all - Just Rust-programmed tools provide some candy for #python developpers, aka. #uv, #ruff...

  18. Статанализ — must-have для проектов с Codex/ClaudeCode

    На днях у Кирилла Мокевнина вышел пост про то, как он разлюбил динамическую типизацию. Мысль понятная: на больших кодовых базах отсутствие типов начинает дорого стоить. Хочу дополнить аргументом, который в 2026 году уже стал прям must-have: статанализ и типы — это лучший self-check для AI-агента . Современные агенты для разработки (Claude Code на Opus 4.5 и ChatGPT Codex 5.2 High) хорошо пишут код. Ошибок уровня «переменная не объявлена», «импорт забыл», «опечатка в имени метода» по сути уже почти нет. Основные промахи чаще про другое:

    habr.com/ru/articles/993004/

    #статистический_анализ #статический_анализ_кода #ruff #phpstan #phpcsfixer #php #python #go #codex #claude_code

  19. ty: революция в тайп-чекинге

    Всем привет! За последние пару лет компания Astral буквально разрывает Python-мир своими инструментами. Даже если вы не слышали это имя напрямую, с большой вероятностью вы уже пользовались их продуктами — ruff или uv . И это не преувеличение. И ruff , и uv сегодня фактически стали стандартом индустрии. Например, в свежем релизе PyCharm 2025.3 при создании нового проекта по умолчанию инициализируется именно окружение uv , а не привычный venv . Для open source-проекта — это очень серьёзный показатель доверия со стороны экосистемы. Открытый исходный код и массовое принятие инструментов Python-разработчиками дали Astral тот самый «кредит доверия», который компания, судя по всему, пока что уверенно оправдывает. И вот буквально на днях Astral объявили, что их новый «революционный» тайп-чекер ty переходит в стадию бета-тестирования. А если учитывать, что и uv , и ruff формально тоже всё ещё находятся в бете, то можно считать, что ty уже фактически вышел в релиз. Собственно, о нём и поговорим дальше. Если вам интересны подобные материалы — подписывайтесь на Telegram-канал «Код на салфетке» . Там я делюсь гайдами для новичков и полезными инструментами. А прямо сейчас у нас ещё и проходит новогодний розыгрыш.

    habr.com/ru/articles/979752/

    #uv #ruff #ty #mypy #type_checking #python #rust #astral

  20. Let's say you want to do good type-checking for the #Python project you're working on. You pick a tool, maybe you use it as an #LSP also (so your editor can show you errors, too). As an example, I'm using #Ty at the moment. There's three places this might be installed: globally (e.g., `brew install ty`), as a dev-only dependency inside your project (e.g., `uv add --dev ty`), or -- and this one might surprise you -- it might only be used and installed by `pre-commit`, which builds a separate environment for each needed tool (which is great for instance where I use `codespell` as a `pre-commit` check, which seems to need some higher version of Python than my actual project).

    Where should you install it?

    If you're the only one on your team running it, globally is fine. If more than just you, then absolutely as a dev-only dependency inside your project ... and **maybe** globally as well.

    The only real problem is updates. If you use a reasonable global install scheme, updates will be easy. They're less easy inside your project or in `pre-commit`. And you might care one way or the other! I **don't** want updates! I **do** want updates!

    As for Python type-checking, `ty` seems good so far, but not enough experience with it yet. `basedpyright`, `pyrefly`, and `ruff` all good. These four are my favorites.

    #BasedPyright #Pyrefly #Ruff #PreCommit #CodeSpell #Homebrew

  21. Let's say you want to do good type-checking for the #Python project you're working on. You pick a tool, maybe you use it as an #LSP also (so your editor can show you errors, too). As an example, I'm using #Ty at the moment. There's three places this might be installed: globally (e.g., `brew install ty`), as a dev-only dependency inside your project (e.g., `uv add --dev ty`), or -- and this one might surprise you -- it might only be used and installed by `pre-commit`, which builds a separate environment for each needed tool (which is great for instance where I use `codespell` as a `pre-commit` check, which seems to need some higher version of Python than my actual project).

    Where should you install it?

    If you're the only one on your team running it, globally is fine. If more than just you, then absolutely as a dev-only dependency inside your project ... and **maybe** globally as well.

    The only real problem is updates. If you use a reasonable global install scheme, updates will be easy. They're less easy inside your project or in `pre-commit`. And you might care one way or the other! I **don't** want updates! I **do** want updates!

    As for Python type-checking, `ty` seems good so far, but not enough experience with it yet. `basedpyright`, `pyrefly`, and `ruff` all good. These four are my favorites.

    #BasedPyright #Pyrefly #Ruff #PreCommit #CodeSpell #Homebrew

  22. Let's say you want to do good type-checking for the project you're working on. You pick a tool, maybe you use it as an also (so your editor can show you errors, too). As an example, I'm using at the moment. There's three places this might be installed: globally (e.g., `brew install ty`), as a dev-only dependency inside your project (e.g., `uv add --dev ty`), or -- and this one might surprise you -- it might only be used and installed by `pre-commit`, which builds a separate environment for each needed tool (which is great for instance where I use `codespell` as a `pre-commit` check, which seems to need some higher version of Python than my actual project).

    Where should you install it?

    If you're the only one on your team running it, globally is fine. If more than just you, then absolutely as a dev-only dependency inside your project ... and **maybe** globally as well.

    The only real problem is updates. If you use a reasonable global install scheme, updates will be easy. They're less easy inside your project or in `pre-commit`. And you might care one way or the other! I **don't** want updates! I **do** want updates!

    As for Python type-checking, `ty` seems good so far, but not enough experience with it yet. `basedpyright`, `pyrefly`, and `ruff` all good. These four are my favorites.

  23. Let's say you want to do good type-checking for the #Python project you're working on. You pick a tool, maybe you use it as an #LSP also (so your editor can show you errors, too). As an example, I'm using #Ty at the moment. There's three places this might be installed: globally (e.g., `brew install ty`), as a dev-only dependency inside your project (e.g., `uv add --dev ty`), or -- and this one might surprise you -- it might only be used and installed by `pre-commit`, which builds a separate environment for each needed tool (which is great for instance where I use `codespell` as a `pre-commit` check, which seems to need some higher version of Python than my actual project).

    Where should you install it?

    If you're the only one on your team running it, globally is fine. If more than just you, then absolutely as a dev-only dependency inside your project ... and **maybe** globally as well.

    The only real problem is updates. If you use a reasonable global install scheme, updates will be easy. They're less easy inside your project or in `pre-commit`. And you might care one way or the other! I **don't** want updates! I **do** want updates!

    As for Python type-checking, `ty` seems good so far, but not enough experience with it yet. `basedpyright`, `pyrefly`, and `ruff` all good. These four are my favorites.

    #BasedPyright #Pyrefly #Ruff #PreCommit #CodeSpell #Homebrew

  24. Let's say you want to do good type-checking for the #Python project you're working on. You pick a tool, maybe you use it as an #LSP also (so your editor can show you errors, too). As an example, I'm using #Ty at the moment. There's three places this might be installed: globally (e.g., `brew install ty`), as a dev-only dependency inside your project (e.g., `uv add --dev ty`), or -- and this one might surprise you -- it might only be used and installed by `pre-commit`, which builds a separate environment for each needed tool (which is great for instance where I use `codespell` as a `pre-commit` check, which seems to need some higher version of Python than my actual project).

    Where should you install it?

    If you're the only one on your team running it, globally is fine. If more than just you, then absolutely as a dev-only dependency inside your project ... and **maybe** globally as well.

    The only real problem is updates. If you use a reasonable global install scheme, updates will be easy. They're less easy inside your project or in `pre-commit`. And you might care one way or the other! I **don't** want updates! I **do** want updates!

    As for Python type-checking, `ty` seems good so far, but not enough experience with it yet. `basedpyright`, `pyrefly`, and `ruff` all good. These four are my favorites.

    #BasedPyright #Pyrefly #Ruff #PreCommit #CodeSpell #Homebrew

  25. ИИ бот-модератор 1: Начало проекта

    Знаете, в чём проблема большинства гайдов и курсов, которые обещают научить всему и сразу — да ещё и устроить на работу? Часто они учат примитиву, выдавая это за качественный контент. В итоге появляется много низкокачественного кода: на первый взгляд он работает, но в реальности трудно поддерживается . Если в проекте нет структуры, он быстро превращается в кашу. Каждая доработка — это не отдельный продуманный модуль, а «приматывание новых кусков кода синей изолентой» с мыслью: «хоть бы не сломалось». Для новичка это особенно опасно: кажется, что всё нормально, пока проект маленький, но при росте даже простые изменения начинают занимать часы и ломать соседние части. Вы наверняка задаётесь вопросом: «Почему рубрика называется “ИИ бот-модератор”, а автор тут рассказывает про качество кода?» На самом деле, всё связано. Telegram-бот для группы — отличный пример проекта, который очень быстро обрастает фичами: команды, настройки, роли, интеграции, хранение данных, логирование, админка, модерация, ИИ и т.д. Если делать всё “в одном файле”, это почти гарантированно закончится болью. Поэтому в этой рубрике мы будем строить бота так, чтобы его можно было развивать: добавлять функциональность без постоянного страха «сломать всё».

    habr.com/ru/articles/978282/

    #telegram #бот #ии #git #make #precommit #линтеры #ruff #ry #uv

  26. I have a script called pyfix which runs mypy and ruff to

    - have strong typing
    - have a fixed and orderly import order
    - have the file always formatted in the same way
    - detect programming errors and redundancies.

    Now I am working on gitlogui (codeberg.org/harald/gitlogui) the main script of which I called glu. So I am running

    pyfix glu

    all the time, which reads funny. 😀

    #python #gitlogui #mypy #ruff #strongTyping #linting

  27. Beginning to really appreciate the #rumdl project in helping me lint my Markdown and get some consistency in the formatting of the gazillion notes I've created for myself.

    Like #ruff and sphinx-lint, it's becoming a common part of my toolbox to keep my sloppiness in check and, perhaps, teach me some better formatting habits.

    github.com/rvben/rumdl

    #Markdown #lint #documentation

  28. 🎉 Great news for all heavy users of Spyder’s editor! 🎉

    In 6.1 it’ll give better and much faster error and warning messages!! 🚀⚡

    That’s thanks to @charliermarsh's Ruff package and Flake8. Hope you like it!

  29. Nuevo artículo: «Configurando pre-commit con ruff para un proyecto en Python»
    https://andros.dev/blog/fa7d1929/configurando-pre-commit-con-ruff-para-un-proyecto-en-python/

    Cuando utilizas Git, dispones de una herramienta muy poderosa llamada hooks. Te permite lanzar scripts en diferentes momentos del ciclo de vida de un repositorio. Por ejemplo, puedes ejecutar un comando después de hacer un push, el cual podría desplegar el código a un servidor, o lanzar un software que se ejecute antes de hacer un commit para asegurarte de que el código cumple con ciertas normas. Y aquí es donde entra en juego pre-commit.

    #python #uv #ruff #precommit #git #anuncios

  30. The pythonbuilder got a few improvements. Apart from introducing ruff as a consistent python code formatter and for linting in addition to mypy, it got a new module pbpython.py which wraps

    - ruff check
    - ruff format
    - mypy

    calls for easy use as target builders.

    codeberg.org/harald/pythonbuil

    #pythonbuilder
    #buildmachine
    #bashbuilder
    #buildsystem
    #buildtool
    #softwaredevelopment
    #programming
    #python
    #ruff
    #mypy

  31. Ruff: мой опыт выселения legacy-линтеров и повышения производительности кода

    Какими инструментами для линтинга и форматирования Python-кода вы пользуетесь? Black, Isort, Flake? Их существует множество, каждый следует своей цели, некоторые могут пересекаться по функциональности. Одни могут нравиться за автономность, другие — за возможности конфигурирования. И наверняка вы слышали о Ruff, который обещается заменить собой все. Привет, Хабр! Я Гена, Python-разработчик в Selectel. В этой статье я опишу свой опыт перевода проекта на Ruff: что понравилось, что — не очень, к чему готовиться и, если все же решитесь, то как это сделать. Добро пожаловать под кат.

    habr.com/ru/companies/selectel

    #ruff #python #linting #formatter #selectel

  32. Other #PyConUS sprints this week:

    * #RAPIDSai
    * django-simple-deploy and py-bugger
    * #PyFyre, #MyPy, and #MyPyC
    * MemRay
    * #Ruff or Ty from Astral
    * #WheelNext
    * ci-test / linting-arguments-python

    Additionally there will be an "Introduction to Sprints" open space in Room 310 at 6:00 PM.

    #PyConUS2025

  33. Как я строю удобную инфраструктуру вокруг Python-проектов: линтеры, Poetry, CI/CD и Docker

    Poetry вместо pip, Ruff вместо flake8, FastAPI вместо ручной документации. Что реально упрощает жизнь Python-разработчику сегодня — на примерах и с реальными конфигами.

    habr.com/ru/articles/904844/

    #python #fastapi #pydantic #docker #poetry #infrastructure #devops #ruff #управление_разработкой #precommit

  34. RT @charliermarsh

    Ruff v0.2.0 is out now 😎

    From v0.1.0 to v0.2.0, we saw...
    - 891 PRs
    - 118 contributors (including 80 new contributors)
    - Over 100 new rules

    astral.sh/blog/ruff-v0.2.0

    CC @charliermarsh