Находки в опенсорсе – Telegram
Находки в опенсорсе
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
​​Diagrams as code!

Turn #python based DSL into beatiful graphics. Diagrams currently supports four major providers: AWS, Azure, GCP and Kubernetes.

https://github.com/mingrammer/diagrams
​​D-Tale is the combination of a Flask back-end and a React front-end to bring you an easy way to view & analyze Pandas data structures. It integrates seamlessly with ipython notebooks & python/ipython terminals and PyCharm. Currently this tool supports such Pandas objects as DataFrame, Series, MultiIndex, DatetimeIndex & RangeIndex.

#python #react
​​Mint: The programming language for writing single page applications.
Mint has all the tools you need to write error free, easily readable and maintainable applications in record time.

Language features:

- Reusable components
- Styling
- Routing
- Global and local state handling
- Synchronous and asynchronous computations that might fail

Docs: https://www.mint-lang.com/
Playground: https://sandbox.mint-lang.com/

Personal opinion: I love programming languages. And I really respect people who build them. And I know that it is fun. But, a new language to color and move your buttons on web pages? Use #elm it has all the things you might need.

#js #css #html
> When we set out to rebuild our own website simplabs.com in 2019, we wanted to use that project as an opportunity to ignore all economic considerations (and reason you could say) and dive deep into what was technically possible. Doing so would allow us to build something that was super customized for our specific needs and highly optimized for performance. We ended up spending a lot of time and effort but are quite pleased with the result.

> While we cannot recommend anyone following our example as your time is most likely better spent elsewhere, this post explains the approach we took. I will be covering topics like static pre-rendering and client-side rehydration, advanced bundling and caching strategies as well as service workers.
> In most testing frameworks, you’re expected to write a lot of low-level tests and few high-level tests. The reasoning is that end-to-end tests are slow and expensive and only cover a tiny amount of the program’s state space. It’s better to focus on testing all the parts in isolation versus testing that they all work together.

> In practice, global correctness does not follow from local correctness. It’s possible for every part to be individually rock-solid but the system to be broken as a whole. One way this happens is with feature interaction (FI) bugs, where different features combine to break global properties.
​​Type Router: a flexible, type safe routing library.

First and foremost Type Route strives for excellent TypeScript support. An API designed for static analysis not only means the compiler has your back but also enables your editor to provide intelligent hints and warnings as you code.

https://www.type-route.org/

I had a blog post last year about problems in typing Vue and it includes router as one of the weakest points: https://sobolevn.me/2019/06/really-typing-vue

I am glad that people are working on it!

#vue #react #ts
​​Doorstop is a requirements management tool that facilitates the storage of textual requirements alongside source code in version control.

When a project leverages this tool, each linkable item (requirement, test case, etc.) is stored as a YAML file in a designated directory. The items in each directory form a document. The relationship between documents forms a tree hierarchy. Doorstop provides mechanisms for modifying this tree, validating item traceability, and publishing documents in several formats.

https://github.com/doorstop-dev/doorstop/

#python
​​Dead simple testing framework for #bash with coverage.

Code sample:

 test-foobar.sh

# Include your source files
source foobar.sh
# Include the framework
source critic.sh

# Write tests
_describe foo
_test "output should equal foo"
_assert _output_equals "foo"

_test "return code should be 0"
_assert _return_true "Optional assertion message"


https://github.com/Checksum/critic.sh
​​Updog is a replacement for #python's SimpleHTTPServer. It allows uploading and downloading via HTTP/S, can set ad hoc SSL certificates and use HTTP basic auth.

https://github.com/sc0tfree/updog
​​Disappearing-People - Person removal from complex backgrounds over time.

Removing people from complex backgrounds in real time using TensorFlow.js in the web browser using #js

https://github.com/jasonmayes/Real-Time-Person-Removal

Looks awesome!
Crocks: A collection of well known Algebraic Data Types for your utter enjoyment.

https://crocks.dev/

Personal opinion: the sad thing is that types are not included.

#js
​​Destiny: like prettier but for file structure.

What does this do?

1. Scans a folder for all the files in it
2. Creates a directed graph based on how the #js or #ts files import each other

https://github.com/benawad/destiny
​​mikro-orm: #ts ORM for Node.js based on Data Mapper, Unit of Work and Identity Map patterns.

Features:
1. Implicit Transactions: MikroORM allows handling transactions automatically. When you call em.flush(), all computed changes are wrapped inside a database transaction.
2. DRY Entities: Uses source code analysis so you do not have to repeat yourself when defining entities. Simply define correct TypeScript types and you are good to go!
3. Supports both SQL and NoSQL: Supports MongoDB, MySQL, MariaDB, PostgreSQL and SQLite databases, and more can be supported via custom drivers right now.

https://github.com/mikro-orm/mikro-orm
​​PostHog is open source product analytics, built for developers. Automate the collection of every event on your website or app, with no need to send data to 3rd parties. It's a 1 click to deploy on your own infrastructure, with full API/SQL access to the underlying data.

https://github.com/PostHog/posthog

#python #js
One of the most common questions about #rust from newcomers is: "why do we have both &str and String"?

This article has a great answer!
​​> Every time I want to write format a date in Ruby using strftime I have to look up the symbols for month, year, etc.

> This tool lets you just write your desired outcome (e.g. "March 3rd, 2019") and it generates the right #ruby code for you

Date strings are compatible with some other languages as well.

http://strftimer.com/
​​Playwright is a Node library to automate the Chromium, WebKit and Firefox browsers with a single API. It enables cross-browser web automation that is ever-green, capable, reliable and fast.

Our primary goal with Playwright is to improve automated UI testing by eliminating flakiness, improving the speed of execution and offering insights into the browser operation.

https://github.com/microsoft/playwright

#qa #ts
​​Conditional coverage based on any rules you define!

Some project have different parts that relies on different environments:

- #python version, some code is only executed on specific versions and ignored on others
- OS version, some code might be Windows, Mac, or Linux only
- External packages, some code is only executed when some 3rd party package is installed

Current best practice is to use # pragma: no cover for this places in your project.

coverage-conditional-plugin allows to use configurable pragmas that include code to the coverage if some condition evaluates to true, and fallback to ignoring this code when condition is false.

Read the announcing post: https://sobolevn.me/2020/02/conditional-coverage

Go star this repo: https://github.com/wemake-services/coverage-conditional-plugin
Great talk about solving the same simple problem with three completely different languages: #csharp, #haskell, and #clojure

From one of my favourite speakers / authors out there:

> First, we'll do a brief overview of the FizzBuzz kata, and see one 'idiomatic' way to implement it in C# (the Java, Javanoscript, Visual Basic, etc. version would be similar, so all OO programmers are welcome). Next, most of the talk will be a live demo showing approaches to the kata in Haskell and Clojure. If you've never seen Haskell or Clojure before, but are curious about these languages, this is the talk for you! Finally, we take some of the ideas from the Haskell and Clojure implementations, and bring them back to C# for a second attempt at the kata.
1
> When you start learning a programming language, how much time do you spend stuck on syntax errors? Hours? Days? As someone who once spent a full day trying to debug a MapReduce build before learning that you need backslashes in multi-line bash expressions, I know it is a deeply discouraging amount of time. Lots of people have suffered through experiences like this with missing semi-colons and curly braces, but how many people do not make it past these syntax errors? How many people fall off the syntax cliff and give up on a language or just quit programming entirely?

> So with the release of Elm 0.19.1 today, I am excited to share the new and improved syntax error messages! My hope is that the new compiler feels more like a teacher, showing helpful and relevant examples when you get stuck. The remainder of this post highlights some of the messages that people are likely to see when learning Elm, so you can decide for yourself!

#elm