Skip to content

Commit

Permalink
Merge pull request #351 from sahiljhawar/rst-linter
Browse files Browse the repository at this point in the history
add `rst` linter
  • Loading branch information
sahiljhawar authored Apr 5, 2024
2 parents 99d7555 + 68ddb01 commit ff3ec49
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/rst-linter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Lint rst

on:
push:
paths: ['**/**.rst']
pull_request:
paths: ['**/**.rst']

jobs:
doctor-rst:
name: DOCtor-RST
runs-on: ubuntu-latest
steps:
- name: "Checkout code"
uses: actions/checkout@v4

- name: DOCtor-RST
uses: docker://oskarstark/doctor-rst
with:
args: --short --error-format=github
env:
DOCS_DIR: 'doc/'
5 changes: 5 additions & 0 deletions doc/.doctor-rst.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
rules:
blank_line_after_directive: ~
exclude_rule_for_file:
- path: changelog.rst
rule_name: blank_line_after_directive
3 changes: 3 additions & 0 deletions doc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ requirements.txt file which are necessary for NMMA:
If everything has gone smoothly, all of these above mentioned "pip install something" commands will show that the requirements have already been satisfied. Otherwise, these will cover the dependencies if not covered by ``pip install .``. Also, if running ``pip install .`` shows something on the lines of "cannot cythonize without cython", do:

.. code::
conda install -c anaconda cython==0.29.24
pip install
Expand Down Expand Up @@ -415,12 +416,14 @@ Internetless Clusters
Some cluster resources may not have access to the internet or could block some forms of data transfer. This will cause some difficulties with certain packages and will require some fixes to how NMMA interacts with them and changes to how you call some commands in NMMA. This can also affect how you install NMMA on the cluster. Because the cluster is in some way restricted, it may be that the `conda install nmma -c conda-forge` or the `pip install nmma` commands don't work. Thus to install NMMA, you will need to install from the source. To begin, you will want to copy the NMMA repository from your local to the cluster using an `scp` or `rsync` commmand because likely the git commands will fail. Once NMMA is downloaded to the cluster, navigate to the main directory and run

.. code::
pip install -r requirements.txt
pip install .
and check that the installation was successful by running the first check for NMMA given above. After installation, the next most likely difference is how NMMA uses the trained kilonova models during any form of EM analysis. When running any analysis that requires the use of the trained grid of models you will need to add the `--local-only` flag to the analysis command. For example,

.. code::
lightcurve-analysis \
--model LANLTP2 \
--svd-path svdmodels/ \
Expand Down

0 comments on commit ff3ec49

Please sign in to comment.