Skip to content
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

Release v0.5.0 🎉 #80

Merged
merged 113 commits into from
Feb 9, 2023
Merged

Release v0.5.0 🎉 #80

merged 113 commits into from
Feb 9, 2023

Conversation

nleroy917
Copy link
Member

@nleroy917 nleroy917 commented Jan 11, 2023

New release of pephub 🎉

This will be a complete overhaul of the pephub user interface, as well as a redesign of the API. The pephub server exposes many pages for viewing, navigating, and managing PEPs stored inside. These are supported by the new API which is located at /api/v1/. For a detail discussion of changes see: #73

Added

  • New landing page
  • New namespace page
  • New Project page
  • Ability to edit projects with new project edit page
  • Search functionality

Changed

  • Moved API endpoints behind /api/v1

Removed

  • old views and old endpoint structure

There is so much here to review (61 changed files), it would be quite difficult to review everything. If people feel so inclined, they can review all of the files, otherwise, I thought the following code review designations seemed appropriate:

  • @nsheff can you review the javascript, Jinja templating, and the HTML rendering?
  • @khoroshevskyi can you review the server API endpoints?

If both could pull the code and just test it and mess around to break it, that would also be helpful 😄

@nleroy917
Copy link
Member Author

[ ] Should it be possible to create a new PEP without uploading any files? Like, start from a blank PEP and then just edit it. I would like to create a new PEP from scratch.

I agree. Maybe when we port to react 😎

@nleroy917
Copy link
Member Author

  • search is not working for the latest items added to the database. How is the vector search database being updated? Is this automated?

There is nothing set up. It is trivial to embed ~10,000 PEPS (takes about a minute). I've developed pepembed to accomplish just this. However a github action should be setup to run the embedding/indexing on a set schedule or some sort of update queue needs to be implemented. I.e. a column in the database with a boolean flag indicating the PEP should be indexed and again, a github action cronjob runs to index only those PEPs. Either way. Does @khoroshevskyi want to implement such a system?

@nleroy917
Copy link
Member Author

nleroy917 commented Feb 2, 2023

I think fetching projects within a namespace should be at /projects?namespace=, rather than /namespaces//projects. I would also put it under the projects.py router, since that's what it returns. This is more in line with viewing endpoints as describing objects that are returned.

I emulated this after the GitHub API architecture. And here is another example. Dockerhub does something similar. Spotify does something similar with album tracks. They all follow this /entity/{id}/data-inside-entity paradigm.

similarly for the Create a project endpoint; I'd expect it to be at /project; you'd specify the namespace in the body payload rather than in the URL

Same as above, I just emulated the GitHub API setup.

Would it be more clear to have a /sample or /samples endpoint for retrieving/creating samples? Rather than putting all this under the /project endpoint.

Maybe. I'd like to discuss in the context of comments I made above re: other endpoints.

Instead of /convert, should we do /project?format=X or /project?convert=X? It's generally recommended that endpoint names be nouns, if possible. I guess I'm OK with verbs too, but here the noun seems to make sense to me.

> The config_load.py role is not clear to me, and why is there a JWT_SECRET with an empty string there?
> cli_auth_system.py is an empty file -- ?

These are remnants of the pephubclient cli rafal was making. I am not sure of their significance.

@nleroy917
Copy link
Member Author

nleroy917 commented Feb 3, 2023

@nsheff @khoroshevskyi Okay - I've addressed many things with some small tweaks. Things that linger that I feel warrant a discussion:

  1. Indexing latest items added to the database - infrastructure for this. Can be a simple GitHub action. I believe this should live inside the pephub repository, but I have a pull request open on pepembed that highlights how it might work
  2. Final logging output tweaks - @khoroshevskyi can you do this?
    3. API structure. It seems like there should be a discussion on the actual structure of the API at several places.
    4. cli auth system files left over
  3. Need a /config endpoint for the projects
  4. /projects/{namespace}/{projectname}?convert=basic to add conversion formats for the project
  5. Are private peps showing up in search results.

Notes

  • Keep pepmbed private for now and then run workflow there - until we publish this. In long term, move to pephub.data.org repo.
  • What about yielding the connection, seems like a hack (create an issue inside pephub to track this)
  • Web validator? Follow up with Alip.

@nleroy917
Copy link
Member Author

nleroy917 commented Feb 7, 2023

- Lets just punt logging to the next iteration.
- Fix versions in footer

@nleroy917
Copy link
Member Author

Im having issues connecting to qdrant inside docker, so I'm waiting for their devs to help me out. but I will merge this soon.

@nsheff
Copy link
Contributor

nsheff commented Feb 8, 2023

Are @aliparslan 's changes in?

@nleroy917
Copy link
Member Author

So far just his changes to eido since the reqs are pointing at the dev_alip branch of eido

@nleroy917 nleroy917 merged commit c75cf76 into master Feb 9, 2023
This was referenced Feb 14, 2023
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.

4 participants