justinsantoro / kb-spending-tracker Goto Github PK
View Code? Open in Web Editor NEWspending tracker bot for keybase written in go
spending tracker bot for keybase written in go
I have already made a few mistakes entering in transactions and with no way to edit them I have had to manually run queries from the SQLite shell to balance my account.
I am not sure about the best design for this.
What is needed:
First obvious thought for identifying a specific transaction would just be to use the ID of the txn record in the database. However, that won't scale since in the future we could end up having thousands of transactions, which wouldn't present well on a phone screen.
The better solution is to allow the user to specify a range of transactions they want to see and then present a pseudo id for each txn in that range. This means that the server would then need to map these pseudo id's to the actual txn id's and then wait for the id to be used...which would then mean we need some sort of thread-safe cache?
something to think about:
What happens if a user wants to edit a transaction from a previous month? In order to get an accurate balance we would then need to update each summary transaction through time to the present. I don't think this is a huge deal. Odds are I won't be editing a transaction that's over a year old, so it would realistically be only less than 12 updates. This will probably need to be done via a database transaction though.
Typing on a phone, the keyboard auto corrects the trigger word to be capitalized, causing the command to not be recognized.
add support for multiple tags per transaction
Perhaps I need to add a mutex to the db to ensure only one connection to the database at a time? Particularly important for the monthly balancing since that runs in its own go routine separate from the listen to messages routine
Originally posted by @justinsantoro in #8 (comment)
Break kst_test.go file into mulitple files and only build db tests on !nodb
build flag
start command should be user specific and monthly summary should tally each users balance individually
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.