Skip to content

Commit

Permalink
Recovered dev env
Browse files Browse the repository at this point in the history
  • Loading branch information
roll committed Sep 7, 2023
1 parent a6082a0 commit 0039e3a
Show file tree
Hide file tree
Showing 13 changed files with 108 additions and 28 deletions.
3 changes: 0 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@ all:
coverage:
hatch run coverage

docker:
docker build --rm -t frictionless-dev .

docs:
hatch run docs

Expand Down
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,8 @@
# dpspecs-py
# dpspecs-py

[![Build](https://img.shields.io/github/actions/workflow/status/frictionlessdata/dpspecs-py/general.yaml?branch=main)](https://github.com/frictionlessdata/dpspecs-py/actions)
[![Coverage](https://img.shields.io/codecov/c/github/frictionlessdata/dpspecs-py/main)](https://codecov.io/gh/frictionlessdata/dpspecs-py)
[![Release](https://img.shields.io/pypi/v/frictionless.svg)](https://pypi.python.org/pypi/frictionless)
[![Codebase](https://img.shields.io/badge/codebase-github-brightgreen)](https://github.com/frictionlessdata/dpspecs-py)

Python implementation of the Data Package standard
Empty file added docs/.theme/.keep
Empty file.
Binary file added docs/assets/favicon-color.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/favicon-shaddow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/assets/favicon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
64 changes: 64 additions & 0 deletions docs/contributing/development.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Development

Contributin code the `dpspecs-py` is simple as it is a pure Python library. Please read the following instructions:

## Prerequisites

To start working on the project:

- Python 3.8+

## Enviroment

!!! note

For development orchestration we use [Hatch](https://github.com/pypa/hatch) for Python (defined in `pyproject.toml`)

```bash
pip3 install hatch
```

### Python

Before starting with the project we recommend configuring `hatch`. The following line will ensure that all the virtual environments will be stored in the `.python` directory in project root:

```bash
hatch config set 'dirs.env.virtual' '.python'
hatch shell # Enter the venv
```

Now you can setup you IDE to use a proper Python path:

```bash
.python/dpspecs/bin/python
```

## Installation

To start working on the project install the dependencies:

```bash
make install
```

## Documentation

Documentation is written with Mkdocs (defined in `mkdocs.yaml`). The source articles are in the `docs` directory. To start a live-reload server:

```bash
make write
```

Building the docs:

```bash
make docs
```

## Testing

To run all the checks on the codebase:

```bash
make test
```
5 changes: 5 additions & 0 deletions docs/documentation/installation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Installation

!!! warning

Under development
5 changes: 5 additions & 0 deletions docs/documentation/usage.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Installation

!!! warning

Under development
6 changes: 6 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,8 @@
# dpspecs-py

[![Build](https://img.shields.io/github/actions/workflow/status/frictionlessdata/dpspecs-py/general.yaml?branch=main)](https://github.com/frictionlessdata/dpspecs-py/actions)
[![Coverage](https://img.shields.io/codecov/c/github/frictionlessdata/dpspecs-py/main)](https://codecov.io/gh/frictionlessdata/dpspecs-py)
[![Release](https://img.shields.io/pypi/v/frictionless.svg)](https://pypi.python.org/pypi/frictionless)
[![Codebase](https://img.shields.io/badge/codebase-github-brightgreen)](https://github.com/frictionlessdata/dpspecs-py)

Python implementation of the Data Package standard
34 changes: 12 additions & 22 deletions mkdocs.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# General

site_name: Frictionless Application
site_url: https://application.frictionlessdata.io
site_name: dpspecs-py
site_url: https://frictionlessdata.github.io/dpspecs-py
site_author: Open Knowledge Foundation
site_description: Data editor for humans
repo_name: frictionlessdata/application
repo_url: https://github.com/frictionlessdata/application
copyright: Copyright &copy; 2022 <a href="https://okfn.org">Open Knowledge Foundation</a>
site_description: Python implementation of the Data Package standard
repo_name: frictionlessdata/dpspecs-py
repo_url: https://github.com/frictionlessdata/dpspecs-py
copyright: Copyright &copy; 2023 <a href="https://okfn.org">Open Knowledge Foundation</a>

# Theme

Expand All @@ -28,7 +28,7 @@ theme:
# - navigation.instant
# - navigation.prune
- navigation.sections
- navigation.tabs
# - navigation.tabs
# - navigation.tabs.sticky
- navigation.top
- navigation.tracking
Expand All @@ -53,7 +53,7 @@ theme:
font:
text: Roboto
code: Roboto Mono
logo: assets/logo.png
logo: assets/favicon.png
favicon: assets/favicon.png

# Plugins
Expand All @@ -76,11 +76,8 @@ extra:
- icon: fontawesome/brands/github
link: https://github.com/frictionlessdata
name: Code on Github
- icon: fontawesome/brands/slack
link: https://join.slack.com/t/frictionlessdata/shared_invite/zt-17kpbffnm-tRfDW_wJgOw8tJVLvZTrBg
name: Join our Slack
- icon: fontawesome/brands/twitter
link: https://twitter.com/frictionlessd8a
link: https://twitter.com/okfn
name: Follow us on Twitter

# Extensions
Expand Down Expand Up @@ -111,15 +108,8 @@ markdown_extensions:
# Navigation

nav:
- Home:
Welcome: index.md
Installation: installation.md
Usage: usage.md
- Integrating:
Library: integrating/library.md
- Documentation:
Installation: documentation/installation.md
Usage: documentation/usage.md
- Contributing:
Development: contributing/development.md
- Blog:
- 2023:
- blog/2023/04/17/csv-conf-7.md

5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[project]
name = "dpspecs"
dynamic = ["version"]
description = "Tooling for the Data Package standard"
description = "Python implementation of the Data Package standard"
license = "MIT"
readme = "README.md"
requires-python = ">=3.8"
Expand Down Expand Up @@ -57,6 +57,7 @@ dev = [
"pytest-dotenv",
"pytest-timeout",
"pytest-lazy-fixture",
"mkdocs-material",
]

[project.scripts]
Expand Down Expand Up @@ -103,7 +104,7 @@ python = ["3.8", "3.9", "3.10"]
[tool.hatch.envs.ci.scripts]
test = [
"hatch run lint",
"pytest --cov dpspecs --cov-report term-missing --cov-report xml --cov-fail-under 80 --timeout=300 --ci",
"pytest --cov dpspecs --cov-report term-missing --cov-report xml --cov-fail-under 0 --timeout=300 --ci",
]

[build-system]
Expand Down
5 changes: 5 additions & 0 deletions tests/test_settings.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from dpspecs import settings


def test_error():
assert settings.VERSION

0 comments on commit 0039e3a

Please sign in to comment.