Skip to content

Update GH actions to run test for the docs only if there are no changes to the underlying code #401

Open

Description

@SultanOrazbayev

This is an issue to keep track of a potential optimization. I will start the PR.

          > Unrelated to the issue/PR, but is it feasible/logical to ignore code tests on the update of docs only?

Yeah, that probably a good idea and doable. Want to give it a try? This might be a good resource:
https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#onpushpull_requestpull_request_targetpathspaths-ignore

Originally posted by @eriknw in #397 (comment)

Activity

  1. added
    hygieneImprove code quality and reduce maintenance overhead
    testsUnit tests and/or continuous integration
    on Mar 25, 2023
  2. eriknw commented on Apr 4, 2023

    @eriknw
    Member

    How feasible is this? What about docstrings that get included from code via autofunction, autoclass, and automodule? Do we know any other project that does this?

  3. SultanOrazbayev commented on Apr 5, 2023

    @SultanOrazbayev
    MemberAuthor

    I'm not aware of other projects that do it (not that I looked hard into it).

    In general, when running testing it feels like there is quite a bit of redundancy in testing the components that were not changed and were not affected. I realise it's not always feasible to build up the dependency links, but would the followng work?

    1. get the list of files with changes/diff
    2. if all files are in docs, then drop testing and only test/build docs.
  4. SultanOrazbayev commented on Apr 5, 2023

    @SultanOrazbayev
    MemberAuthor

    And yes, this won't affect docstrings, so not comprehensive, but at least for doc-specific changes should be faster/more efficient.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    hygieneImprove code quality and reduce maintenance overheadtestsUnit tests and/or continuous integration

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions