Skip to content

Commit

Permalink
Merge pull request #196 from NREL/ndr/update-deps
Browse files Browse the repository at this point in the history
update documentation; update tests; osmnx to 2.0
  • Loading branch information
nreinicke authored Nov 27, 2024
2 parents aa509d6 + b806fa0 commit 1185925
Show file tree
Hide file tree
Showing 93 changed files with 5,964 additions and 5,380 deletions.
31 changes: 0 additions & 31 deletions .github/workflows/assign_or_assign.yml

This file was deleted.

46 changes: 46 additions & 0 deletions .github/workflows/deploy-docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: deploy-docs

on:
push:
branches:
- main
paths:
- docs/**
- .github/workflows/deploy-docs.yaml


# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

jobs:
deploy-docs:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -el {0}
steps:
- uses: actions/checkout@v4

- uses: conda-incubator/setup-miniconda@v3
with:
auto-update-conda: true
python-version: "3.12"

- name: Install package
run: |
conda install -c conda-forge osmnx
pip install ".[dev]"
- name: Build book
run: |
jupyter-book build docs/
# Push the book's HTML to github-pages
- name: GitHub Pages action
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs/_build/html
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,19 @@ jobs:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install .[tests]
- name: Run black
run: black . --check
- name: Run ruff
- name: Run ruff linting
run: ruff check .
- name: Run ruff formatting
run: ruff format --check
- name: Run mypy
run: mypy .
- name: Run Tests
Expand Down
40 changes: 20 additions & 20 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,26 +8,26 @@ jobs:
deploy:
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/project/mappymatch/
name: pypi
url: https://pypi.org/project/mappymatch/
permissions:
id-token: write
id-token: write
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build
- name: Build package
run: |
python -m build
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.9"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install hatch
- name: Build package
run: |
hatch build
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
path: ./dist/*
- name: Publish package
uses: pypa/gh-action-pypi-publish@release/v1
- name: Publish package
uses: pypa/gh-action-pypi-publish@release/v1
24 changes: 13 additions & 11 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
repos:
- repo: https://github.com/psf/black
rev: 22.10.0
hooks:
- id: black
args: [--config, pyproject.toml]
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: v0.0.188
hooks:
- id: ruff

repos:
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: v0.8.0
hooks:
- id: ruff
- id: ruff-format

- repo: https://github.com/pre-commit/mirrors-mypy
rev: "v1.13.0"
hooks:
- id: mypy
additional_dependencies:
[matplotlib, pandas-stubs, pytest, types-requests]
20 changes: 0 additions & 20 deletions .readthedocs.yaml

This file was deleted.

71 changes: 71 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
# Contributing to mappymatch

Thank you for considering contributing to mappymatch.
This document provides a high-level overview of how you can get involved.

## Asking Questions

Have a question? Rather than opening an issue directly, please ask questions
or post comments in [Q&A Discussions](https://github.com/NREL/mappymatch/discussions/categories/q-a).
The NREL team or other members of the community will assist. Your well-worded
question will serve as a resource to others searching for help.

## Providing Feedback

Your comments and feedback are very welcome. Please post to
[General Discussions](https://github.com/NREL/mappymatch/discussions/categories/general)
with lots of information and detail. It is beneficial to consider
how someone else will understand your comments in order to make
them most effective.

## Reporting Issues

Have you identified a reproducible problem in mappymatch?
Have a feature request? We want to hear about it! Here's how you can make
reporting your issue as effective as possible.

### Look For an Existing Issue

Before you create a new issue, please do a search in
[open issues](https://github.com/NREL/mappymatch/issues) to see if
the issue or feature request has already been filed.

If you find your issue already exists, make relevant comments and add your
[reaction](https://github.com/blog/2119-add-reactions-to-pull-requests-issues-and-comments).
Use a reaction in place of a "+1" comment:

- 👍 - upvote
- 👎 - downvote

If you cannot find an existing issue that describes your bug or feature,
create a new issue using the guidelines below.

### Writing Good Bug Reports and Feature Requests

File a single issue per problem and feature request. Do not enumerate
multiple bugs or feature requests in the same issue.

Do not add your issue as a comment to an existing issue unless it's for the
identical input. Many issues look similar, but have different causes.

The more information you can provide, the more likely someone will
be successful at reproducing the issue and finding a fix.

Please follow the issue template guidelines to include relevant information
that will help in diagnosing the problem.

### Final Checklist

Please remember to do the following:

- [ ] Search the issue repository to ensure your report is a new issue

- [ ] Recreate the issue with a minimally descriptive example

- [ ] Simplify your code around the issue to better isolate the problem

## Contributing Fixes

If you are interested in writing code to fix an issue or
submit a new feature, let us know in
[Ideas Discussions](https://github.com/NREL/mappymatch/discussions/categories/ideas)!
File renamed without changes.
20 changes: 0 additions & 20 deletions docs/Makefile

This file was deleted.

12 changes: 12 additions & 0 deletions docs/_autosummary/mappymatch.constructs.coordinate.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
mappymatch.constructs.coordinate
================================

.. automodule:: mappymatch.constructs.coordinate


.. rubric:: Classes

.. autosummary::

Coordinate

12 changes: 12 additions & 0 deletions docs/_autosummary/mappymatch.constructs.geofence.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
mappymatch.constructs.geofence
==============================

.. automodule:: mappymatch.constructs.geofence


.. rubric:: Classes

.. autosummary::

Geofence

12 changes: 12 additions & 0 deletions docs/_autosummary/mappymatch.constructs.match.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
mappymatch.constructs.match
===========================

.. automodule:: mappymatch.constructs.match


.. rubric:: Classes

.. autosummary::

Match

13 changes: 13 additions & 0 deletions docs/_autosummary/mappymatch.constructs.road.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
mappymatch.constructs.road
==========================

.. automodule:: mappymatch.constructs.road


.. rubric:: Classes

.. autosummary::

Road
RoadId

17 changes: 17 additions & 0 deletions docs/_autosummary/mappymatch.constructs.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
mappymatch.constructs
=====================

.. automodule:: mappymatch.constructs


.. rubric:: Modules

.. autosummary::
:toctree:
:recursive:

coordinate
geofence
match
road
trace
12 changes: 12 additions & 0 deletions docs/_autosummary/mappymatch.constructs.trace.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
mappymatch.constructs.trace
===========================

.. automodule:: mappymatch.constructs.trace


.. rubric:: Classes

.. autosummary::

Trace

12 changes: 12 additions & 0 deletions docs/_autosummary/mappymatch.maps.igraph.igraph_map.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
mappymatch.maps.igraph.igraph\_map
==================================

.. automodule:: mappymatch.maps.igraph.igraph_map


.. rubric:: Classes

.. autosummary::

IGraphMap

Loading

0 comments on commit 1185925

Please sign in to comment.