# interpreted
A Python interpreter, written from scratch in Python.
This interpreter is made solely as the base for my talk,
"[Writing a Python interpreter from scratch, in half an hour.](https://ep2023.europython.eu/session/writing-a-python-interpreter-from-scratch-in-half-an-hour)", but is now being used as a project to learn how interpreters work.
Feel free to open up issues, pick up tasks, and ask questions.
## Installation
```bash
pip install interpreted
```
## Usage
```console
$ cat foo.py
print("2 + 2 is", 2 + 2)
def greet(name='User'):
print('Hello,', name + '!')
greet()
$ interpreted foo.py
2 + 2 is 4
Hello, User!
```
## Local Development / Testing
- Create and activate a virtual environment
- Run `pip install -r requirements-dev.txt` to do an editable install
- Run `pytest` to run tests
## Type Checking
Run `mypy .`
## Create and upload a package to PyPI
Make sure to bump the version in `setup.cfg`.
Then run the following commands:
```bash
rm -rf build dist
python setup.py sdist bdist_wheel
```
Then upload it to PyPI using [twine](https://twine.readthedocs.io/en/latest/#installation):
```bash
twine upload dist/*
```
Raw data
{
"_id": null,
"home_page": "https://github.com/tusharsadhwani/interpreted",
"name": "interpreted",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": null,
"keywords": null,
"author": "Tushar Sadhwani",
"author_email": "tushar.sadhwani000@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/8e/82/7d465d3111d309f5b8112645d8021fe3ee1c153be37002ca3dd54a047bf2/interpreted-0.2.0.tar.gz",
"platform": null,
"description": "# interpreted\n\nA Python interpreter, written from scratch in Python.\n\nThis interpreter is made solely as the base for my talk,\n\"[Writing a Python interpreter from scratch, in half an hour.](https://ep2023.europython.eu/session/writing-a-python-interpreter-from-scratch-in-half-an-hour)\", but is now being used as a project to learn how interpreters work.\n\nFeel free to open up issues, pick up tasks, and ask questions.\n\n## Installation\n\n```bash\npip install interpreted\n```\n\n## Usage\n\n```console\n$ cat foo.py\nprint(\"2 + 2 is\", 2 + 2)\n\ndef greet(name='User'):\n print('Hello,', name + '!')\n\ngreet()\n\n$ interpreted foo.py\n2 + 2 is 4\nHello, User!\n```\n\n## Local Development / Testing\n\n- Create and activate a virtual environment\n- Run `pip install -r requirements-dev.txt` to do an editable install\n- Run `pytest` to run tests\n\n## Type Checking\n\nRun `mypy .`\n\n## Create and upload a package to PyPI\n\nMake sure to bump the version in `setup.cfg`.\n\nThen run the following commands:\n\n```bash\nrm -rf build dist\npython setup.py sdist bdist_wheel\n```\n\nThen upload it to PyPI using [twine](https://twine.readthedocs.io/en/latest/#installation):\n\n```bash\ntwine upload dist/*\n```\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "A Python interpreter, in Python.",
"version": "0.2.0",
"project_urls": {
"Homepage": "https://github.com/tusharsadhwani/interpreted"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "28805177f5161770370ab1eb883ba679cc2f062e98cfe9becb6b9c7376235c92",
"md5": "b712224d889f81c7aada4744d030ee3c",
"sha256": "876be33af55dd047ca9723583ec5ccb990f1a837faae51861a7a93fffe6db445"
},
"downloads": -1,
"filename": "interpreted-0.2.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "b712224d889f81c7aada4744d030ee3c",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 18093,
"upload_time": "2024-07-04T12:44:44",
"upload_time_iso_8601": "2024-07-04T12:44:44.758612Z",
"url": "https://files.pythonhosted.org/packages/28/80/5177f5161770370ab1eb883ba679cc2f062e98cfe9becb6b9c7376235c92/interpreted-0.2.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "8e827d465d3111d309f5b8112645d8021fe3ee1c153be37002ca3dd54a047bf2",
"md5": "7df41d6402f708604620c7f5293fe76a",
"sha256": "5b91aa739477c146b0cc8ffb0d445729be5577471d3ad3ae89f33bf25791bd3f"
},
"downloads": -1,
"filename": "interpreted-0.2.0.tar.gz",
"has_sig": false,
"md5_digest": "7df41d6402f708604620c7f5293fe76a",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 16778,
"upload_time": "2024-07-04T12:44:48",
"upload_time_iso_8601": "2024-07-04T12:44:48.054775Z",
"url": "https://files.pythonhosted.org/packages/8e/82/7d465d3111d309f5b8112645d8021fe3ee1c153be37002ca3dd54a047bf2/interpreted-0.2.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-07-04 12:44:48",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "tusharsadhwani",
"github_project": "interpreted",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [],
"tox": true,
"lcname": "interpreted"
}