Git Product home page Git Product logo

textshredder's Introduction

Our root,
who art in Unix,
hallowed be thy shell.
Thy kernel come.
Thy commands be run
@localhost as they are in iNet.
Give us this day our daily updates,
And forgive us for our four-oh-threes,
as we forgive those who 403 against us.
And lead us not into segfaults,
but deliver us from /dev/null.
For thine is the Kernel, access, and 1337ness,
for ever and ever.
EOF

textshredder's People

Contributors

stil4m avatar wkonecny avatar mitchelkuijpers avatar maikdiepenbroek avatar corne avatar

Stargazers

Martin Kock avatar Harm Berntsen avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar Martin Kock avatar

textshredder's Issues

Client should be able to save files

The client must have the functionality to save files locally. These must not interferer with the consistency of the working copy on the server.
A good option is to make a snapshot, and save it locally or make a kind of repository.

bugs in updating edit colors

  • When you remove everything, client does not update correct
  • When you send an edit on the moment there is a remove edit in your textfield it removes your edit, and cursor position sets to 0
  • When 1 patch has multilpe inserts/deletes it only gives color to the first insert/delete

Connect to unkown host

Enable connect button again after showing error message. Error message shows on error, but user cannot connect again.

Filemanager should have a Server boolean

The Filemanager should store a variable that will store if the filemanager is used for the server or client.
This can be used for the context of closing and opening files.

Performance test locking

There should be a test for how long the lock occurs when synchronizing.
This should be done with small and big files.
Can be done with a unit test or an integration test.

Syncable file should emit 'status'

The syncable file should emit its status when a variable internally changes. The isShared variable or the number of SyncThreads stored in the object.

This status should be 'calculated' and be emitted.

Update Class Commenting & Code Review

A lot of files are lagged in commenting and need code review.

List all files current classes in this issue so they can be ticked off:

FileReviewed
BackupCopy (2011/05/13 12:34) NO
Edit (2011/05/13 12:34) NO

Update Documentation

There has to be done a lot of overdue documentation.

The Class Diagram has to be updated, and maybe cut into manageable pieces.
Interaction diagrams must be made for the importent interactions and button events.

Protocol has to be defined more clearly. For all kind of current packets.

Error checking on connection.

There should be error checking on server starting and the TSConnection to the server/client.
It should handle/notify the user when the internet connection is lost or an error occurs

Expand testing

The testing should be expanded. Currently a lot of classes are not fully tested.
Example: TextShredderPacketParser

Some classes are not tested at all.

A hard class to test is SyncThread. This class could use its own testing app. (2 local connections which sends edits to each other and checks on the performance and correctness of the sync)

Design of mutiple files sync

How are we going to sync mutiple files?
Do we put all data on the same socket and extend/append a header? Or are we going to open multiple sockets?

Somebody has to think about the solution and what impact this has on the structure.

Synchronization Algorithm Bug

Currently there is a bug in the synchronization. Between some connections (sync threads) it happens that two users get out of sync.

Mats: I encountered the fact that the missing data is never received by the receiver. This means it is probably never send. My guess is that the problem occurs by a revert of the working copy or an empty/clear of the EditList object.

Status indicator needs to be updated.

In the list of syncable files there are litle colored rounds after the files. We call this status indicators.
We have the following use cases:

The status indicators have the following states on the server:

  • if a synable file has isShared == false make the indicator grey
  • If the syncthreads.count == 0 (on the server) make the indicator yellow
  • if the syncthreads > 0 make the indicator green.
  • if is syncing show the indicator a little textbox with dots (check the resources).

The status indicators have the following states on the client:

  • if a syncable file is available but you don't sync him make the indicator yellow
  • if you start to sync make the indicator green
  • if a syncable file is edited show a little textbox with dots (check the resources)
  • if a synable file has isShared == false make the indicator grey

Multiple definition of lock/unlock functions

Different classes implement the lock/unlock functions:

  • EditList
  • ShadowCopy
  • WorkingCopy

A 'Lockable' class should be created which implements these functions. All above classes should inherit from this class.

Things that should be done:

  • Code
  • Class Diagram

Logging to a file

We need to be able to log. The logging has the have 2 arguments, a key and the content. Its should log to a file based on the key.

Create a notification system

A notification system (singleton) should be created to simple and effectively show messages to the user. After creating this system, it should be implemented in the application.

Example messages:

  • You have been disconnected from the server as your internet connection has shut down.
  • The server has stopped. You are not syncing the file you are editing with the server anymore.

For more information see:
https://github.com/mitchelkuijpers/TextShredder/wiki/Notification-handling

Reorganize project(s)

The project is currently a bunch of collected files. They need to be separated in different packages.
Unused classes must be deleted.

Difference between opening HTML or Plain Text Files

When opening a Rich Text/HTML file in the TextShredder Editor, the editor should open the file as a Rich Text/HTML file. Currently it opens any file as a plain text file (for example, you can see HTML tags).

Host multiple files on 1 server

Currently a server is started with a file.
This should be changed into 'starting without a file'.
When the server is started, the user can select which files he want to share.

When a client is connected, it should not do a download request directly, but should do a request for all available files. When all available files are received. The client can choose which file he wants to sync.

There is no syncthread to start

Create a syncthread for the program.

This is draft of what has to happen:

  1. received download
  2. dissconnect connection signals from the UI
  3. start syncthread
  4. process incoming changes
  5. send a change every 2 seconds if there are any changes to the workingcopy

Syncable file isOpen variable

Syncable file should have a variable that represents if the file is opened in the GUI.

It should have an open(), close() and isOpened() functions.

Configuration Manager

The same idea as notification manager, a singleton class that can read and write to multiple configuration files.

Save files locally

The users must be able to save files locally. These files are not being synced anymore. Example:

  1. User opens a file from the server
  2. User clicks the save button
  3. A folder browser pops up
  4. User selects a folder to save the file in
  5. User types in a filename
  6. User clicks "Save"

The file is now saved locally.

Domain Model File sharing

There should be a Domain Model for the file sharing. Currently the design choose made is: Each sync will get its own UDP socket.
Shared files should also get a shared state representing if clients are connected.

Logging cleanup.

Logging currently has two issues.

  • The log files will not be removed.
  • The log could have an undefined size. This could result in too much data.
  • A way too easily set the log type for a build (INFO/DEBUG/...), maybe with a macro.

backup/save server file

-save the current server file content when there are no longer syncthreads on the current file
-back up all the server file contents every 5 minutes if it is syncing with clients

SyncThread Destructor ERROR

When destructing a SyncThread the program gets an EXC_BAD_ACCESS exception. See SyncThreadTests::breakDownVariables().

Sync Bug 2.0

When testing the app this morning, Wouter and i found a bug.
Some text was synced multiple times from a server to a client.
Which resulted in lots of duplicated text.

This text is not synced back, this means the shadow copy changed (the representation of the server on the client).

A possible cause of this bug could be:

  • Multilpe edits are send with different version id's;
  • Edits are processed multiple times when they are received (edits have a higher version, or the version on the receiving side is not updated correctly).

No indicator when connecting

If you connect to a server from the mainwindow, you need to disable the buttons and show an indicator that you are connecting.

Design GUI

The goal is to define a rich user interface as soon as possible.
There has to be thought about all components that will be put into the interface. The risk about not doing this is a GUI where all components are cropped in.

  • List all features that have to put into the GUI.
  • Make story board for the application.
  • Review with whole group.
  • Review with product owner (Alice).

Clean up state emit from TSConnection

The TSConnection state emit is a giant mess. Looks a little bit like Corne on the women toilet. UGH. Should be cleaned up for multiple reasons:

  • User Interface should go to main menu if connection ended.
  • Sync's must stop when socket is closed or receives an error. Otherwise the stack will be filled.

Currently there is a really crappy response to errors and socket closing. Should be looked at.

TextShredderConnection Disconnect Signal

Only the signal stateChanged(QAbstractSocket::SocketState) is currently used in TextShredderConnection, even for a disconnect event. The QAbstractSocket emits a signal called disconnected() this signal has to be implemented into TextShredderConnection instead of using if-else statements in the slot where the stateChanged() signal is handled.

User must be able to see edits.

The edits must be shown to the client. This can be done in two ways:

  • Just the edits. With green/red (or something)
  • Edits + a tag with the name of the editor.

End message on synchronization

The Synchronization should have an end message which will be send on ending the SyncThread.
Ending would also result in disconnecting the events from the TSConnection, dropping variables from the EditList and stopping the Timer
When the SyncThread receives an EndMessage is should stop the timer, clear its edits, disconnect the events from the TSConnection and emit to the SyncableFile that synchronization has ended.

The SyncableFile should remove the SyncThread from its list.

TSPacket subclassing

Maybe it is very 'need' to make subclasses of TextShredderPacket.
Example:
AvailableFilesPacket: constructor which takes a QList of QStrings.
This way the definition of the data structure is defined in AvailableFielsPacket and nowhere else.

User should see if edits are processed

When the user is editing a file. He should see when its edits are processed.
This should functionality should use the combination between the WorkingCopy and EditList

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.