Activity

eee

final devlog!!

  • last devlog before shipping
  • nothing new just been testing everything to make sure it all works as expected
  • will be shipped later today

changelog

  • docs(main): bump version (5018ff1)
  • docs(main): update readme (a854b56)
Attachment
0
eee

lantern devlog - 17/03/26

  • lots of debugging since the last devlog since i want to ship this soon
  • managed to identify a few weakpoints in the code which are now resolved:
  • passwords are all hashed locally before being sent to server - this will mean that users will need to re-register if they’re already signed up (easiest fix is to just delete the users.json file in db so u can preserve message data)
  • the help menu now pulls all of its data from the command registry just like the autocomplete system does
  • silenced all the opencv output so it doesnt disrupt the tui and added some more error handling
  • the username checks now check for allowed characters rather than banned ones since there are way more banned chars than allowed
  • removed keybinds from help menu and made a dedicated /keybinds command
  • rewrote the readme so its more coherent :)

changelog (most arent pushed yet lol)

  • fix(main): fixes + silence cv2 error output (71222d5)
  • docs(main): update readme - will ship soon :) (edb62f7)
Attachment
0
eee

lantern devlog - 15/03/26

  • new /reload command (admin only) - this command essentially reloads all server config meaning you dont have to restart server every time you edit config eg to add a user as admin etc.
  • full restructure of the server net code
    –> moved it across multiple files like I did previously for the client code, was just getting way too clunky and long. i also tightened up some of the logic and decided to use camel case for all my functions in the new net code because its just superior lol.
  • fixed a few other bugs with the server network alongside that refactor including some more patches to hopefully finally fix that phantom leave msg bug.
  • added a --version or -v flag to the server (lantern-server) so you can quickly check what version of the code you have installed (will add to client cli later today).
  • version has been bumped to 1.4.8 :)

changelog

  • feat(client): begin implementation of /reload cmd (admin) (8a75790)
  • feat(server): /reload cmd server side changes (a727e84)
  • refactor(server): some of server net refactor (0446d1b)
  • refactor(server): refactor server network logic - camelcase for the win (553b08f)
  • docs(pkg): bump version (76876ff)
Attachment
0
eee

lantern v1.4.7

whats new????

  • Unread DMs indicator - shows on status bar, by each respective user on the user list and on the dm panel.
  • The unread dms counter is managed completely server side so any dms sent to you whilst offline will still trigger an update in the unread dms indicator when u launch lantern (this was a pain to implement).
  • Opening a conversation automatically marks those messages as read and clears indicator for that user.
  • More server config!! - control ratelimits, login timeout etc all from the config file
  • Login ratelimit - server configured rate limit for login attempts to reduce spam and prevent brute force attacks
  • /purge command to remove the last n messages from chat
  • /snap command - takes photo directly from your camera and sends to the active chat (initial implementation courtesy of dennis.
  • Refactored the command system - adding commands is now so much easier and faster.
  • Client saves state upon quit - if you were viewing DMs with a user or turned DnD off - when opening the client, you will be back in dms with that user with DnD still off!!

bug fixes

  • Fixed the phantom user left messages that appeared randomly ( i really hope its fixed lol )
  • Config file (server, port, dnd settings) no longer gets overwritten when saving
    UI state - persistent config is now kept separate from ephemeral session state.
  • Image filenames now sent alongside image data for proper rendering.
  • Usernames and message content sanitized for system notifications to prevent
    osascript/notify-send errors.
  • Session tokens invalidated on user disconnect.
0
eee

lantern devlog - 13/03/26

whats new???

  • /purge command - admin only - removes the last n messages from the main chat, this has been needed for a long time..
  • i refactored the command system for the client, all the code is much cleaner and adding new commands is so much simpler - this’ll also make contribution from anyone else easier in regards to commands.
  • login ratelimits - there is a limit (currently 5) to how mainy failed login attempts a user can have before being temp locked out of their acc - previously, it wouldve been really easy to bruteforce the login form.
  • any images sent now also show the sender name upon client reload (although images are not stored on db, only for the session they are sent since this would require way too much storage).

changelog

  • fix(main): send user alongside image name (8e130fc)
  • refactor(client): new cmd system - better logic and just way nicer (402c6c5)
  • feat(main): /purge cmd to remove last n msgs (d79adab)
  • feat(server): login ratelimits (234996f)
  • docs(main): bump version to 1.3.7 (bbea3fa)
Attachment
0
eee

What’s new????

  • /snap command which takes a picture from your webcam/laptop camera and sends it to the active chat.
  • this command is more of a joke tbh but its pretty fun to use lol
  • also updated the readme to specify the supported platforms

Bug fixes

  • fixed the disappearing messages logic - previously, if a user ran the command, it would cause the most recent message to be redacted - which in some cases would not be the correct message to be redacted, I fixed this logic after realising how bad of an implementation this was lmao

changelog

  • docs(main): add cry for help in readme (e9f2314)
  • Added /snap to take photos and send them (002e94f)
  • Merge pull request #4 from dennisupton/main (5faac06)
  • docs(main): bump version (3575609)
  • feat(main): error handling to /snap (7ec9b16)
  • fix(main): fix disp messages bug (644cf65)
Attachment
0
eee

What’s new???

Mostly just a few smaller features :)

  • Reconnect with backoff - client will automatically attempt to reconnect to the server upon disconnect (up to 5 attempts).
  • Unread DM indicators - unread counter shone in the user list, DM panel and status bar.
  • Pressing up arrow will grab previous messages just like the rerminal
  • The DM panel now shows all registered users not just online or previously dmed
  • /rename allows for the renaming of user acccounts - changed from /changeusername.

Bug fixes

  • /disp correctly redacts in main chat regardless of state of client.
  • /disp command shows a “not supported in DMs message” if ran in DMs instead of sending the message to the main chat lmao
  • Session tokens invalidated on user disconnect
  • Sanitised usernames and message content passed to osascript / notify-send

Installation / Setup

No real changes, just reinstall with pip or pipx.

pip install --upgrade lantern-chat

If you encounter any issues or bugs, please submit an issue (or a PR).

changelog

  • feat(main): up arrow places your previous message in the text box (like terminal), also added better message handling cos tuples were getting really messy (51a1ba3)
  • fix(main): fix mouse scrolling (5a49ffe)
  • feat(main): unread msgs counter, refactor net code so its nicer (e4ee49e)
  • fix(main): disp disabled in dms cos i cba to fi the bug (b06a72a)
  • fix(main): fix disp messages in main chat (80e6ba1)
Attachment
Attachment
0
eee

lantern devlog - 10/03/26

  • no major additions today. honestly spent a fair bit of time actually using the chat client lol.
  • up arrow key now cycles through previous messages like ur terminal
Attachment
1

Comments

YourLocalSatyrFlip

Brings back memories!

eee

What’s new??

  • Full image support (well kinda)
  • All images are converted to ascii for easy rendering (since curses doesn’t support actual image rendering and neither do most terminals).
  • Images are only saved for that given session, mainly because otherwise upon client reload, the server is forced to send a ton of data/chunks all in one go and so the client takes ages to launch. Also, I would prefer to not be storing everyone’s random images on my server…
  • Images can picked from a file picker, accessible through the /img command.
  • You can also paste images simply by copying one to your clipboard and hitting Ctrl+V –> this currently only works on Linux and MacOS, i have not managed to implement this on Windows.

Installation

pip install --upgrade lantern-chat

Some users may encounter an error message asking them to create a virtual env, the easiest way to get around this (other than creating a venv) is to install the package with pipx - this will place the binaries for lantern and lantern-server in the ~/.local/bin directory so make sure that is in your PATH.

Usage

  • No significant changes to the usage of the client.
  • To send images run /img to open the file picker or simply paste an image into the chat with CTRL + V.
Attachment
1

Comments

Rez
Rez 8 days ago

holy frwic this is cool!

eee

txtr devlog - 08/03/26

syntax highlighting!!
was a pretty simple implementation but its there now. still working on fixing a few things like highlighting \ commands whilst inside math mode $$.

other than that, not much to really talk about lol.

changelog

  • docs(main): update readme (09ceccf)
  • feat(main): basic syntax highlighting for latex (WIP) (91dea07)
Attachment
0
eee

lantern devlog - 08/03/26

  • doing some really cool stuff today
    –> disappearing messages!!
    • New /disp <seconds> <message> command — sends a message that redacts itself
      after the given time
    • Redaction is server-side: [bob]: hello world becomes [bob]: ***** *****
      for all clients — cannot be bypassed by a modified client
    • Word shape is preserved (* per character, spaces maintained)
    • Disappearing messages are never written to history, so they don’t reappear on
      reconnect

And I have also been working on image support - by converting images to ascii. Currently, I’ve finished the image conversion logic and I am currently working on creating a menu that acts as a file picker and then will move onto the networking.

changelog

  • docs(main): update readme to match new pip package build (bf3af21)
  • feat(main): disappearing messages!! also rebound show keybinds menu keybind and some other small changes (444f918)
  • docs(main): v1.1.2 (be6e1cb)
0
eee

txtr devlog - 07/03/26

finished the command mode logic and integrated it into the status bar. Commands can also be used simultaneously ie “wq” saves and quits.
this now allows for the running of commands like

  • w - save
  • q - quit
    etc
    This means that txtr can be used as an actual text editor now.
    nearly finished with syntax highlighting too

changelog

  • feat(ui): finish the basic text editor (7e4057d)
  • feat(ui): add status bar and command modre (12c9573)
Attachment
0
eee

lantern devlog - 07/03/26

big news!

lantern is now available as a pip package on PYPI. Install it with:

pip install lantern-chat

This provides two commands - lantern and lanten-server. lanten allows you to run the client and of course lantern-server allows you to run the server. All configs are stored in ~/.config/lantern. :)

If prefer to build from source or install it via a wheel file then check out the releases below:
https://github.com/benjibrown/lantern/releases/tag/v1.0.0

changelog

  • feat(main): pip package release (833b70f)
  • docs(main): new readme (e237392)
  • docs(main): readme img fix (again smh) (0f31415)
  • docs(main): add badge to readme (688abcb)
Attachment
0
eee

lantern devlog - 06/03/26

lots of debugging and also some additional features:

  • server side message ratelimiting
    –> the ratelimit can be set in the server configuration files and prevents spam. it honestly took a while to get this to work with the fetch cooldown command but its all sorted now :) (as fetch sends data as numerous messages).
  • /dm command now validates the user actually exists before opening a dm panel with that user and also detects offline users.
  • the dm panel (ctrl + p) - shows only prev dmed users or online users to prevent clutter
  • the server now has a –port argument so you can easily change the port the server listens on
  • message timestamps with each message!!
  • i have also made it so that dnd is on by default and i am currently working on making this an installable package so the program can be ran with “lantern” or “lantern-server”.

TODO:

  • refactor dm panel
  • port in server config file
  • custom fetch cooldown

changelog

  • feat(main): server side message ratelimiting (f025d56)
  • fix(main): fix /dm command not detecting offline users (511a81c)
  • feat(main): –port arg on server (84624fa)
  • feat(main): message timestamps!! (ceb9441)
  • fix(server) fetch not caught by ratelimit (36c43cd)
Attachment
Attachment
Attachment
0
eee

txtr devlog - 05/03/26

finally have an actual text editor (although file saving isnt quite there yet lol)
finished off the editor and statusbar widgets today. visual mode selection highlighting landed in editor.py, then the rest of the editor rendering got polished up gutter, cursor, cursorline, the works. statusbar is now complete with the mode pill, filename, modified dot and cursor position. also started a theme config file (colors.toml) so colours can eventually be swapped out without touching code -c atppuccin mocha as the default for now.

changelog

  • chore(main): update .gitignore to hide pycache folder in texitor dir (e65266d)
  • feat(ui): editor.py - highlighting text when in visual mode (b98ada5)
  • feat(config): add theme config file (WIP) (059141a)
  • feat(ui): finish the basic text editor (7e4057d)
Attachment
Attachment
0
eee

txtr devlog - 04/03/26

  • wrapped up the core keybind logic and fixed a few bugs that crept in from earlier stuff i did with the buffer/modes.
  • also moved onto the ui layer properly - got the full key dispatch and all normal mode action handlers done and into app.py (yank, del, paste, undo/redo, visual selection, replace char, indent etc) - will be adding indent indicators soon (those lil lines).
  • built out the main editor widget with line gutter, cursor block, cursorline highlight and visual selection rendering in both char and line-wise modes.
  • statusbar is getting there too, added mode pill, filename with modified indicator and cursor pos.

changelog

  • feat(core): keybinds logic finished (dd360d8)
  • style(main): update main program file (9f31346)
  • feat(ui): add action handlers and key dispatch (028f2af)
  • feat(ui): statusbar base variables/definitions (4da4c40)
  • docs(ui): statusbar additions (1011f05)
  • feat(ui): nearly done with gutter for editor logic (1cf2bcd)
Attachment
0
eee
  • Mostly sorted all of the key handling logic for the text editor
    –> the biggest thing was figuring out how to capture commands that are multiple commands ie g g etc

(no meaningfuk code output rn so im just putting an ss of code)

Changelog

  • other(main): remove random files (4282bb3)
  • feat(ui): key handling logic in app.py (91f6920)
Attachment
0
eee

txtr - first decent bit of progress

its official, the spaghetti code of my classes and functions has now become organised spaghetti

  • updated the main file so txtr actually does something when called (although still no ui yet)

  • finished the modes logic:

  • INSERT - text goes into the buffer (where you actually edit files as you would normally)

  • NORMAL - default mode, each keypress is a command

  • VISUAL - selection of characters

  • VISUAL LINE - same as visual but line by line

  • COMMAND (WIP) - the : command prompt, hardly ready yet.

  • Also added some vim inspired keybinds (heavily inspired as this is a vim-style editor and its what im used to)

  • The basic things include:
    gg and G - jump to start/end
    u/ctrl r - undo/redo
    and a lot more, theyre all in the repo :)

  • Also cleaned up some buffer code and fixed a little bit of logic :)
    (and i managed to make it actually install as a pip package this time)

Changelog

  • feat(core): open files that havent yet been made (a39216a)
  • chore(core): edit some stuff in buffer, add waffle to the comments lol (392e58b)
  • did i even change anything? (48102fc)
  • feat(core): add some keybinds (3337575)
  • feat(core): finish off modes logic (d2646ad)
  • feat(ui): add texitor app base - the main class for pulling together all of my spaghetti code (7385245)
Attachment
0
eee

the buffer is pretty much sorted, the main logic for deletions, undo/redo (i love stacks), file writing/opening etc is done.

  • havent done any of the frontend work yet but need to sort out all the modes (insert, visual and normal) beforehand.
  • will be using textual as my tui package for this project because curses truly is cursed.
  • also added a main.py file for testing purposes and to check the pyproject logic is correct and i can actualy install it as a pip package, so far, so good.

Changelog

  • feat(core): add buffer — lines, cursor, undo/redo, file i / o (c5d3033)
  • feat(core): add main.py for pyproject + pip package (6bb3c27)
Attachment
0
eee

New project!! (lantern is still going dw)

  • This is my first devlog for txtr (aka texitor).

  • txtr/texitor will be a Vim-style text editor, specifically designed for incredibly fast LaTeX typesetting or in more simple terms, writing cool math equations way faster than you could hand write them :)

  • So far, I have created the initial structure of the project, created a pyproject.toml file for the pip package that this will eventually be distributed as and also have begun to code some core logic such as the buffer and modes (insert, visual, normal etc).

Changelog

  • refactor(main): initial commit (b04035c)
  • fix(core): use setuptools.build_meta for broader compatibility (df0b76f)
  • docs(main): update .gitignore to ignore egg dir for texitor (c3fe1b6)

(no code output yet so heres a ss of the repo lol)

Attachment
0
eee

Couple things added, mostly just been testing the client.

  • /clear command clears current main chat buffer
  • fixed notifications breaking due to \ causing notify-send to get angry (strip message data of \ for notification preview)
  • temp removal of ctrl + h to open help menu - for some reason, on another device, backspace opens the help menu not ctrl h ???

Changelog

  • chore(base): add comment lol (86fa8ce)
  • fix(base): fix help keybind, temp removal (11e18b8)
  • fix(base): notifications fix (267aba9)
  • perf(main): dm notifications back (a5af163)
  • feat(main): /clear command (501e70a)
  • change default server cooldown (b533c19)
  • fix(main): duplicated colon on server log (a1e7a4e)
  • refactor(main): remove unnecessary shebangs (daaa75b)
0
eee
  • Finished TCP stuff –> frames.py and some updates in the server and client network code.
  • Added an unban command, much needed.
  • Hopefully disappearing messages bug is fixed - haven’t been able to replicate yet.

Changelog

  • temp remove notis, notify-send throws error (cf8b2b9)
  • temp remove notis, notify-send throws error, tcp fix (091b46f)
  • added a few bugs (fe9d2b6)
  • add tcp (udp is so bad), unban command (a66c64e)
Attachment
Attachment
0
eee

Update

  • I’ve been working on the transition from UDP to TCP but I thought it might be helpful to outline the bugs that are making this massive change worthwhile:

Bug 1 — Chunked history packet loss

Channel history is sent as a series of chunks when you join:

[CHANNEL_HISTORY]|0|<chunk>
[CHANNEL_HISTORY]|1|<chunk>
[CHANNEL_HISTORY]|2|<chunk>
[CHANNEL_HISTORY_END]

The client reassembles these by index into a buffer then JSON parses the whole thing. If UDP drops a single chunk (or [CHANNEL_HISTORY_END] itself arrives before a chunk due to reordering), you get either empty slots in the buffer or json.loads() fails on malformed data. Either way it silently falls into an exceptblock that just sets authenticated = True` and moves on. Hence, no messages load.

Bug 2 — DM history truncated

[DM_HISTORY] was sent as one big UDP packet. Both sides called recvfrom(4096) — 4096 bytes is the buffer size. A DM conversation with any meaningful history easily exceeds that. The packet gets truncated, JSON parse fails, empty conversation. Same exact thing lol.

  • I’m currently researching some information about using TCP with the socket library in python to make sure i dont make any more bad implementations lol.
  • I plan to have the TCP finished by the end of this week and then I’ll move on to refining everything and if thats all working perfectly perhaps I will take the giant leap and explore the possibility of sending images via the client (these won’t be rendered in your terminal directly but you will be able to open them with your local file viewer with a command).

Changelog (minimal changes so far , most of my time has been debugging)

  • frame stuff should be done (b1c01b9)
  • import intop server net (0062652)
Attachment
0
eee

The past hour I’ve worked on lantern I haven’t actually written much new code.
My main aim has been testing the program over a different network (not my home) and across multiple devices.
This has allowed me to find numerous bugs which I will be working on in future to resolve.

Known Bugs

  • Messages fail to load on occasion when launching client

–> When you join, the server sends history as multiple [CHANNEL_HISTORY]|{idx}|{chunk} packets, then [CHANNEL_HISTORY_END]. If any single chunk is dropped (or arrives after END due to reordering), the client does “”.join(buffer) with empty slots → malformed JSON –> silent failure in the
except block –> no messages shown.
This is the main downside of UDP and so i am thinking about swapping the whole chat client over to TCP - I’ll probably push the existing UDP client to a different branch and work on the updated TCP version on the maim branch of the repo. This will take a while…

Attachment
0
eee
  • Server side control of fetch cooldown has now been fully implemented.
  • Set the fetch command cooldown in server/config.json.
  • Clients can no longer bypass this and it saves even after quitting the client.
  • Working on doing the same for message ratelimits.

Changelog

  • add whitespace (161372a)
  • server side control of fetch cooldown (a55f634)
Attachment
0
eee

Been busy today so haven’t gotten much done but oh well.

  • Updated the README slightly
    –> I will be creating a fully detailed and coherent one later once the project is closer to shipping
  • I have also begun to implement a server side control for the fetch command cooldown - my plan is that server hosts will be able to configure this in their server/config.json file –> the code for this isn’t very complex but it is taking me a little while to fix all the bugs I’m creating, especially with how cursed curses is (ig clue is in the name).
  • Also working on a general message ratelimit that can be configured server side too

Known Bugs

  • The first time you DM a user, they must be online - whether or not this is something I should leave idk but I will fix this so you can run /dm or open the dm panel to see all users - even if you have not DMed them before and they are not currently online.
  • Essentially, a user must be online to start a DM conversation with them currently.
  • I may also reduce the DM panel down to only users you have DMed previously and reserve /dm for creating those new chats with other users - lmk what you think if ur reading this lol

Changelog

Attachment
0
eee

Command Autocomplete

  • Finally finished the command autocomplete functionality
  • Typing / in the text box will open a dialogue that lists all the possible commands that match, as you continue to type, the list updates to show only matching commands.
  • Use arrow keys to select a command from the popup menu and enter to type out the full command in the text box for you.
  • Normal commands still function as normal, this is just a general QOL update to make the process faster and more pleasant.

Next Updates:

  • Fetch user stats dialogue
  • Server side control of fetch command cooldown
  • Server side message ratelimiting
    —–> All these features will be managed server side to make the program more robust and prevent people bypassing ratelimits or cooldowns by just editing the client. This also means that the cooldowns/ratelimit can be easily configured and will not reset when the client is restarted (currently you can just close and reopen the client to reset any cooldowns).

Changelog

  • begin implementation of cmd autocomplete (36a9937)
  • remove debug code - print(token) unnecessary and server host shouldnt need access to user tokens (a4671c5)
  • command autocomplete fully implemented (dd83c6f)
Attachment
0
eee

Tiny update

  • Removed a bit of debug code I left in the source lol

  • Have done a bit more work toward the autocomplete function for commands, I have finished writing the key capture methods for it (ie arrow keys used to scroll popup menu if active, if not then scroll chat) and I am now finishing off command descriptions and working on displaying the actual window.

  • begin implementation of cmd autocomplete (36a9937)

  • remove debug code - print(token) unnecessary and server host shouldnt need access to user tokens (a4671c5)

Attachment
0
eee
  • Began implementation of command autocomplete - popup menu appears when typing /… .

  • Moved ADMIN tag to other side of username

  • Fixed a few bugs

  • /stats command now displays stats for the user running the command if no user given

  • /stats command to output either ur stats or the requested users stats - messages sent, banned state, mute state etc, will add last online etc later (c485e9e)

  • move admin tag to the right side of username, update .gitignore (69d01d6)

  • begin implementation of cmd autocomplete (36a9937)

Attachment
0
eee
  • Updated the README - more instructions on how to actually use Lantern and how to spin up a server.

  • Also added the requirements.txt file which is referenced in the README, allowing for easy installation of dependencies
    –> luckily the only dependency that is not pre-installed on python is “rich”, so Lantern remains relatively lightweight in terms of packages required.

  • I will be adding a more modular config system for the sever, allowing you to easily customise many features such as max message length, custom join messages etc.

  • I will also be working on a stats command that allows you to easily view your own stats or other user’s stats (messages sent, privileges, muted state, last online etc).

  • req.txt (17a9493)

  • readme lol (31cb702)

Attachment
0
eee
  • Ban reasons have now been fully implemented
    –> When a server admin runs the /ban command, they are presented with small dialog that allows them to enter the reason for the ban.
    This ban reason is then displayed on the newly added ban screen (that is shown to the targeted user). The ban reason is also shown whenever the user attempts to log back into their account.
  • I have also fixed system messages from the DND command not showing when in DM view.
0
eee

Big update today :)

  • User session tokens –> Users are now given session tokens whenever they connect to the client, these are assigned by the server and stored on the server and on the client - whenever a client sends a request that requires admin permissions, their token must be sent alongside it. This token is then compared to the session tokens of the actual admins (configured in the server config file) to ensure that only users who have been given admin privileges can perform actions such as ban, mute or change the username’s of users.
  • Admin commands:
  • /ban
  • /mute
  • /unmute
  • /changeusername
    The mute command only mutes from the main channel, not from dms.
    The changeusername command requires client to be restarted after your username is changed for the new username to show in the main chat - your old messages will still have your old username as this would otherwise require the server to change every message from you in the DB to match your current username.
    General Fixes:
  • System alerts now send when in DM view
  • Removed /channel as a command - now just /back
  • Fixed some users not showing up on DM panel
  • WIP:
  • Fix notifications - only send when window focused (still can’t get it working lol)
  • Ban reasons - when banning a user, you are prompted to enter the reason for it - which is then displayed to the banned user for a short period of time until they quit the program.
  • Username validation - no spaces, or certain chars.
  • Message stripping - strip messages of any newlines (especially when pasting) - so if you were to paste a block of text with many new lines, this would not trigger message send for each new line.
Attachment
0
eee

Few implementations I have been working that have proven to be pretty time consuming:

  • User session tokens - instead of identifying users purely on their username, I have decided to implement a function that assigns each user a session token every time they connect to the client. This means that people cannot impersonate users (still a WIP).

  • Following on from this, I am currently working on adding server admins.
    –> Server admins will be able to mute users, ban users, change usernames etc. This is the main reason for adding user tokens as the sever will store the user tokens for all users but also those for server admins and will check that every admin command used is only sent by a user who has an admin user token before executing the command.

  • These two features are still a WIP.

  • I have also implemented server side max message length control - so instead of this being determined by clients, it is not retrieved from the server upon connection. I am also going to implement more sever-side config options.

  • Also updated the README on the Github repo.

  • Few new commands too - /logout to logout of the current user account.

  • System alerts now appear even when you are in DM mode.

  • Will probably remove the /channel command and just use /back. - might add configurable command aliases if I feel it is worth the time.

Attachment
Attachment
Attachment
0
eee

Couple quick fixes today (still took 2 hours to debug this lol)

  • DM command fixed - with improved validation so you can’t DM yourself (although that would be nice), or a user that does not exist
  • DM panel no longer shows you - was pointless and just confused me when running multiple instances of the client during testing
  • Fetch command now works in DMs - forgot that I need to append it to the dm messages and not the main channel messages lol
  • Fetch command has an improved cooldown message that states how long you have left on your cooldown
  • Keybinds - ctrl + b to go back to main chat, ctrl + p opens panel etc
  • Fixed a few other small bugs such as system messages not showing in dm view. I am aware that “message failed to send” alerts currently don’t appear if in dm view, will fix soon.
Attachment
Attachment
0
eee
  • Added a cursor the main text box meaning you can edit messages before you send them without having to delete the whole way back to the one thing you want to edit.
  • Improved help menu’s with color coding
  • Improved DM panel
  • Keybinds added such as ctrl + p to open DM panel
  • Awesome ascii art cos why not (on help menu’s)
Attachment
Attachment
0
eee
  • Finally pushed all the recent updates to the github repo (accidentally pushed some password hashes too but they’re all gone now thanks to git-filter-repo.
  • Updated README with a nice image for your viewing pleasure
    TODO:
  • Fix notifications - i found a pretty awesome way of checking if a window is focused using ANSII escape sequences.
  • DND keybind + add to status bar
  • Add a few other keybinds e.g. to open dm panel
  • Few other things I’ve probably forgotten about but I’ll remember eventually …

Also currently working on a nicer help menu that isn’t just a boring list of commands.

Attachment
0
eee

Short Update

  • Notifications - working on a fix for this, currently you can either have the choice of no notifications at all or notifications whenever a message is sent (even if you have that window focused). I am working on a fix for this however I have been unable to figure out how to detect if a window is focused so will simply be checking if the user is idle by looking for when the last time their mouse moved over the window or the last time they pressed a key.
  • Passwords are all hashed using SHA256 and a salt for extra security :).
  • Sending a message when the server is not running will now produce a system message that lets the user know their message failed to send - likewise when initially running the program or logging in.
Attachment
0
eee

Current WIP:

  • DM functionality –> typing /dm {user} will take you to your dms with that user and allow you to send them messages privately.
  • DM Panel –> typing /panel will open a panel which shows all online/offline users - allowing you to select a user and begin messaging them.
  • Authentication system –> you can now create accounts through the TUI, these credentials are stored on the server (all passwords are hashed too). There is options to register or login - this only has to be completed if it is the first time you are running the client - the program creates a .lantern_session file which stores those credentials and logs you in automatically in future. You can also logout by typing /logout.
  • Message storage (WIP) –> messages are to be stored server side - linked to user accounts. This means that messages sent to you - either as dm or in the main chat - whilst you are offline still show when you log back in. Additionally, this means there cannot be any tampering with message data.

There are a few other additions I have made - will include these in the next devlog. Currently working on a hotfix for the notifications and ensuring they only send when the window that the client is running in is not focused.

Attachment
Attachment
Attachment
Attachment
Attachment
Attachment
0
eee

Added notification support, notifications are sent under one of the following conditions:

  • User Join/Leave
  • System Message
  • Message Received
    Currently, this implementation uses notify-send in order to trigger your notification daemon to send a notification with the specified content. I am currently working on detecting if a user has the window focused and if they do not, then sending a notification. In this current prototype, notifications are sent even if the user has the window focused - which of course gets annoying.

In order to implement this, I will likely just check when a user has last interacted with the TUI ie the last time they pressed any key and comparing that to the current time and if it is above a certain threshold then sending a notification.

Attachment
0
eee

First iteration has been pushed to GitHub.
Current/New features:

  • Keyboard Shortcuts (cos who uses a mouse anyway)
  • Chat Saves - all chats are saved even when you quit the program
  • Fixed user list - users who have exited the client by simply closing the terminal window are now removed from the user list (when heartbeat not received)
  • Chat scrolling - you can scroll up/down with arrow keys or mouse to view previous chats
  • Color coding - join, leave and system messages all have proper color coding
  • Implemented a keyboard shortcut help menu
  • Config file - instead of having to keep entering port and server via -p / -s , you can store your config in a json file (argparse still supported and takes priority over config file).
  • Status bar - bar at bottom of client to show uptime, current time, no. of users who are connected and ping.
Attachment
Attachment
0
eee

I have built the first prototype of the chat client - currently all the code is split into a server and client file however I will be shifting to an OOP approach before publishing this first iteration to GitHub. I have added a basic TUI in curses alongside some args that can be passed when the program is run, these are:
-s/–server –> change server (defaults to 0.0.0.0)
-p/–port –> change port (defaults to 6000)
-u/–username –> set username (defaults to your local device username)

Username formats all follow the same structure:
[username]@[hostname]
where username is either your local account username (ie the name of your home directory) or the username passed as an argument to the program and hostname is your device’s hostname.

The server is required for clients to be able to talk over a LAN/network - the server logs all users, messages and allows for clients to fetch the online users to display in a user list on the main TUI.
I have also implemented a status bar which gives the current time, number of users connected, your ping in ms, and your uptime as a client.

Some networks such as my school network prevent me from using this client to chat over a LAN (something to do with opening ports and connecting to sockets) - a work around I have devised for this is to use a tunneling service to tunnel the port my server is hosted at to an IP that is accessible from any network.

Attachment
0
eee

Spent some time researching different ways I could build a TUI through python. I have settled on Curses - although it is much more complex compared to other TUI libraries such as blessed or textual, this additional complexity makes way for much greater levels of customization and functionality. I have begun reading the docs and creating small terminal interfaces to familiarize myself with curses.

Attachment
Attachment
0
eee

Created the main framework for the project - including the main program file and any additional files.
I have decided that the initial implementation of this project will have a focus on first creating an effective networking system before then moving on to working on the TUI and creating an “active users” list.

Attachment
0