Skip to content

Commit

Permalink
Merge pull request #2 from pyjanitor-devs/rdfio-intro
Browse files Browse the repository at this point in the history
introduction of notebook pyjviz support
  • Loading branch information
asmirnov69 authored Mar 6, 2023
2 parents cfadc99 + 0742737 commit 1ef7b08
Show file tree
Hide file tree
Showing 47 changed files with 3,303 additions and 989 deletions.
148 changes: 144 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,145 @@
*~
# Custom
.vscode/*
test*.xml
*.DS_Store
docs/notebooks
pip-wheel-metadata

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
pyjviz.egg-info/
pyjviz/__pycache__/
pyjviz-test-output/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg
function_test.ipynb
# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
.hypothesis/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# pyenv
.python-version

# celery beat schedule file
celerybeat-schedule

# SageMath parsed files
*.sage.py

# dotenv
.env

# virtualenv
.venv
.venv*/
venv/
env/
ENV/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/

# pycharm
.idea/


# Custom
.pytest_cache

# Ingore docs' symbolic link to notebooks
docs/notebooks
docs/*


# Swap
[._]*.s[a-v][a-z]
[._]*.sw[a-p]
[._]s[a-rt-v][a-z]
[._]ss[a-gi-z]
[._]sw[a-p]

# Session
Session.vim
Sessionx.vim

# Temporary
.netrwhist
*~
# Auto-generated tag files
tags
# Persistent undo
[._]*.un~

# Other stuff
*.profraw
/scratch.py
midpoint.csv
63 changes: 63 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
SHELL=/bin/bash
ACTIVATE=source activate pyjviz

release:
rm -f dist/*
python setup.py sdist bdist_wheel
twine upload dist/*

# Note to self:
# makefile has not been fully tested.
# DO NOT COMMIT until testing is done.
#
# ALSO, remove this comment once it's tested!!!!!!!!!!!

.PHONY: format test lint docs isort check style notebooks install

format:
@echo "Applying Black Python code formatting..."
pre-commit run black --all-files

test:
@echo "Running test suite..."
pytest -v -n auto --color=yes

lint:
@echo "Checking code formatting..."
pre-commit run flake8 --all-files

lint-src:
@echo "Checking code formatting in pyjviz source dir..."
flake8 --color never pyjviz

docs:
@echo "Building documentation..."
mkdocs build

isort:
@echo "Sorting imports..."
isort --check-only --use-parentheses --trailing-comma --multi-line 3 --line-length 79 .

check: test docs notebooks isort format lint
@echo "checks complete"

style: isort format
@echo "styling complete"

install:
@echo "Creating Conda environment..."
conda env create -f environment-dev.yml

@echo "Installing pyjviz in development mode..."
$(ACTIVATE) && python setup.py develop

@echo "Registering current virtual environment as a Jupyter Python kernel..."
$(ACTIVATE) && python -m ipykernel install --user --name pyjviz-dev --display-name "pyjviz development"

@echo "Installing pre-commit hooks"
$(ACTIVATE) && pre-commit install

compile-requirements:
@echo "pip-compiling requirements files..."
find .requirements -type f -name '*.in' | xargs -I {} sh -c\
'echo "compiling" {} && pip-compile {} --upgrade -q'
77 changes: 0 additions & 77 deletions README.md

This file was deleted.

1 change: 1 addition & 0 deletions README.md
5 changes: 5 additions & 0 deletions docs/api/test.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Test

<b>Hello</b>

::: pyjviz
53 changes: 53 additions & 0 deletions docs/css/apidocs.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/* https://mkdocstrings.github.io/theming/#css-classes */
.doc-property {
border-radius: 15px;
padding: 0 5px;
}
.doc-property-special {
background-color: blue;
color: white;
}
.doc-property-private {
background-color: red;
color: white;
}
.doc-property-property {
background-color: green;
color: white;
}
.doc-property-read-only {
background-color: yellow;
color: black;
}

/* https://mkdocstrings.github.io/handlers/python/#recommended-style-material */
/* Indentation. */
div.doc-contents:not(.first) {
padding-left: 25px;
border-left: 4px solid rgba(230, 230, 230);
margin-bottom: 80px;
}

/* add a keyboard shortcut icon for search bar,
* https://github.com/squidfunk/mkdocs-material/issues/2574#issuecomment-821979698
*/
[data-md-toggle="search"]:not(:checked) ~ .md-header .md-search__form::after {
position: absolute;
top: 0.3rem;
right: 0.3rem;
display: block;
padding: 0.1rem 0.4rem;
color: var(--md-default-bg-color--lighter);
font-weight: bold;
font-size: 0.8rem;
border: 0.05rem solid var(--md-default-bg-color--lighter);
border-radius: 0.1rem;
content: "/";
}

/* prevent selection of chevron in example blocks
* cf. https://mkdocstrings.github.io/recipes/#prevent-selection-of-prompts-and-output-in-python-code-blocks
*/
.highlight .gp, .highlight .go { /* Generic.Prompt, Generic.Output */
user-select: none;
}
3 changes: 3 additions & 0 deletions docs/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Examples

::: examples
Loading

0 comments on commit 1ef7b08

Please sign in to comment.