Skip to content

relax context requirement#674

Merged
dpetran merged 3 commits intomainfrom
task/relax-context-requirement
Nov 14, 2023
Merged

relax context requirement#674
dpetran merged 3 commits intomainfrom
task/relax-context-requirement

Conversation

@dpetran
Copy link
Contributor

@dpetran dpetran commented Nov 14, 2023

Fixes https://github.com/fluree/core/issues/54

Users no longer need to supply the fluree context in their transactions, unless they are wrapping them in a verifiable credential.

First we extract whatever context the user supplied, then we clobber it to expand our
top-level document. We still have to jump through some hoops to remove the fluree
context if it is supplied, but we won't have to do that anymore once we remove the
default context.
@dpetran dpetran requested a review from a team November 14, 2023 17:24
@dpetran dpetran mentioned this pull request Nov 14, 2023
(contains? txn "@context"))
(->> (get txn "@context" (:context txn))
(util/sequential)
(remove #{"https://ns.flur.ee"})))]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what happens if the user also supplies the fluree context?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We remove it. This is the status quo, though, and this commit doesn't change it. Once we properly remove default context this hack will no longer be necessary.

Copy link
Contributor

@zonotope zonotope left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🌵

@dpetran dpetran merged commit 4a3aebd into main Nov 14, 2023
@dpetran dpetran deleted the task/relax-context-requirement branch November 14, 2023 20:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants