stevenleeg / gobb Goto Github PK
View Code? Open in Web Editor NEWA simple and fast bulletin board written in Go.
License: Other
A simple and fast bulletin board written in Go.
License: Other
main.go
tries to import the following two packages which are not in the standard library (and are not given a valid import path for third-party packages).
"sirjtaa/controllers"
"sirjtaa/config"
https://github.com/stevenleeg/gobb/blob/master/utils/utils.go#L10
This sucks and should be changed to something set in the config file.
Ensure that the first user who registers (id: 1) is assigned to the admin role by default. This rids of the installation step that involves going into postgres and running that UPDATE
query.
`2024-07-03 18:13:37.864 +04 [14151] ERROR: relation "goose_db_version" does not exist at character 36
2024-07-03 18:13:37.864 +04 [14151] STATEMENT: SELECT version_id, is_applied from goose_db_version ORDER BY id DESC
2024-07-03 18:13:37.864 +04 [14151] ERROR: permission denied for schema public at character 14
2024-07-03 18:13:37.864 +04 [14151] STATEMENT: CREATE TABLE goose_db_version (
id serial NOT NULL,
version_id bigint NOT NULL,
is_applied boolean NOT NULL,
tstamp timestamp NULL default now(),
PRIMARY KEY(id)
);
2024-07-03 18:13:37.866 +04 [14151] ERROR: relation "settings" does not exist at character 27
2024-07-03 18:13:37.866 +04 [14151] STATEMENT: select "key","value" from "settings" where "key"=$1;
2024-07-03 18:18:31.840 +04 [14117] LOG: checkpoint starting: time
2024-07-03 18:18:32.194 +04 [14117] LOG: checkpoint complete: wrote 3 buffers (0.0%); 0 WAL file(s) added, 0 removed, 0 recycled; write=0.002 s, sync=0.108 s, total=0.355 s; sync files=2, longest=0.058 s, average=0.054 s; distance=0 kB, estimate=0 kB; lsn=0/1972B60, redo lsn=0/1972B28
2024-07-03 18:54:41.767 +04 [14151] ERROR: relation "boards" does not exist at character 88
2024-07-03 18:54:41.767 +04 [14151] STATEMENT:
SELECT
boards.*,
views.time AS viewed_on
FROM boards
LEFT OUTER JOIN views ON
views.post_id=(SELECT id FROM posts WHERE board_id=boards.id AND parent_id IS NULL ORDER BY latest_reply DESC LIMIT 1) AND
views.user_id=$1
ORDER BY
ordering ASC
2024-07-03 18:54:41.768 +04 [14151] ERROR: relation "users" does not exist at character 22
2024-07-03 18:54:41.768 +04 [14151] STATEMENT: SELECT COUNT() FROM users
2024-07-03 18:54:41.768 +04 [14151] ERROR: relation "users" does not exist at character 15
2024-07-03 18:54:41.768 +04 [14151] STATEMENT: SELECT * FROM users ORDER BY created_on DESC LIMIT 1
2024-07-03 18:54:41.768 +04 [14151] ERROR: relation "posts" does not exist at character 22
2024-07-03 18:54:41.768 +04 [14151] STATEMENT: SELECT COUNT() FROM posts
2024-07-03 18:54:41.768 +04 [14151] ERROR: relation "users" does not exist at character 15
2024-07-03 18:54:41.768 +04 [14151] STATEMENT: SELECT * FROM users WHERE last_seen > current_timestamp - interval '5 minutes' AND hide_online != true
2024-07-03 18:54:41.768 +04 [14151] ERROR: relation "settings" does not exist at character 27
2024-07-03 18:54:41.768 +04 [14151] STATEMENT: select "key","value" from "settings" where "key"=$1;
2024-07-03 18:54:41.769 +04 [14151] ERROR: relation "settings" does not exist at character 27
2024-07-03 18:54:41.769 +04 [14151] STATEMENT: select "key","value" from "settings" where "key"=$1;
2024-07-03 18:54:41.769 +04 [14151] ERROR: relation "settings" does not exist at character 27
2024-07-03 18:54:41.769 +04 [14151] STATEMENT: select "key","value" from "settings" where "key"=$1;
`
here is the log of postgres
Currently can't see a way to traverse the board hierarchy. "Posts in general" could be "Board Index >> General" or something. Maybe it works and it's disabled? Don't know.
It's possible to create usernames with the same name but different cases, which is a problem. Make usernames case insensitive when registering, checking, and logging in.
It would be nice if there was an interface for adding webhooks. This could be a list of URLs that get pinged when a post is created or edited. This would allow for services like an IRC bot that would post in a channel whenever a new post is made or topic is started on the board.
Example (Declan's signature causes the post width to be larger than the rest).
Width should be consistent between posts.
For humanity's sake.
Best practice. Do this before you forget.
Some way of banning users and IP addresses by moderators/administrators.
I'm periodically seeing things like this in the log:
[error] Could not get latest post: (sql: no rows in result set)
[error] Cannot select user (sql: no rows in result set)
Something weird is going on here: parent_id: 1171, page_id: 0[error] Something went wrong in posts ([error] Could not get parent (1171))
[error] Cannot select user (sql: no rows in result set)
Something weird is going on here: parent_id: 865, page_id: 0[error] Something went wrong in posts ([error] Could not get parent (865))
Something weird is going on here: parent_id: 865, page_id: 0[error] Something went wrong in posts ([error] Could not get parent (865))
Not exactly sure what could be causing them (I know where the errors are occurring, just not why).
If you haven't set a signature and make a post no signature is shown.
If you set a signature, remove it (set the field to nothing in your user settings), and then post, a signature box is shown.
Possible solution would be to set user.Signature.Valid
to false if the user's signature is set to an empty string.
Something like recaptcha. Make sure it's optional (on the admin's end).
Not a requirement for the milestone, but it might be useful to optionally collect e-mail addresses and require e-mail validation.
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.