CenterForDigitalHumanities / TPEN-services

Services required by TPEN interfaces in order to interact with data
1 stars 0 forks source link

User class #106

Closed jsvoo closed 3 months ago

jsvoo commented 4 months ago

Added user class, tests, and object modifying utilities. Some of the things I need feedback on include

cubap commented 4 months ago

The 'mongo' designation is probably going to be refactored in the future to something like "local" or "private" so it is appropriate to have in here.

cubap commented 4 months ago

Ids can be tricky.

_id is the mongoDB default and I think for all private data it is sufficient. id and @id are used in RERUM and always refer to a full URL for the JSON object. The end of the @id is the hexString from the _id in the MongoDB RERUM uses, but you can also use a slug to refer to an object and then the hexString is preempted by the __rerum.slug String.

thehabes commented 4 months ago

Noting that there are couple failing tests related to the /user endpoint when doing npm run allTests

image

thehabes commented 4 months ago

This has been merged into the reserveId branch, but we are leaving it open until we are sure everything is merged together correctly.