Add url calculation to attachment resource - #12
Conversation
|
Also, small nitpick I noticed: all calculations define an |
|
Down to remove the unnecessary callbacks. Was using them at some point and removed the check w/o removing the callback. |
1 similar comment
|
Down to remove the unnecessary callbacks. Was using them at some point and removed the check w/o removing the callback. |
Done! |
a44a8f9 to
6963385
Compare
|
I'm working through the CI issues. |
84c39ec to
821e2fc
Compare
|
I'm having a very hard time understanding what is wrong with CI. |
821e2fc to
7d6e4d1
Compare
|
🚀 Thank you for your contribution! 🚀 (we just need to use |
|
Oh, I could have made that change before you merged! AI actually suggested exactly this change but I wasn't sure about it 😅 |
|
It's all good, was easy enough to update! I was excited to get this in 😆 |
Contributor checklist
Leave anything that you believe does not apply unchecked.
First off, sorry @StephanH90 if you were planning on doing this, I just wanted this ASAP so I put this together. If you have WIP you were hoping to PR, I'm happy to close this in favour of anything you've done (not a loss for me as I learned a thing or two!)
Adds
urldirectly to the attachment resource as per #5.Design Trade-off
This implementation threads the parent resource through the calculation in order to get the
base_url. Alternatively, we could store thebase_urlinAshStorage.Service.Disk.service_opts_fieldshowever this would be a breaking change. Note that it would only be breaking for users who would want to use this new functionality and in order to do so, would need to back-fill.Basically this:
I want to note that I use AI heavily to produce these changes. I spent around 1.5 hours on this PR going back and forth with Calude Code, gaining a decent grasp of what is going on but I cannot say that I yet have a deep understanding of the inner workings of ash_storage (having built things like this before I have a very good high level understanding I'm just talking more Ash stuff, like Spark).
I have also tried this out in my current project and all seems good there.