-
Notifications
You must be signed in to change notification settings - Fork 26
Optional override for Vertex custom job name #208
Conversation
…tHQ#196) Bumps [JamesIves/github-pages-deploy-action](https://github.com/jamesives/github-pages-deploy-action) from 4.4.2 to 4.4.3. - [Release notes](https://github.com/jamesives/github-pages-deploy-action/releases) - [Commits](JamesIves/github-pages-deploy-action@v4.4.2...v4.4.3) --- updated-dependencies: - dependency-name: JamesIves/github-pages-deploy-action dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Alexander Streed <desertaxle@users.noreply.github.com>
* Persist Labels to Vertex AI Custom Job * ensure compatible with GCP requirements * small bug not fetching key-value pairs * Add test, changelog, and format * pre commit hook changes * Feedback for method name --------- Co-authored-by: Alexander Streed <desertaxle@users.noreply.github.com>
@desertaxle Can I get some feedback on this? I believe the failing tests happened when there was a dependency issue of the prefect side, but I am unable to re-run them to verify. |
@jeremy-thomas-roc I think we could use the existing |
@desertaxle that works for me, implemented that change It appears that |
@jeremy-thomas-roc That's true that |
@desertaxle I have made that change, but it appears an unrelated test is failing due to an API error, not sure why that is happening |
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.
Couple of small nits, but otherwise this is good to go!
CHANGELOG.md
Outdated
@@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 | |||
### Added | |||
|
|||
### Changed | |||
- `job_name` in `VertexAICustomJob` is now based on the flow run name instead of the image repository. |
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.
- `job_name` in `VertexAICustomJob` is now based on the flow run name instead of the image repository. | |
- Use flow run name for name of created custom jobs - [#208](https://github.com/PrefectHQ/prefect-gcp/pull/208) |
prefect_gcp/aiplatform.py
Outdated
repo_name = self.name or self.image.split("/")[2] | ||
return f"{repo_name}-{uuid4().hex}" |
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.
repo_name = self.name or self.image.split("/")[2] | |
return f"{repo_name}-{uuid4().hex}" | |
base_name = self.name or self.image.split("/")[2] | |
return f"{base_name}-{uuid4().hex}" |
@desertaxle suggested changes implemented |
Add optional parameter to VertexAICustomJob to name jobs. This helps in monorepo situations where all Vertex jobs will just be {repo-name}-{uuid}, which is not very helpful when running lots of scheduled jobs.
Screenshots
Checklist
pre-commit
checks.pre-commit install && pre-commit run --all
locally for formatting and linting.mkdocs serve
view documentation locally.