- 
                Notifications
    You must be signed in to change notification settings 
- Fork 1
feat(apify): Actor run improvements #5
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
Conversation
… and change how Actor or task name is displayed
There was a problem hiding this 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 enhances the Apify Actor run action to improve user experience and align with other integrations. The changes add a new search source selection for Actors, update the display format to show more descriptive labels, and simplify synchronous runs by removing the wait timeout option.
- Add Actor search source selection (Store vs Recently used Actors)
- Update Actor and Task display format to include title and username/name format
- Remove wait for finish input for synchronous runs and use build parameter instead
Reviewed Changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated 3 comments.
| File | Description | 
|---|---|
| components/apify/sources/new-finished-actor-run-instant/new-finished-actor-run-instant.mjs | Updates prop definition reference from userActorId to actorId | 
| components/apify/apify.app.mjs | Consolidates Actor selection logic, adds search source functionality, and updates display formatting | 
| components/apify/actions/run-actor/run-actor.mjs | Adds Actor source selection, removes wait timeout, and updates parameter handling | 
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
| value, | ||
| ] of Object.entries(data)) { | ||
| const editor = properties[key].editor; | ||
| const editor = properties[key]?.editor; | 
    
      
    
      Copilot
AI
    
    
    
      Jul 23, 2025 
    
  
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding optional chaining here suggests that properties[key] might be undefined, but this could cause silent failures. The code should handle the case where the property doesn't exist more explicitly to avoid unexpected behavior in the setValue function.
| const editor = properties[key]?.editor; | |
| let editor; | |
| if (properties[key]) { | |
| editor = properties[key].editor; | |
| } else { | |
| console.warn(`Property "${key}" is not defined in the schema.`); | |
| editor = undefined; // Or assign a default value if appropriate | |
| } | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few notes
| name: "Run Actor", | ||
| description: "Performs an execution of a selected Actor in Apify. [See the documentation](https://docs.apify.com/api/v2#/reference/actors/run-collection/run-actor)", | ||
| version: "0.0.4", | ||
| description: "Performs an execution of a selected actor in Apify. [See the documentation](https://docs.apify.com/api/v2#/reference/actors/run-collection/run-actor)", | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did you changed Actor->actor, it was correct before. It should be Actor.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm ... I'm not sure. I'll change it back
| type: "boolean", | ||
| label: "Run Asynchronously", | ||
| description: "Set to `true` to run the Actor asynchronously", | ||
| description: "Set to `true` to run the actor asynchronously", | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actor
| const summary = this.runAsynchronously | ||
| ? `Successfully started Actor run with ID: ${response.data.id}` | ||
| : `Successfully ran Actor with ID: ${this.actorId}`; | ||
| ? `Successfully started actor run with ID: ${response.data.id}` | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actor
| description: "Where to search for Actors. Valid options are Store and Recently used Actors.", | ||
| options: [ | ||
| { | ||
| label: "Store", | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| label: "Store", | |
| label: "Apify Store Actors", | 
        
          
                components/apify/apify.app.mjs
              
                Outdated
          
        
      | id: value, title, username, name, | ||
| }) => ({ | ||
| label, | ||
| label: `${title} (${username}/${name})`, | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Title is optional, so there can be a case that the title is missing in that case, let's show just the tech name ${username}/${name}
        
          
                components/apify/apify.app.mjs
              
                Outdated
          
        
      | id: value, title, username, name, | ||
| }) => ({ | ||
| label, | ||
| label: `${title} (${username}/${name})`, | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's move to formating label into function to DRY
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
WHY
Improves the run Actor action to align it with other integrations. The new props for the action look like this:

Links to #1, #3 and #9
Changes
title (username/name)(like Zapier)