Coder Social home page Coder Social logo

mtbarta / monocorpus Goto Github PK

View Code? Open in Web Editor NEW
232.0 232.0 13.0 9.25 MB

A notepad for software and machine learning

License: GNU Affero General Public License v3.0

Shell 2.18% Makefile 2.23% JavaScript 18.39% HTML 0.23% Vue 25.93% TypeScript 16.15% CSS 6.11% Go 24.33% Dockerfile 4.44%
developer-tools machine-learning note-taking

monocorpus's People

Contributors

mtbarta avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

monocorpus's Issues

Katex rendering is duplicated

A note should only show the katex rendering, but shows the raw and rendered versions next to each other.

Additionally, the rendering doesn't seem correct.

Tokens expire without refreshing

The gateway has basic functionality for extracting data from a bearer token, but has no logic for dealing with expired tokens. Given an expired token, the gateway will reject the call.

This becomes annoying for the user, since the only way to fix this currently is to login again. The frontend should be updating the token, although this may not be working as intended.

A more robust solution to explore is to use keycloak's proxy service in between traefik and the gateway. This would allow better token handling and a way to have a dev environment without authentication. The downside is that this is adding another hop to every request.

Frontend - pass env variables

The production build of the frontend overwrites process.env in the webpack config.

This has been extraordinarily limiting for configuration from docker.

A user should be able to pass in environment variables from docker to the frontend.

Notebook doesn't update

When a user is under a title Filter, switching to the notebook page should show all notes.

I assume because we are not updating our graphQL cache, the queries are not aware of new data to show.

This is also an issue for showing note titles in the menu.

Improve Search

Search doesn't seem to work, and it's not clear to the user why.

  1. add more error handling so the user knows search is broken.
  2. consider adding a queue for search events in the backend. The implementation here can be improved.

Feature: Shareable Notes

What's missing from the design is the ability to share notes.

What is happening currently

MonoCorpus is meant to share information. The way the web UI works right now, the notes are private. A user can only see their own notes.

What I would like to do is assign permissions per note and project and allow a URL structure to find them.

linik structures
A link structure like monocorpus.com/mtbarta/<project>/<noteid> would be capable of leaking information, but is more informative and composable. I would need to be concerned about the http error returned when a link is missing and when a link exists but the user doesn't have access. The benefit of this method is that the permissions could be looked up during note retrieval, and we'd only require a new collection for project-level permissions.

I could also use something like monocorpus.com/mtbarta/<dbID> where the dbId is an ID to the permissions. The db would need to store permissions for all objects. This method would always require a network hit to find the permissions.

Either way, it looks like attribute-based authorization makes sense here, although i need to explore other options more.

Add Tags

A user should be able to add tags to their notes.

It's been suggested from reddit to use entity based labels. I would also wonder if we can use a hierarchical structure in an effective way.

  • Each note will need a way to add tags to it.
  • The sidebar should display a tag menu.
  • Search results should take tags into account.

mongo deleted - docker-compose up fails

Describe the bug
When running docker-compose, docker complains that the mongo image is deleted and halts.

To Reproduce
Steps to reproduce the behavior:

  1. sudo docker-compose up -d

Expected behavior
All monocorpus containers get started.

Screenshots

> sudo docker login
Authenticating with existing credentials...
WARNING! Your password will be stored unencrypted in /home/rawland/.docker/config.json.
Configure a credential helper to remove this warning. See
https://docs.docker.com/engine/reference/commandline/login/#credentials-store

Login Succeeded
0> sudo docker-compose up -d
Pulling mongo (monocorpus/mongo:3.6.2-jessie)...
ERROR: The image for the service you're trying to recreate has been removed. If you continue, volume data could be lost. Consider backing up your data before continuing.

Continue with the new image? [yN]y
Pulling mongo (monocorpus/mongo:3.6.2-jessie)...
ERROR: pull access denied for monocorpus/mongo, repository does not exist or may require 'docker login'

Desktop (please complete the following information):

  • OS: Ubuntu bionic

Add Dashboard Features

A user should be able to login to a dashboard.

The app logs users in to a blank homepage, and a user is expected to navigate to the notebook.

I would like to explore ideas for what could live on a homepage.

Frontend - NoteMenu incorrectly highlights titles

I expect that the NoteMenu would highlight the current filtered title in the primary color. This behavior is set in the vuetify element.

What I'm seeing is that every title gets highlighted. This is probably related to the NoteMenu's native click behavior function that was added to change the title filter in vuex.

So, theoretically a solution to this problem is using an event handler object as mentioned in #14

Notebook UI is not responsive

A user should be able to take notes in a smaller window, even mobile.

I've mostly relied on vuetify to style elements appropriately. It looks like the layout is 500-some pixels, and the noteList data span is 800-some.

Frontend - GraphQL note query does not update the cache.

Apollo's graphql client can provide an updateQuery mapping to update the cache before receiving a response from the server. This behavior was removed at one point because of a conflict with fetching older notes within the notebook.

This behavior should be used since we know the basic structure of a note.

Notes - Add Tests

The notes microservice is a basic CRUD app right now. I would like to make this bulletproof.

Tests should validate that queries are validated appropriately, that user data cannot be leaked, and that errors are handled gracefully.

Manage Dependencies with Glide

In the past I used dep to vendor in each microservice. Dep itself suggests it's not suited to a monorepo environment. Helm is a good example of a repo using glide that I would like to mimic.

Notebook throws DOMException

it is possible to throw a DOMException if not careful.

DOMException: Failed to execute 'setAttribute' on 'Element': ',' is not a valid attribute name.

This prevents notes from showing up on the notebook and the progress bar never goes away.

There should be better user data sanitizing as well as error handling in the notebook to prevent this from happening.

Frontend - refactor

I'm in the process of adding unit tests. This doesn't, however, help the fact that the code is a mess.

  • I need to make a lot of note functionality into mixins. I can't really think of a great way to solve my inheritance issue otherwise.

  • GraphQL statements are in their own folders for the notebook, but not for the note menu queries.

  • get around the NoteWrapper abstraction?

  • Flatten out the notebook directory

  • Add tslint and rewrite components into TS

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.