Giter VIP home page Giter VIP logo

tudo's People

Contributors

cachapa avatar vpkopylov 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

Watchers

 avatar  avatar  avatar  avatar  avatar

tudo's Issues

Dockerize web builds

I'm not sure what the standard for web app containers is. I guess it should include a web server and (optional?) certificate handling.

I'm quite happy with Caddy as it handles the certificate stuff transparently, but would be happy with other solutions as well, e.g. nginx.

Allow configuring server url

  1. Show server configuration page on first launch (default to official server)
  2. Allow changing server in settings

Challenge: figure out how to handle auth when changing servers in a running system

Self-hosting feasibility

This app looks great, it's exactly what I've been looking for for a while! How feasible is it at the moment to run a tudo server on my own systems? The two limitations I see right now are:

  1. Not being able to configure the server URL in the app
  2. (non-critical) No docker images available

Is there an interest in making tudo easier to self-host? Are there any other current limitations I've missed? If it is wanted, I could probably contribute the necessary parts for building and releasing docker images for tudo_server (and perhaps for the web build of the client?)

Thank you!

Implement data migration in case of server change

Two options off the top of my head:

  • Allow changing server settings in a running session and allow the data to be synced to the new server - could have unforeseen consequences and may break the CRDT if there are id collisions (e.g. if the user "returns" to the same server).
  • Manual export / import - more effort on the part of the user but guaranteed to work.

If we go the manual export route we still need a better way to reset the app than asking the user to re-install.

Accidental swipe-deletes

I use android's gesture navigation, which includes swiping from the edge of the screen to navigate backwards. Occasionally, I miss and accidentally delete a list item. Luckily there is an undo button, but this is still inconvenient. I think there are a few possible approaches here:

  1. Adding an option to the app that disables swipe-deletes altogether.
  2. Having swipe-delete require an extra confirmation.
  3. Adding a 'deadzone' to the ends of the swipe-delete area, so that it doesn't trigger when you swipe near the edge of the screen.
  4. Using the Gesture Exclusion API - I don't actually know if/how this would work, but it seems like it's relevant here?
  5. Just not missing ;)

Export sqlite_crdt.dart to separate package

Hi @cachapa ,

First, I would like to thank you for a great CRDT example on Flutter, really appreciate the hard work.

Anyway, is there any plan to export sqlite_crdt.dart implementation to a separate dart package in the pub.dev? Personally, I would like to use it on my projects. I will gladly help if there's anything that needs to be done to achieve that, thank you ๐Ÿ™

Linux support

I am running flutter on Fedora 64 bit.
Not sure what I'm doing wrong right now. I had to upgrade the hive dependency as mentioned in the other issue.

  • I run the server. Server runs fine at 0.0.0.0:8080 (Able to see empty map in browser)
  • I run the client. Client UI is fine - no widget errors. But shows the red offline bar at the bottom.
  • I am connecting to wss://0.0.0.0:8080 (changed in config)

However, on printing the error in connection, I see this.

flutter: disconnected: WebSocketChannelException: WebSocketChannelException: HandshakeException: Connection terminated during handshake: #0      new IOWebSocketChannel._withoutSocket.<anonymous closure> (package:web_socket_channel/io.dart:98:24)
#1      _invokeErrorHandler (dart:async/async_error.dart:45:24)
#2      _HandleErrorStream._handleError (dart:async/stream_pipe.dart:272:9)
#3      _ForwardingStreamSubscription._handleError (dart:async/stream_pipe.dart:157:13)
#4      _rootRunBinary (dart:async/zone.dart:1378:47)
#5      _CustomZone.runBinary (dart:async/zone.dart:1272:19)
#6      _CustomZone.runBinaryGuarded (dart:async/zone.dart:1178:7)
#7      _BufferingStreamSubscription._sendError.sendError (dart:async/stream_impl.dart:360:15)
#8      _BufferingStreamSubscription._sendError (dart:async/stream_impl.dart:378:16)
#9      _BufferingStreamSubscription._addError (dart:async/stream_impl.dart:280:7)
#10     _SyncStreamControllerDispatch._sendError (dart:async/stream_controller.dart:737:19)
#11     _StreamController._addError (dart:async/stream_controller.dart:615:7)
#12     _rootRunBinary (dart:async/zone.dart:1378:47)
#13     _CustomZone.runBinary (dart:async/zone.dart:1272:19)
#14     _CustomZone.runBinaryGuarded (dart:async/zone.dart:1178:7)
#15     _BufferingStreamSubscription._sendError.sendError (dart:async/stream_impl.dart:360:15)
#16     _BufferingStreamSubscription._sendError (dart:async/stream_impl.dart:378:16)
#17     _BufferingStreamSubscription._addError (dart:async/stream_impl.dart:280:7)
#18     _SyncStreamControllerDispatch._sendError (dart:async/stream_controller.dart:737:19)
#19     _StreamController._addError (dart:async/stream_controller.dart:615:7)
#20     new Stream.fromFuture.<anonymous closure> (dart:async/stream.dart:166:18)
#21     _rootRunBinary (dart:async/zone.dart:1378:47)
#22     _CustomZone.runBinary (dart:async/zone.dart:1272:19)
#23     _FutureListener.handleError (dart:async/future_impl.dart:169:20)
#24     Future._propagateToListeners.handleError (dart:async/future_impl.dart:719:47)
#25     Future._propagateToListeners (dart:async/future_impl.dart:740:24)
#26     Future._completeError (dart:async/future_impl.dart:550:5)
#27     Future._asyncCompleteError.<anonymous closure> (dart:async/future_impl.dart:606:7)
#28     _rootRun (dart:async/zone.dart:1354:13)
#29     _CustomZone.run (dart:async/zone.dart:1258:19)
#30     _CustomZone.runGuarded (dart:async/zone.dart:1162:7)
#31     _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:1202:23)
#32     _microtaskLoop (dart:async/schedule_microtask.dart:40:21)
#33     _startMicrotaskLoop (dart:async/schedule_microtask.dart:49:5)

Allow recovering sessions

  1. Expose the auth token from an existing session
  2. Allow setting token on first launch
  3. Allow resetting session (dump database, reset to first launch)

Questions about fields

Thank you so much for creating the tudo example. I'm learning a lot from it.

I want to make sure I understand your implementation of CRDT. Please let me know if this correct:

To use CRDT for a generic table, the following fields are added:

  • is_deleted: used for soft deletes
  • node_id: contains the ID of the node creating/modifying the record.
  • hlc: the timestamp for record creation/modification appended with the ID of the mutating node
  • modified: the timestamp for the record entry/update on the current node (not changes to the data), appended with the node ID where the record is being saved

If this is correct, then I have two questions:

  1. Isn't appending the node ID to the modified field redundant since the node writing the record would know its own ID?
  2. Isn't appending the node ID to the hlc entry redundant, since that value will always be equal to the value of the node_id field? Or is it needed for compatibility with earlier versions of the code?

Desktop interface

  • Master/detail interface for large screens
  • Max width on settings page
  • Max width on all bottom sheet interfaces

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.