Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rerun cookiecutter with codespell edits #55

Merged
merged 13 commits into from
Nov 6, 2024
42 changes: 11 additions & 31 deletions .codecov.yml
Original file line number Diff line number Diff line change
@@ -1,34 +1,14 @@
# codecov can find this file anywhere in the repo, so we don't need to clutter
# the root folder.
#comment: false

codecov:
notify:
require_ci_to_pass: no

coverage:
status:
patch:
project: # more options at https://docs.codecov.com/docs/commit-status
default:
target: '70'
if_no_uploads: error
if_not_found: success
if_ci_failed: failure
project:
default: false
library:
target: auto
if_no_uploads: error
if_not_found: success
if_ci_failed: error
paths: '!*/tests/.*'

tests:
target: 97.9%
paths: '*/tests/.*'
if_not_found: success

flags:
tests:
paths:
- tests/
target: auto # use the coverage from the base commit, fail if coverage is lower
threshold: 0% # allow the coverage to drop by

comment:
layout: " diff, flags, files"
behavior: default
require_changes: false
require_base: false # [true :: must have a base report to post]
require_head: false # [true :: must have a head report to post]
hide_project_coverage: false # [true :: only show coverage on the git diff aka patch coverage]
2 changes: 2 additions & 0 deletions .codespell/ignore_lines.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
;; Please include filenames and explanations for each ignored line.
;; See https://docs.openverse.org/meta/codespell.html for docs.
14 changes: 14 additions & 0 deletions .codespell/ignore_words.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
;; Please include explanations for each ignored word (lowercase).
;; See https://docs.openverse.org/meta/codespell.html for docs.

;; abbreviation for "materials" often used in a journal title
mater

;; alternative use of socioeconomic
socio-economic

;; Frobenius norm used in np.linalg.norm
fro

;; cutted used as attribute in unit_test.py and fourigui.py
cutted
22 changes: 14 additions & 8 deletions .github/ISSUE_TEMPLATE/release_checklist.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,20 @@ assignees: ""
### Release checklist for GitHub contributors

- [ ] All PRs/issues attached to the release are merged.
- [ ] All the badges on the README are passing.
- [ ] License information is verified as correct. If you are unsure, please comment below.
- [ ] Locally rendered documentation contains all appropriate pages, including API references (check no modules are
- [x] All the badges on the README are passing.
- [x] License information is verified as correct. If you are unsure, please comment below.
- [x] Locally rendered documentation contains all appropriate pages, including API references (check no modules are
missing), tutorials, and other human written text is up-to-date with any changes in the code.
- [ ] Installation instructions in the README, documentation and on the website (e.g., diffpy.org) are updated and
tested
- [ ] Successfully run any tutorial examples or do functional testing in some other way.
- [ ] Grammar and writing quality have been checked (no typos).
- [x] Installation instructions in the README, documentation and on the website (e.g., diffpy.org) updated.
- [x] Successfully run any tutorial examples or do functional testing with the latest Python version
- [x] Grammar and writing quality have been checked (no typos).
cadenmyers13 marked this conversation as resolved.
Show resolved Hide resolved

Please mention @sbillinge when you are ready for release. Include any additional comments necessary, such as
version information and details about the pre-release.
version information and details about the pre-release here:

### Post-release checklist

Before closing this issue, please complete the following:

- [ ] Run tutorial examples and conduct functional testing using the installation guide in the README.
- [ ] Documentation (README, tutorials, API references, and websites) is deployed without broken links or missing figures.
2 changes: 1 addition & 1 deletion .github/workflows/build-wheel-release-upload.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Release (GitHub/PyPI)
name: Release (GitHub/PyPI) and Deploy Docs

on:
workflow_dispatch:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/tests-on-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,5 @@ jobs:
project: diffpy.fourigui
c_extension: false
headless: true
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
6 changes: 6 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,9 @@ repos:
name: Prevent Commit to Main Branch
args: ["--branch", "main"]
stages: [pre-commit]
- repo: https://github.com/codespell-project/codespell
rev: v2.3.0
hooks:
- id: codespell
additional_dependencies:
- tomli
3 changes: 1 addition & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ If you use diffpy.fourigui in a scientific publication, we would like you to cit
`Real-Space Texture and Pole-Figure Analysis Using the 3D Pair Distribution
Function on a Platinum Thin Film <https://doi.org/10.1107/S2052252522006674>`_. *IUCrJ* **9 (5)**, 594–603 (2022).


Installation
------------

Expand Down Expand Up @@ -125,7 +124,7 @@ trying to commit again.

Improvements and fixes are always appreciated.

Before contribuing, please read our `Code of Conduct <https://github.com/diffpy/diffpy.fourigui/blob/main/CODE_OF_CONDUCT.rst>`_.
Before contributing, please read our `Code of Conduct <https://github.com/diffpy/diffpy.fourigui/blob/main/CODE_OF_CONDUCT.rst>`_.

Contact
-------
Expand Down
23 changes: 23 additions & 0 deletions news/codespell.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
**Added:**

* Added `codespell` for spell check on all files.

**Changed:**

* <news item>

**Deprecated:**

* <news item>

**Removed:**

* <news item>

**Fixed:**

* <news item>

**Security:**

* <news item>
2 changes: 1 addition & 1 deletion news/test.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

**Fixed:**

* Surpress the `RuntimeWarning` in tests for the `applycutoff` function
* Suppress the `RuntimeWarning` in tests for the `applycutoff` function

**Security:**

Expand Down
7 changes: 6 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ classifiers = [
'Operating System :: Microsoft :: Windows',
'Operating System :: POSIX',
'Operating System :: Unix',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Programming Language :: Python :: 3.13',
'Topic :: Scientific/Engineering :: Physics',
'Topic :: Scientific/Engineering :: Chemistry',
]
Expand All @@ -54,6 +54,11 @@ namespaces = false # to disable scanning PEP 420 namespaces (true by default)
[tool.setuptools.dynamic]
dependencies = {file = ["requirements/pip.txt"]}

[tool.codespell]
exclude-file = ".codespell/ignore_lines.txt"
ignore-words = ".codespell/ignore_words.txt"
skip = "*.cif,*.dat"

[tool.black]
line-length = 115
include = '\.pyi?$'
Expand Down
4 changes: 2 additions & 2 deletions src/diffpy/fourigui/fourigui.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,10 +155,10 @@ def initUI(self):
anibutton.grid(row=8, column=4)

# row 10-12 Fourier transformation
seperator = tk.Label(
separator = tk.Label(
frame00, text=" "
) # __________________________________________________________________")
seperator.grid(row=9, column=0, columnspan=5)
separator.grid(row=9, column=0, columnspan=5)
cutofflabel = tk.Label(frame00, text="cutoff frequency")
cutofflabel.grid(row=10, column=2, columnspan=2)
qminlabel = tk.Label(frame00, text="qmin [px]:")
Expand Down
Loading