Alternative StdLib for Nim for Python targets

Overview

Alternative StdLib for Nim for Python targets

Documentation

For more documentation, use Python official documentation, works too.

Design

  • 1 Dependency only.
  • 1 Nim module per 1 Python module.
  • Module files are <200 lines each of pure Nim code.
  • Arbitrary precision big Decimals with all the operators for Nim.
  • Compatible with ARC and ORC deterministic memory nanagement.
  • Enforces real strong inferred static typing with UFCS for Python.
  • Same API as Python StdLib, same function names, same argument names (Names starting and ending with double underscore are not legal in Nim).
  • Use the vanilla official Python StdLib that you already know by memory.
  • Same module filenames as Python StdLib, same imports as Python StdLib.
  • Documentation online, but also any Python documentation should work too.
  • Simple code using template, easy to hack for new users, KISS & DRY.
  • Stuff deprecated/removed in Python before year 2020 will not be supported.
  • We do not deprecate stuff, even if Python deprecate/remove it, it will keep working for Nim.
  • Each file is completely self-contained standalone, you can copy just 1 file on your project and use it.
  • If Python removes a module from StdLib you must obtain the .py file somehow, but the .nim remains.
  • It does not use anything from Nim standard library, very future-proof (uses Nimpy for Python-Nim interop, but other than that they are thin wrappers, with minimal dependency on StdLib).
  • Package version == Python version.
  • Pet the turtle.

Requisites

  • Python ( >2.7 works but unsupported, >3.5 minimal, >=3.10 recommended ).

Install

nimble install cpython

OR

nimble install https://github.com/juancarlospaco/cpython.git

Stars

Doing JavaScript or Web Dev ?

Why?

The idea comes from the community of "Nim en Espanol" Telegram group (Spanish).

Also...

  • Whole new StdLib becomes usable for Nim, without Nim having to spend resources.
  • Showcase easy interoperability of Nim (CTypes is harder, Python is verbose, etc).
  • Arbitrary precision big Decimals for Nim.
  • Others do it too (Scala/Kotlin uses Java StbLib, Swift uses Objective-C StdLib, etc).
  • Python does it too, Python is written in C therefore using C StdLib.
  • Make others work improving libs that you can use in Nim.
  • A place to pile up "Nim-ified" Python stuff.

See also

Owner
Juan Carlos
.10x frAgile FullStuck Midend Devlooper, Python & Nim, Arch & OpenSource, EN|ES, Argentina, UTC-3, UTF-8, UFCS
Juan Carlos
Make pack up python files easier.

python-easy-pack make pack up python files easier. 目前只提供了中文环境 如何使用? 将index.py复制到你的项目文件夹,或者把.py文件拷贝到这个文件夹。 打开你的cmd或者powershell 切换到程序所在目录,输入python index

2 Dec 15, 2021
Simple programming language built on Python.

Serial Another programming language. Built on Python. Building and running program In order to run the program on serial, unfortunately you still need

Aleksey Demchenkov 1 Dec 09, 2021
This is a Python 3.10 port of mock, a library for manipulating human-readable message strings.

This is a Python 3.10 port of mock, a library for manipulating human-readable message strings.

Alexander Bartolomey 1 Dec 31, 2021
一个可以自动生成PTGen,MediaInfo,截图,并且生成发布所需内容的脚本

Differential 差速器 一个可以自动生成PTGen,MediaInfo,截图,并且生成发种所需内容的脚本 为什么叫差速器 差速器是汽车上的一种能使左、右轮胎以不同转速转动的结构。使用同样的动力输入,差速器能够输出不同的转速。就如同这个工具之于PT资源,差速器帮你使用同一份资源,输出不同PT

Lei Shi 96 Dec 15, 2022
Allows you to purge all reply comments left by a user on a YouTube channel or video.

YouTube Spammer Purge Allows you to purge all reply comments left by a user on a YouTube channel or video. Purpose Recently, there has been a massive

4.3k Jan 09, 2023
Checking-For-Fibonacci-Syquence-In-Python - Checking For Fibonacci Syquence In Python

Checking-For-Fibonacci-Syquence-In-Python The Fibonacci sequence is a set of num

John Michael Oliba 1 Feb 14, 2022
Test reproducibility of leiden/umap on different systems

Demonstrate that UMAP and Leiden analysis is not reproducible between different cpu architectures.

Gregor Sturm 2 Oct 16, 2021
A visidata plugin for parsing f5 ltm/gtm/audit logs

F5 Log Visidata Plugin This plugin supports the default log format for: /var/log/ltm* /var/log/gtm* /var/log/apm* /var/log/audit* It extracts common l

James Deucker 1 Jan 06, 2022
Web app for keeping track of buildings in danger of collapsing in the event of an earthquake

Bulina Roșie 🇷🇴 Un cutremur în București nu este o situație ipotetică. Este o certitudine că acest lucru se va întâmpla. În acest context, la mai bi

Code for Romania 27 Nov 29, 2022
Web-based Sudoku solver built using Python. A demonstration of how backtracking works.

Sudoku Solver A web-based Sudoku solver built using Python and Python only The motivation is to demonstrate how Backtracking algorithm works. Some of

Jerry Ng 2 Dec 31, 2022
Code and data for learning to search in local branching

Code and data for learning to search in local branching

Defeng Liu 7 Dec 06, 2022
Stopmagic gives you the power of creating amazing Stop Motion animations faster and easier than ever before.

Stopmagic gives you the power of creating amazing Stop Motion animations faster and easier than ever before. This project is maintained by Aldrin Mathew.

Aldrin's Art Factory 67 Dec 31, 2022
Python based scripts for obtaining system information from Linux.

sysinfo Python based scripts for obtaining system information from Linux. Python2 and Python3 compatible Output in JSON format Simple scripts and exte

Petr Vavrin 70 Dec 20, 2022
《practical python programming》的中文翻译

欢迎光临 大约 25 年前,当我第一次学习 Python 时,发现 Python 竟然可以被高效地应用到各种混乱的工作项目上,我立即被震惊了。15 年前,我自己也将这种乐趣教授给别人。教学的结果就是本课程——一门实用的学习 Python的课程。

编程人 125 Dec 17, 2022
A basic ticketing software.

Ticketer A basic ticketing software. Screenshots Program Launched Issuing Ticket Show your Ticket Entry Done Program Exited Code Features to implement

Samyak Jain 2 Feb 10, 2022
The official Repository wherein newbies into Open Source can Contribute during the Hacktoberfest 2021

Hacktoberfest 2021 Get Started With your first Contrinution/Pull Request : Fork/Copy the repo by clicking the right most button on top of the page. Go

HacOkars 25 Aug 20, 2022
YourX: URL Clusterer With Python

YourX | URL Clusterer Screenshots Instructions for running Install requirements

ARPSyndicate 1 Mar 11, 2022
An OrpheusDL Tidal module

OrpheusDL - Tidal A Tidal module for the OrpheusDL modular archival music program Report Bug · Request Feature Table of content About OrpheusDL - Tida

Daniel 54 Dec 29, 2022
Oregon State University grade distributions from Fall 2018 through Summer 2021

Oregon State University Grades Oregon State University grade distributions from Fall 2018 through Summer 2021 obtained through a Freedom Of Informatio

Melanie Gutzmann 5 May 02, 2022
A pairs trade is a market neutral trading strategy enabling traders to profit from virtually any market conditions.

A pairs trade is a market neutral trading strategy enabling traders to profit from virtually any market conditions. This strategy is categorized as a statistical arbitrage and convergence trading str

Kanupriya Anand 13 Nov 27, 2022