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

Decouple main actions logic #166

Open
germa89 opened this issue Feb 9, 2023 · 8 comments
Open

Decouple main actions logic #166

germa89 opened this issue Feb 9, 2023 · 8 comments
Labels
enhancement General improvements to existing features
Milestone

Comments

@germa89
Copy link
Contributor

germa89 commented Feb 9, 2023

📝 Description of the feature

This is a complain I have already rised, but I need to insist.

The current actions are veeery specific and complex. For example, doc-deploy-dev.

In this action we perform:

  • Checkout (now it is optional)
  • Download artifacts (and decompress)
  • documentation logic (upload jekill files, generate redirection, etc)

Proposed solution

I think these underlying actions should be grouped in "private" actions. For instance:

name: "Documentation deploy development version."
description: "Deploy development documentation to GitHub pages."

inputs:
  doc-artifact-name:
    description: "Name of the HTML documentation artifact."
    required: false
[...]

runs:
  using: "composite"
  steps:

    - name: "Checkout"
      uses: pyansys/actions/_doc_deploy_dev_checkout

    - name: "Download needed files"
       id: download
      uses: pyansys/actions/_doc_deploy_dev_download

    - name: "Documentation generation"
      uses: pyansys/actions/_doc_deploy_dev_doc_gen
      with:
          artifact_path: download.output.artifact_path

    - name: "Deploy"
      uses: pyansys/actions/_doc_deploy_dev_deploy

💡 Steps for implementing the feature

To be decided but I am happy to help (when I go back from holidays) if approved the PoC.

🔗 Useful links and references

No response

@germa89 germa89 added the enhancement General improvements to existing features label Feb 9, 2023
@germa89
Copy link
Contributor Author

germa89 commented Feb 9, 2023

Pinging @pyansys/pyansys-core for visibility

@jorgepiloto
Copy link
Member

Thanks for raising this concern, German.

I understand that the doc-deploy-* actions are long and may be difficult to read and maintain. However, I am not sure up to which point adding so many "private" actions is going to increase its maintainability over time.

@germa89
Copy link
Contributor Author

germa89 commented Feb 26, 2023

I understand more actions might increase the maintainability cost, and I agree.

But decoupling the main steps in several smaller (and maybe private) actions will enforce a common API between them and hence making easier individual changes in each one. Having everything in one big action goes (IMHO) against the componetization approach we are trying to take in PyAnsys.

@jorgepiloto
Copy link
Member

I am adding this to the list of tasks for the next release. Let us investigate more about it. At least, it should be feasible to isolate the common parts into private actions.

@jorgepiloto jorgepiloto added this to the v4.1 milestone Feb 27, 2023
@jorgepiloto
Copy link
Member

Postponing this for v4.2.

@jorgepiloto jorgepiloto modified the milestones: v4.1, v4.2 Jul 31, 2023
@jorgepiloto jorgepiloto modified the milestones: v6, v6.1 Apr 29, 2024
@jorgepiloto
Copy link
Member

Adding this to v6.1. It makes me wonder if we should put the effort in here or in #459.

@RobPasMue
Copy link
Member

I would go for #459... seems more appropriate.

@RobPasMue
Copy link
Member

They are not mutually exclusive though - but I'd tackle first the other one

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement General improvements to existing features
Projects
None yet
Development

No branches or pull requests

3 participants