Comments (12)
I have Paper Trail setup for the workflow and project content models, but as I looked into starting work on #122 I don't think it's the best solution.
Since these are just going to be json blob, it seems like it work make more sense to just create a Versions model and store the entire old json blob in it along with a timestamp and a reference to the old resource.
We'd expose these as a nested version endpoint under the main resource endpoint, so /project_contents/1/versions
, /subjects/2/versions
, /workflow_contents/2/versions
. @brian-c let me know if you don't think we should break the previous flat api for versioning. To me the above routes make more sense than /project_content_versions?project_content_id=1
, but it doesn't matter too much to me.
from panoptes.
Looks good to me. They'll be listed in the top-level links anyway, right?
from panoptes.
Yes.
from panoptes.
This sounds fine if we're just showing old versions. If we want the funky diffs / restore functionality we can get this for free with paper trail (not saying we can't make it but this gem is pretty stable for this).
from panoptes.
That's fair. I think it should be pretty simple to a basic diff a json object client-side, I wasn't sure if how paper trail's diff interact with json field (or the jsonb fields when we can move to them) in postgres. I thought it did a diff at the model attribute level as opposed to to within the values of the attributes.
from panoptes.
Is this truly truly a concern for version 1?
Is there anywhere on the front end you're planning on exposing it? I imagine it's a footnote in the reduction.
from panoptes.
I think it'd be around and exposed for doing translations since that's what we do now. I'd prefer not to take a step back in terms of supporting other languages.
from panoptes.
@aliburchard - thoughts?
from panoptes.
Best to extract the paper trail / custom versioning to it's own issue. This issue will depend on that funcationatliy though.
from panoptes.
Opened #188
from panoptes.
I'm not totally sure I follow, but I can see two types of use cases for tracking updated metadata.
-
Workflow depends on subject metadata. Say the decision tree options or tasks depend on subject location or time of day. Science team might upload subjects with certain metadata, then realize that they have made some mistake that they failed to catch before launching. I'm not sure what fixing that looks like -- either updating metadata for certain subject IDs or essentially deleting those subjects and re-uploading them.
-
Workflow doesn't depend on subject metadata, but metadata is displayed on the interface and publicly available for other science teams (which is an eventual outcome we've bounced around). In this case, updating metadata isn't critical to the app producing useable data, but tracking those changes and displaying updated metadata would improve the user experience (if it's displayed) and ensure that the data being made publicly available is the "correct" data.
from panoptes.
and, @brian-c @camallen, I do think it's important that metadata be incorporated into version 1. I think that not building in some sort of metadata handling and tracking will limit the types of projects that can use panoptes. For example, even though the Snapshot Serengeti interface doesn't ask different questions based on the subject metadata, images are grouped and presented in those groups based on metadata...
from panoptes.
Related Issues (20)
- "/queued" endpoint seems to ignore ?subject_set_id, for certain workflows
- /grouped endpoint doesn't accept ?admin parameter
- Subjects endpoint returns duplicate subjects and misses others HOT 1
- Language Preference: Implementing Translations in FEM HOT 1
- Character limit on usernames
- Subject set completeness counters not updating HOT 1
- Sequential subject selection advancing the subject by 10 when requesting subjects HOT 7
- where-is-spoony question HOT 1
- science-scribbler-key2cat tutorial HOT 1
- Subject Set Exports: CSV Filename Incomplete
- Updates to Subjects error when update params do not contain metadata
- Orphaned media rows created by subject location update HOT 1
- Project Builder: Workflow Steps cannot be updated HOT 1
- Rails 6 Task: Deprecation Warning: Initialization autoloaded constants
- Rails 6 Upgrade Task: DEPRECATION WARNING: Content-Type header without modification (json_api_render, api_response) HOT 3
- Rails 6 Upgrade Task: Deprecation Warning: Rails 6.1 will return Content-Type header without modification. (home_controller, workflows_dump_worker)
- Workflow get request returns unexpected workflow after unlinking subject set from workflow HOT 6
- Restrict SVG uploads HOT 2
- Issue with Pulling User Groups GET `/user_groups` endpoint HOT 2
- Allow admins to update user project preferences HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from panoptes.