Skip to content

Conversation

@odeimaiz
Copy link
Member

@odeimaiz odeimaiz commented May 9, 2025

What do these changes do?

This PR is the first iteration on the Creation of Functions required by the Meta Modeling case.

In order to be able to create a function out of a study, the study pipeline needs:

  • Inputs: at least one parameter (or file-picker (file type parameter))
  • Outputs: at least one probe
  • For now, only float type is supported @JavierGOrdonnez

if these requirements are met, a Create Function section will appear in the Study Card. From here, one can give a name, description and decide which inputs and outputs will be exposed.

When Create Function is pressed, the frontend will request the backend to create a template from the study, and then it will call "POST" the /functions endpoint (coming here).

CreateFunction

Related issue/s

How to test

Dev-ops

@odeimaiz odeimaiz self-assigned this May 9, 2025
@odeimaiz odeimaiz added this to the Bazinga! milestone May 9, 2025
@odeimaiz odeimaiz added t:enhancement Improvement or request on an existing feature a:frontend issue affecting the front-end (area group) labels May 9, 2025
@odeimaiz odeimaiz marked this pull request as ready for review May 9, 2025 14:57
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR introduces the first iteration for creating functions in the study pipeline. Key changes include:

  • New utility functions in Utils.js for extracting file-pickers, parameters, and probes, and a new boolean check (canCreateFunction) for when a function can be created.
  • A new CreateFunction widget in CreateFunction.js that builds a form for naming and configuring functions based on study data.
  • Updates to related files (Resources.js, ResourceDetails.js, ParameterEditor.js, and service Utils.js) to support and integrate this new functionality.

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
osparc/study/Utils.js Added helper functions (extractFilePickers, extractParameters, extractProbes) and canCreateFunction logic.
osparc/study/CreateFunction.js Introduced new widget for function creation with form layout and API interactions.
osparc/service/Utils.js Added utility functions to extract parameter and probe types/values.
osparc/node/ParameterEditor.js Updated to use the new parameter type extraction.
osparc/data/Resources.js Added configuration for the "functions" endpoint.
osparc/dashboard/ResourceDetails.js Integrated the new Create Function page and updated related UI elements.

@odeimaiz odeimaiz requested a review from JavierGOrdonnez May 9, 2025 15:06
Copy link
Member

@sanderegg sanderegg left a comment

Choose a reason for hiding this comment

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

😱

Copy link
Contributor

@GitHK GitHK left a comment

Choose a reason for hiding this comment

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

Copy link

@JavierGOrdonnez JavierGOrdonnez left a comment

Choose a reason for hiding this comment

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

Thanks for the effort @odeimaiz

@odeimaiz odeimaiz added the 🤖-automerge marks PR as ready to be merged for Mergify label May 12, 2025
@odeimaiz
Copy link
Member Author

@Mergifyio queue

@mergify
Copy link
Contributor

mergify bot commented May 12, 2025

queue

✅ The pull request has been merged automatically

The pull request has been merged automatically at 5125753

@sonarqubecloud
Copy link

@mergify mergify bot merged commit 5125753 into ITISFoundation:master May 12, 2025
59 checks passed
@matusdrobuliak66 matusdrobuliak66 mentioned this pull request Jun 6, 2025
92 tasks
@matusdrobuliak66 matusdrobuliak66 mentioned this pull request Aug 5, 2025
88 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🤖-automerge marks PR as ready to be merged for Mergify a:frontend issue affecting the front-end (area group) t:enhancement Improvement or request on an existing feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants