Находки в опенсорсе
10.8K subscribers
11 photos
1 video
3 files
820 links
Привет!

Меня зовут Никита Соболев. Я занимаюсь опенсорс разработкой полный рабочий день.

Тут я рассказываю про #python, #c, опенсорс и тд.
Поддержать: https://boosty.to/sobolevn
РКН: https://vk.cc/cOzn36

Связь: @sobolev_nikita
Download Telegram
​​dump-env - a #python utility tool to create .env files.

dump-env takes an .env.template file and some optional environmental variables to create a new .env file from these two sources. No external dependencies are used.

https://github.com/sobolevn/dump-env
ORMs are something that seem cool until you have to do anything with them, and then they just get in the way. Their promises (backend-agnostic, write type-safe native code, less boilerplate) sometimes have a catch and sometimes are just false.

The reason for this is that ORMs are backwards: they force you to design schemas in your implementation language (python, javascript, java) and then export them to #sql ‘somehow’. (The ‘somehow’ is usually a half-baked migration tool). This is bad for a lot of reasons and horrible if you want to access your data from another language.
​​SHIP: Shell Helper to Initialize (dockerfiles) in a new Project: https://github.com/augustohp/ship

#docker
​​WebAssembly runtimes (e.g. browsers) are slightly diverging in which features they support.

So here’s wasm-feature-detect — think modernizr, but for #wasm.

- Detectors for various WebAssembly proposals
- Tiny (~600B)
- Easy to augment and contribute

https://github.com/GoogleChromeLabs/wasm-feature-detect
​​New PEP to #python! Adding a frozenmap type to collections: https://www.python.org/dev/peps/pep-0603/

At last! That's the first feature in a long time that was really required. Not :=!
​​webhint is a linting tool that will help you with your site's accessibility, speed, security and more, by checking your code for best practices and common errors. Use the online scanner or the CLI to start checking your site for errors: https://webhint.io/

#js #a11y
​​Caddy2 will be completely different from the first version. See the new Quickstart guide: https://github.com/caddyserver/caddy/tree/v2

Currently it is beta, but the new API looks ... strange?

#devops
​​🐋 Keep an eye on your #docker image size and prevent it from growing too big: https://github.com/wemake-services/docker-image-size-limit
​​GitLocalize is a continuous localization tool built for communities and teams that want to simplify their workflow when translating their content.

GitLocalize automatically keeps translations up to date by syncing with your repository.

https://github.com/marketplace/gitlocalize

#i18n #l10n
Backends today are too complicated to build. #dark is designed to massively reduce that complexity. Dark is a holistic programming language, editor, and infrastructure for building backends. You write in the Dark language, using the Dark editor, and your program is hosted on Dark’s infrastructure. As a result, you can code without thinking about infrastructure, and have safe instant deployment, which we’re calling “deployless”.
​​Automated face warping #python tool. For each face in an image define what actions are to be performed on it, pychubby will do the rest: https://github.com/jankrepl/pychubby

 matplotlib.pyplot as plt

from pychubby.actions import Chubbify, Multiple, Pipeline, Smile
from pychubby.detect import LandmarkFace

img_path = 'path/to/your/image'
img = plt.imread(img_path)

lf = LandmarkFace.estimate(img)

a_per_face = Pipeline([Chubbify(), Smile()])
a_all = Multiple(a_per_face)

new_lf, _ = a_all.perform(lf)
new_lf.plot(show_landmarks=False, show_numbers=False)
Vue recently presented the Composition API RFC, a new API for writing #vue components inspired by #react hooks but with some interesting differences that I will discuss in this post. This RFC started with a previous version called Function-based Component API that received lots of criticism from certain part of the community, based on the fear of Vue starting to be more complicated and less like the simple library that people liked in the first place.

So, let's get started studying the different aspects of React Hooks and Vue Composition API and remark certain differences that we might find along the way.
​​hypothesis-auto is an extension for the Hypothesis project that enables fully automatic #python tests for type annotated functions. Key Features:

- Type Annotation Powered: Utilize your function's existing type annotations to build dozens of test cases automatically.
- Low Barrier: Start utilizing property-based testing in the lowest barrier way possible. Just run auto_test(FUNCTION) to run dozens of test.
- py.test Compatible: Built-in compatibility with the popular py.test testing framework. This means that you can turn your automatically generated tests into individual py.test test cases with one line.
- Scales Up: As you find your self needing to customize your auto_test cases, you can easily utilize all the features of Hypothesis, including custom strategies per a parameter.

https://timothycrosley.github.io/hypothesis-auto/
​​Gearbox is a functional state machine for #elixir with an easy-to-use API, inspired by both Fsm and Machinery.

Gearbox does not run in a process, so there's no potential for a GenServer bottleneck. This way there's also less overhead as you won't need to setup a supervision tree/manage your state machine processes.

https://github.com/edisonywh/gearbox