-
Notifications
You must be signed in to change notification settings - Fork 53
Add name to an existing dataclip #3409
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
base: main
Are you sure you want to change the base?
Conversation
619e77e
to
a49b2f4
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3409 +/- ##
==========================================
+ Coverage 89.99% 90.01% +0.01%
==========================================
Files 368 369 +1
Lines 14408 14436 +28
==========================================
+ Hits 12967 12994 +27
- Misses 1441 1442 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
a49b2f4
to
3611687
Compare
3611687
to
c8e7207
Compare
@taylordowns2000 as always, your feature breaking skills are always appreciated |
@doc-han how do you rate my gpt-assisted React skills? |
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.
Hey @midigofrank , looking great. Started a canvas for the UI. The only big things I can see from a logic perspective are:
- it crashes on duplicates
- the search by name doesn't work
[error] GenServer #PID<0.6943.0> terminating
** (Ecto.ConstraintError) constraint error when attempting to update struct:
* "dataclips_name_project_id_index" (unique_constraint)
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.
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.
UI looks great!
- please add an audit trail event for the creation and removal of a label, then i think we're good
- please add a flash message when a label is added "Label created. Dataclip will be saved permanently."
- please add a flash message when a label is removed "Label deleted. Dataclip will be purged when your retention policy limit is reached."
@taylordowns2000 I've added the audits and flash messages |
* not just prefix for name * update remaining mentions :name_prefix --------- Co-authored-by: Frank Midigo <[email protected]>
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.
This is looking great, but it seems as though the search doesn't return a named dataclip when that named dataclip is the next cron run. In this image, I'd expect "long" to match and it does. I'd also expect "here" to match, but it returns no results.

This isn't likely a big problem, as the next cron run will almost never be named/saved. But it's still strange enough to warrant some investigation. Please see if you can get it to return when searching for the name of the next cron run.
I have run into a situation where if the query is of base 16, like |
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.
@midigofrank , as of the last commit 0edd1a7 I'm seeing this crash when searching for either a name or a UUID:
[error] GenServer #PID<0.874.0> terminating
** (FunctionClauseError) no function clause matching in String.downcase/2
(elixir 1.18.3) lib/string.ex:930: String.downcase(nil, :default)
(lightning 2.13.5) lib/lightning/invocation.ex:884: anonymous fn/2 in Lightning.Invocation.dataclip_matches_filters?/2
(elixir 1.18.3) lib/enum.ex:383: anonymous fn/3 in Enum.all?/2
(elixir 1.18.3) lib/enum.ex:4968: Enumerable.List.reduce/3
(elixir 1.18.3) lib/enum.ex:382: Enum.all?/2
(lightning 2.13.5) lib/lightning/invocation.ex:838: Lightning.Invocation.list_dataclips_with_cron_state/3
(lightning 2.13.5) lib/lightning_web/live/workflow_live/new_manual_run.ex:26: LightningWeb.WorkflowLive.NewManualRun.search_selectable_dataclips/4
(lightning 2.13.5) lib/lightning_web/live/workflow_live/edit.ex:1533: LightningWeb.WorkflowLive.Edit.handle_event/3
(phoenix_live_view 1.0.9) lib/phoenix_live_view/channel.ex:509: anonymous fn/3 in Phoenix.LiveView.Channel.view_handle_event/3
(telemetry 1.3.0) /Users/taylor/OpenFn/lightning/deps/telemetry/src/telemetry.erl:324: :telemetry.span/3
(phoenix_live_view 1.0.9) lib/phoenix_live_view/channel.ex:260: Phoenix.LiveView.Channel.handle_info/2
(stdlib 6.2.2) gen_server.erl:2345: :gen_server.try_handle_info/3
(stdlib 6.2.2) gen_server.erl:2433: :gen_server.handle_msg/6
(stdlib 6.2.2) proc_lib.erl:329: :proc_lib.init_p_do_apply/3
Last message: %Phoenix.Socket.Message{topic: "lv:phx-GFQ4wxZixv9Rfj7B", event: "event", payload: %{"event" => "search-selectable-dataclips", "type" => "hook", "value" => %{"job_id" => "17a6ec8a-5812-4dfd-8a14-82861bbd0921", "limit" => 10, "search_text" => "query=funky"}}, ref: "73", join_ref: "62"}
Description
Closes #311
Validation steps
Log in as a project
editor, admin, owner
Run
and then chooseExisting
on the select box that appearsEnter label
tag
icon. Click on it.Log in as a project viewer
When logged in a viewer, you don't get access to the
input
box for naming a dataclip.Additional notes for the reviewer
x
padding of the buttons to have the fit one line when you open the inspectorEnum.reduce
AI Usage
Please disclose how you've used AI in this work (it's cool, we just want to know!):
You can read more details in our Responsible AI Policy
Pre-submission checklist
:owner
,:admin
,:editor
,:viewer
)