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

Fix linters and installation using editable mode #151

Open
wants to merge 23 commits into
base: master
Choose a base branch
from

Conversation

Ali-Tehrani
Copy link
Collaborator

@Ali-Tehrani Ali-Tehrani commented Jan 10, 2024

This issue fixed the ruff errors. I left it as a pull-request in case it might mess up with merging with other pull-requests. It is also meant to test github actions. I commented out two tests so that the tests pass, see issue #152 for information about the two tests, these tests have been fixed and now pass.

Checklist

  • [x ] Write a good description of what the PR does.
  • Rebase onto master

Type of Changes

Type
🔨 Refactoring

Related

@Ali-Tehrani Ali-Tehrani changed the title Fix linters Fix linters and installation using editable mode Jan 10, 2024
@FarnazH FarnazH requested review from FarnazH and RichRick1 January 11, 2024 05:52
- Adding a comment on teh pull-request based on teh coverage
  only works if you're doign a pull-request from teh master
  branch
- Instead just did, get an error if it reaches a certain pt
- Fails if the total coverage is less than 90 percent.
@RichRick1
Copy link
Collaborator

@marco-2023 @Ali-Tehrani I assume this fix should solve the problem with automatic update of the website.

@Ali-Tehrani
Copy link
Collaborator Author

@marco-2023 Hi Marco, there is also instructions on how to build the website locally on your own computer, see here.

pyproject.toml Outdated
@@ -38,6 +38,10 @@ dependencies = [
]
dynamic = ["version"]

[tool.setuptools.packages.find]
where = ["."] # list of folders that contain the packages (["."] by default)
include = ["gbasis"] # package names should match these glob patterns (["*"] by default)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Specifically this line should pass the initial setup of the package that will run action for building and updating website later

@RichRick1
Copy link
Collaborator

RichRick1 commented Jan 11, 2024

@Ali-Tehrani @marco-2023 there is no need to do anything regarding the website build and deployment. building documentation and deployment is run automatically using GitHub actions here:
https://github.com/theochem/gbasis/blob/master/.github/workflows/main.yml

  1. Documentation is build using the sphinx:
    - name: Build the documentation
  2. Website is build using the Jupyter book:
    - name: Build the website
  3. And website is deployed using the ghpages
    - name: GitHub Pages Action

@Ali-Tehrani
Copy link
Collaborator Author

Ali-Tehrani commented Jan 11, 2024

I meant it before deployment, if you need to check the added docstrings and formulas look and formatted correctly before merging a pull-request. From what I understand, deployment only occurs when the pull-request gets merged, and not while the pull-request is running, as forked repositories don't have write permissions.

@RichRick1
Copy link
Collaborator

RichRick1 commented Jan 11, 2024

You are right, but I'm feeling like pushing things into ghpages branch manually may create issues with the website, especially when multiple people are working at the same time.
I think the safer option would be to just open file ./website/_build/html/index.html after running jupyter-book build ./website/
This will render the website exactly like it would look like deployed, but no need to push anything on gh-pages branch

@Ali-Tehrani
Copy link
Collaborator Author

Ali-Tehrani commented Jan 11, 2024

Okay, finally all of the tests and linters are working. I think it's ready to be merged and may take the executive decision to do it later, so that others can install using editable mode. Although I'm worried that it may add too much merge conflicts to others

@RichRick1 I completely agree with you on this and was not intending for it to be pushed to the gh-pages but only created locally.

@RichRick1
Copy link
Collaborator

@Ali-Tehrani okay, I can remove a section Pushing to the website from here then?

@Ali-Tehrani
Copy link
Collaborator Author

If you're worried about other people that have admin access, mistakenly updating it then sure.

@leila-pujal leila-pujal mentioned this pull request Jan 15, 2024
2 tasks
leila-pujal added a commit to leila-pujal/gbasis that referenced this pull request Apr 22, 2024
leila-pujal added a commit that referenced this pull request Apr 23, 2024
* Add function to get permutation with LibCint order

* Apply ordering permutation to libcint arrays

* Minor changes libcint conventions

* Add tests and files for iodata/libcint

* Change default convention for p spherical orbitals

* Add install libcint to workflow

* Exclude notebooks and test/*fchk from pre-commit

* Fix errors workflows and pre-commit

* Fix errors

- Install lisp interpreter
- Exclude only folders

* Skip install sbcl for windows

* Fix excluding folders pre-commit

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update syntax

* Debug workflows pytest

* Try again if statment in workflows

* Exclude libcint tests if build folder is not found

* Exclude libcint tests if operating in windows os

* Move imports from libcint into tests

* Add some changes included in PR #151

* Change to test with IOData to cover wrappers

* Delete version check IOData

* Add pyscf to tests to cover wrappers

* Remove pyscf and lower coverage requirement

---------

Co-authored-by: Michelle Richer <michellericher93@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants