Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
80 commits
Select commit Hold shift + click to select a range
c03973c
Run black diffpy
bobleesj Aug 1, 2024
3f12010
Run black .
bobleesj Aug 1, 2024
6764bef
Add flake8 file
bobleesj Aug 1, 2024
157f7ed
Fix flake8 file
bobleesj Aug 1, 2024
5439088
Merge pull request #53 from bobleesj/black
sbillinge Aug 1, 2024
90dd060
Fix all flake8 issues
bobleesj Aug 2, 2024
f3f8ae3
Run precommit
bobleesj Aug 2, 2024
b435314
Re-run pre-commit
bobleesj Aug 2, 2024
504568e
Merge pull request #55 from bobleesj/precommit
sbillinge Aug 2, 2024
b70628b
Avoid lamdbda flake8 erorr with private function
bobleesj Aug 2, 2024
9ca7caf
Fix return description of private func
bobleesj Aug 2, 2024
1243f1a
Add noqa: E731 for lambda func
bobleesj Aug 7, 2024
ac2d944
Clarify lambda func name
bobleesj Aug 7, 2024
fab4728
Track License, code of conduct, readme
bobleesj Aug 7, 2024
5d3b42e
Track src
bobleesj Aug 7, 2024
f4b83b2
Track requirement files
bobleesj Aug 7, 2024
37b8547
Track doc source api and static, news
bobleesj Aug 7, 2024
fbc2163
Track GH files
bobleesj Aug 7, 2024
54ad0c0
Track cfg and MANIFEST.in files
bobleesj Aug 7, 2024
548915e
[pre-commit.ci] auto fixes from pre-commit hooks
pre-commit-ci[bot] Aug 7, 2024
fb9661e
Merge pull request #56 from bobleesj/lambda
sbillinge Aug 7, 2024
dbc8a65
Add requirements to run.txt
bobleesj Aug 7, 2024
e2cb35d
Remove requirements/README.txt
bobleesj Aug 7, 2024
1611d94
Merge pull request #57 from bobleesj/cookierelease
sbillinge Aug 7, 2024
48e99db
Remove one of diffpy dirs
bobleesj Aug 7, 2024
e10c264
Modify codecov src path
bobleesj Aug 7, 2024
a537d7a
Merge pull request #58 from bobleesj/cookierelease-test
sbillinge Aug 8, 2024
f428d5d
Modify doc absolute path
bobleesj Aug 8, 2024
a85403c
Remove empty files under doc
bobleesj Aug 8, 2024
237c75f
Remove pdfmorph quickstart
bobleesj Aug 8, 2024
ef31dd1
Add section headers to quickstart.rst
bobleesj Aug 9, 2024
ed08231
[pre-commit.ci] auto fixes from pre-commit hooks
pre-commit-ci[bot] Aug 9, 2024
88826da
Merge pull request #60 from bobleesj/cookierelease-filter
sbillinge Aug 9, 2024
12b09f9
Remove older LICENSE and REAMDE.md
bobleesj Aug 9, 2024
a9312a0
API doc success
bobleesj Aug 9, 2024
0af373d
Remove rever.xsh and setup.py
bobleesj Aug 9, 2024
5e57da1
Modify pyproject.toml
bobleesj Aug 9, 2024
45c99e1
[pre-commit.ci] auto fixes from pre-commit hooks
pre-commit-ci[bot] Aug 9, 2024
2d0a70f
Merge pull request #61 from bobleesj/api-workflow
sbillinge Aug 9, 2024
a23b95c
Add news under cookie.rst
bobleesj Aug 9, 2024
c79c7cc
Use doc/conf.py and liense from diffpy.pdfffit2
bobleesj Aug 10, 2024
190c28d
Modify conf.py
bobleesj Aug 10, 2024
75e1f15
[pre-commit.ci] auto fixes from pre-commit hooks
pre-commit-ci[bot] Aug 10, 2024
7aab5eb
Change of instances of pdffit2 to snmf
bobleesj Aug 10, 2024
5b9bd96
Fix date in readme.rst
bobleesj Aug 10, 2024
8163037
[pre-commit.ci] auto fixes from pre-commit hooks
pre-commit-ci[bot] Aug 10, 2024
94d1d90
Update release news
bobleesj Aug 10, 2024
bdacc6d
Fix dev status to 4
bobleesj Aug 10, 2024
b19d024
Add earlier year next to copyright 2024
bobleesj Aug 10, 2024
4f020be
Fix copyright years to 2023-2024
bobleesj Aug 11, 2024
90b559c
Merge pull request #62 from bobleesj/sign-off
sbillinge Aug 11, 2024
62bfc1f
Add 2023 to LICNESE.rst
bobleesj Aug 11, 2024
939bbdd
Make quickstart section clear with TBA
bobleesj Aug 11, 2024
115b579
Merge pull request #63 from bobleesj/doc-host
sbillinge Aug 11, 2024
019659e
Remove older doc.yml and add cookie on push
bobleesj Aug 12, 2024
e2ab8db
Add citation to README.rst
bobleesj Aug 12, 2024
f907473
Add citation to doc index.rst
bobleesj Aug 12, 2024
94def5a
Merge pull request #66 from bobleesj/cookie-doc
sbillinge Aug 12, 2024
4c51c55
Merge pull request #68 from bobleesj/cookie-citation
sbillinge Aug 12, 2024
daf401d
Clean up index.rst with redundant info
bobleesj Aug 12, 2024
1e5050d
Add package description in README.rst
bobleesj Aug 12, 2024
50bf2fd
Fix typo from diff.pysnmf to diffpy.snmf
bobleesj Aug 12, 2024
b1a3b87
Update docs, main.yml to Aug 11, 2024
bobleesj Aug 12, 2024
917883f
Update make.bat and makefile files to cookiecutter
bobleesj Aug 12, 2024
e0afc02
Add repository to placeholder
bobleesj Aug 12, 2024
c36b6d6
Merge pull request #71 from bobleesj/cookie-udpate-yml
sbillinge Aug 12, 2024
4bc33e7
Update REAMDE longer description
bobleesj Aug 12, 2024
cfdc529
Remove run test file
bobleesj Aug 12, 2024
997cfa7
Remove run test file in tests folder
bobleesj Aug 12, 2024
06fa935
Merge pull request #72 from bobleesj/cookie-remove-test-file
sbillinge Aug 12, 2024
5446afd
Make a clear ref to the paper in readme
bobleesj Aug 12, 2024
b9befdf
Merge pull request #70 from bobleesj/cookie-description
sbillinge Aug 13, 2024
7ca7ced
Fix doc.yml
bobleesj Aug 13, 2024
25eca53
Update cooke docs.yml
bobleesj Aug 13, 2024
fb0665a
Fix typo coonda to conda
bobleesj Aug 13, 2024
2103e4c
fix yml syntax in docs.yml
bobleesj Aug 13, 2024
8faeb7d
Add install test.txt
bobleesj Aug 13, 2024
107faf7
Debug coverage installation
bobleesj Aug 13, 2024
96ba768
Remove cookie branches to prevent Codecov deployment
bobleesj Aug 13, 2024
14b27e9
Merge pull request #74 from bobleesj/cookie-docs-fix
sbillinge Aug 13, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[run]
source =
diffpy/snmf/
source =
src
[report]
omit =
*/python?.?/*
Expand Down
11 changes: 11 additions & 0 deletions .flake8
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[flake8]
exclude =
.git,
__pycache__,
build,
dist,
doc/source/conf.py
max-line-length = 115
# Ignore some style 'errors' produced while formatting by 'black'
# https://black.readthedocs.io/en/stable/guides/using_black_with_other_tools.html#labels-why-pycodestyle-warnings
extend-ignore = E203
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
diffpy.snmf/_version.py export-subst
59 changes: 59 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
name: Build Documentation

on:
push:
branches:
- main
release:

jobs:
test:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0

- uses: conda-incubator/setup-miniconda@v2
with:
activate-environment: build
environment-file: ./environment.yml
python-version: 3
auto-update-conda: true

- name: install requirements
run: |
conda config --set always_yes yes --set changeps1 no
conda config --add channels conda-forge
conda create -n build python=3.12
conda activate build
conda install --file requirements/build.txt
conda install --file requirements/run.txt
conda install --file requirements/test.txt
conda install --file requirements/docs.txt
python -m pip install . --no-deps

- name: build documents
run: make -C doc html

- name: Run tests and upload coverage
shell: bash -l {0}
run: |
conda activate build
coverage run -m pytest -vv -s
coverage report -m
codecov

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

- name: Deploy
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./doc/build/html
37 changes: 0 additions & 37 deletions .github/workflows/documentation.yml

This file was deleted.

12 changes: 4 additions & 8 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches:
- main
- CI
pull_request:
workflow_dispatch:

Expand All @@ -19,9 +20,8 @@ jobs:
uses: actions/checkout@v3
with:
repository: diffpy/diffpy.snmf
# for bookkeeping have diffpy.snmf at the same level as everything else in the
# directory tree
path: .
fetch-depth: 0 # avoid shallow clone with no tags

- name: initialize miniconda
# this uses a marketplace action that sets up miniconda in a way that makes
Expand Down Expand Up @@ -50,10 +50,6 @@ jobs:
shell: bash -l {0}
run: |
conda activate test
coverage run run_tests.py
coverage run -m pytest -vv -s
coverage report -m

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
codecov
19 changes: 19 additions & 0 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: pre-commit

on:
pull_request:
push:
workflow_dispatch:

jobs:
pre-commit:
# pull requests are a duplicate of a branch push if within the same repo.
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.repository

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
- uses: pre-commit/action@v3.0.0
with:
extra_args: --all-files
4 changes: 4 additions & 0 deletions .isort.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[settings]
line_length = 115
multi_line_output = 3
include_trailing_comma = True
43 changes: 43 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
default_language_version:
python: python3
ci:
autofix_commit_msg: |
[pre-commit.ci] auto fixes from pre-commit hooks
autofix_prs: true
autoupdate_branch: 'pre-commit-autoupdate'
autoupdate_commit_msg: '[pre-commit.ci] pre-commit autoupdate'
autoupdate_schedule: monthly
skip: [no-commit-to-branch]
submodules: false
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
hooks:
- id: check-yaml
- id: end-of-file-fixer
- id: trailing-whitespace
exclude: '\.(rst|txt)$'
- repo: https://github.com/psf/black
rev: 24.4.2
hooks:
- id: black
- repo: https://github.com/pycqa/flake8
rev: 7.0.0
hooks:
- id: flake8
- repo: https://github.com/pycqa/isort
rev: 5.13.2
hooks:
- id: isort
args: ["--profile", "black"]
- repo: https://github.com/kynan/nbstripout
rev: 0.7.1
hooks:
- id: nbstripout
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: no-commit-to-branch
name: Prevent Commit to Main Branch
args: ["--branch", "main"]
stages: [pre-commit]
7 changes: 4 additions & 3 deletions AUTHORS.rst
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
Authors
====================
=======

Ran Gu, Adeolu Ajayi, Qiang Du, Simon J.L. Billinge
Billinge Group and community contibutors.

Contributors
------------
For a full list of contributors, visit

For a list of contributors, visit
https://github.com/diffpy/diffpy.snmf/graphs/contributors
7 changes: 3 additions & 4 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
===========
Change Log
===========
=============
Release Notes
=============

.. current developments

133 changes: 133 additions & 0 deletions CODE_OF_CONDUCT.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,133 @@
=====================================
Contributor Covenant Code of Conduct
=====================================

Our Pledge
----------

We as members, contributors, and leaders pledge to make participation in our
community a harassment-free experience for everyone, regardless of age, body
size, visible or invisible disability, ethnicity, sex characteristics, gender
identity and expression, level of experience, education, socio-economic status,
nationality, personal appearance, race, caste, color, religion, or sexual
identity and orientation.

We pledge to act and interact in ways that contribute to an open, welcoming,
diverse, inclusive, and healthy community.

Our Standards
-------------

Examples of behavior that contributes to a positive environment for our
community include:

* Demonstrating empathy and kindness toward other people
* Being respectful of differing opinions, viewpoints, and experiences
* Giving and gracefully accepting constructive feedback
* Accepting responsibility and apologizing to those affected by our mistakes,
and learning from the experience
* Focusing on what is best not just for us as individuals, but for the overall
community

Examples of unacceptable behavior include:

* The use of sexualized language or imagery, and sexual attention or advances of
any kind
* Trolling, insulting or derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or email address,
without their explicit permission
* Other conduct which could reasonably be considered inappropriate in a
professional setting

Enforcement Responsibilities
----------------------------

Community leaders are responsible for clarifying and enforcing our standards of
acceptable behavior and will take appropriate and fair corrective action in
response to any behavior that they deem inappropriate, threatening, offensive,
or harmful.

Community leaders have the right and responsibility to remove, edit, or reject
comments, commits, code, wiki edits, issues, and other contributions that are
not aligned to this Code of Conduct, and will communicate reasons for moderation
decisions when appropriate.

Scope
-----

This Code of Conduct applies within all community spaces, and also applies when
an individual is officially representing the community in public spaces.
Examples of representing our community include using an official email address,
posting via an official social media account, or acting as an appointed
representative at an online or offline event.

Enforcement
-----------

Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported to the community leaders responsible for enforcement at
sb2896@columbia.edu. All complaints will be reviewed and investigated promptly and fairly.

All community leaders are obligated to respect the privacy and security of the
reporter of any incident.

Enforcement Guidelines
----------------------

Community leaders will follow these Community Impact Guidelines in determining
the consequences for any action they deem in violation of this Code of Conduct:

1. Correction
****************

**Community Impact**: Use of inappropriate language or other behavior deemed
unprofessional or unwelcome in the community.

**Consequence**: A private, written warning from community leaders, providing
clarity around the nature of the violation and an explanation of why the
behavior was inappropriate. A public apology may be requested.

2. Warning
*************

**Community Impact**: A violation through a single incident or series of
actions.

**Consequence**: A warning with consequences for continued behavior. No
interaction with the people involved, including unsolicited interaction with
those enforcing the Code of Conduct, for a specified period of time. This
includes avoiding interactions in community spaces as well as external channels
like social media. Violating these terms may lead to a temporary or permanent
ban.

3. Temporary Ban
******************

**Community Impact**: A serious violation of community standards, including
sustained inappropriate behavior.

**Consequence**: A temporary ban from any sort of interaction or public
communication with the community for a specified period of time. No public or
private interaction with the people involved, including unsolicited interaction
with those enforcing the Code of Conduct, is allowed during this period.
Violating these terms may lead to a permanent ban.

4. Permanent Ban
******************

**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
individual, or aggression toward or disparagement of classes of individuals.

**Consequence**: A permanent ban from any sort of public interaction within the
community.

Attribution
-----------

This Code of Conduct is adapted from the `Contributor Covenant <https://www.contributor-covenant.org/version/2/1/code_of_conduct.html>`_.

Community Impact Guidelines were inspired by `Mozilla's code of conduct enforcement ladder <https://github.com/mozilla/inclusion>`_.

For answers to common questions about this code of conduct, see the `FAQ <https://www.contributor-covenant.org/faq>`_. `Translations are available <https://www.contributor-covenant.org/translations>`_
Loading