Browser Extension Vote-Counter (early demo)

This forum is for discussion related to the game.
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #100 (ISO) » Sat Feb 10, 2024 4:20 pm

Post by JacksonVirgo »

Bumping this so I remember that this project exists and I should complete it
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #101 (ISO) » Sat Feb 10, 2024 4:20 pm

Post by JacksonVirgo »

I've been massively overcomplicating it and the break for personal stuff has made me realise that so gonna simplify and then complete this and then have a personal pizza party
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
Psyche
Psyche
he/they
Survivor
User avatar
User avatar
Psyche
he/they
Survivor
Survivor
Posts: 10721
Joined: April 28, 2011
Pronoun: he/they

Post Post #102 (ISO) » Mon Feb 12, 2024 9:15 pm

Post by Psyche »

am sure to drift in and out but would like to fit in some time to start contributing and helping keep momentum. would also help me build my comfort w/ typescript and get ideas for my other projects.
first step is probably checking if i can set up the dev environment by following your instructions
in the meantime do you think there are any "good first issues" you could add to the repo that could get my feet wet w/o disrupting your other plans?
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #103 (ISO) » Tue Feb 13, 2024 8:15 am

Post by JacksonVirgo »

In post 102, Psyche wrote: am sure to drift in and out but would like to fit in some time to start contributing and helping keep momentum. would also help me build my comfort w/ typescript and get ideas for my other projects.
first step is probably checking if i can set up the dev environment by following your instructions
in the meantime do you think there are any "good first issues" you could add to the repo that could get my feet wet w/o disrupting your other plans?
Yeah so I just remembered I left the repo in a state that's broken in the sense that as soon as the bg script idles, the page needs to refreshed and thats not a super long time either so just beware of that. I should get that fixed pretty soon (today or tomorrow).

In terms of good first issues, I'll get back to that I just need time to look back over the project
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
yessiree
yessiree
he
Mafia Scum
User avatar
User avatar
yessiree
he
Mafia Scum
Mafia Scum
Posts: 4389
Joined: June 6, 2013
Pronoun: he

Post Post #104 (ISO) » Tue Feb 20, 2024 11:14 pm

Post by yessiree »

been wanting to contribute to this project too, i'll revisit this soon!

quick question @JV, why did you decide to use a package like zod, as opposed to just regular TSDoc? zod is kind of intimidating to see in a ts project ngl :lol:
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #105 (ISO) » Tue Feb 20, 2024 11:20 pm

Post by JacksonVirgo »

In post 104, yessiree wrote: been wanting to contribute to this project too, i'll revisit this soon!

quick question @JV, why did you decide to use a package like zod, as opposed to just regular TSDoc? zod is kind of intimidating to see in a ts project ngl :lol:
I used what I was most comfortable with as I wanted to spit something out pretty fast, I haven’t touched much tsdoc all things considered even though I probably should.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
yessiree
yessiree
he
Mafia Scum
User avatar
User avatar
yessiree
he
Mafia Scum
Mafia Scum
Posts: 4389
Joined: June 6, 2013
Pronoun: he

Post Post #106 (ISO) » Wed Feb 21, 2024 12:29 am

Post by yessiree »

In post 105, JacksonVirgo wrote:
In post 104, yessiree wrote: been wanting to contribute to this project too, i'll revisit this soon!

quick question @JV, why did you decide to use a package like zod, as opposed to just regular TSDoc? zod is kind of intimidating to see in a ts project ngl :lol:
I used what I was most comfortable with as I wanted to spit something out pretty fast, I haven’t touched much tsdoc all things considered even though I probably should.
gotcha, i was just wondering why u would use zod because it is kinda overkill for this project, interfaces and TSDoc that come out of the box with typescript should be good enough

maybe my first PR will be deprecating zod and replacing it with typescript native syntax :thinking:
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #107 (ISO) » Wed Feb 21, 2024 12:31 am

Post by JacksonVirgo »

Lmfao feel free if you wanna, I agree it’s overkill ahaha. Just awfully convenient for validating yaml without needing to use my brain
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #108 (ISO) » Wed Feb 21, 2024 3:29 pm

Post by JacksonVirgo »

I fixed my computer once again so with people wanting to contribute I should probably fix the glaring issue which is the timeout problem, I overcomplicated it to all hell and I really shouldn't have.
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #109 (ISO) » Wed Feb 21, 2024 9:22 pm

Post by JacksonVirgo »

Alright so I realised that I've overcomplicated this project to an extreme degree, I've reverted back to an older version and I am going to focus on simplifying what the current process is cuz my god my eyes hurt looking at this code
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #110 (ISO) » Wed Feb 21, 2024 9:25 pm

Post by JacksonVirgo »

And for the record, I have very little experience working with other people on a codebase. I got no idea how to use github beyond the very surface level stuff, I reverted to an older commit so if that fucks anything over regarding your forks uh, sorry?

I did make a branch prior to doing so, so that I can copy/paste anything to do with the UI changes that I've made after moving to a tRPC thing like a chump
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #111 (ISO) » Wed Feb 21, 2024 9:31 pm

Post by JacksonVirgo »

In post 104, yessiree wrote: quick question @JV, why did you decide to use a package like zod, as opposed to just regular TSDoc? zod is kind of intimidating to see in a ts project ngl
Can TSDoc validate objects? Because I'm mostly using Zod to validate types so I don't have to go through and check them myself, as there is no typesafe layer when communicating from the content scripts and the bg scripts
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
yessiree
yessiree
he
Mafia Scum
User avatar
User avatar
yessiree
he
Mafia Scum
Mafia Scum
Posts: 4389
Joined: June 6, 2013
Pronoun: he

Post Post #112 (ISO) » Wed Feb 21, 2024 10:42 pm

Post by yessiree »

In post 111, JacksonVirgo wrote:
In post 104, yessiree wrote: quick question @JV, why did you decide to use a package like zod, as opposed to just regular TSDoc? zod is kind of intimidating to see in a ts project ngl
Can TSDoc validate objects? Because I'm mostly using Zod to validate types so I don't have to go through and check them myself, as there is no typesafe layer when communicating from the content scripts and the bg scripts
if you are validating objects during runtime (from user input), there is no easy way, because types don't exist in runtime, you'd have to go through the good ol' user input validation step

this might help (i see you have a lot of optional fields in the game definition check)
https://www.typescriptlang.org/docs/han ... predicates
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #113 (ISO) » Wed Feb 21, 2024 10:43 pm

Post by JacksonVirgo »

In post 112, yessiree wrote:
In post 111, JacksonVirgo wrote:
In post 104, yessiree wrote: quick question @JV, why did you decide to use a package like zod, as opposed to just regular TSDoc? zod is kind of intimidating to see in a ts project ngl
Can TSDoc validate objects? Because I'm mostly using Zod to validate types so I don't have to go through and check them myself, as there is no typesafe layer when communicating from the content scripts and the bg scripts
if you are validating objects during runtime (from user input), there is no easy way, because types don't exist in runtime, you'd have to go through the good ol' user input validation step

this might help (i see you have a lot of optional fields in the game definition check)
https://www.typescriptlang.org/docs/han ... predicates
Yeah I know types don't exist in runtime, that's why I am using zod to validate it
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
yessiree
yessiree
he
Mafia Scum
User avatar
User avatar
yessiree
he
Mafia Scum
Mafia Scum
Posts: 4389
Joined: June 6, 2013
Pronoun: he

Post Post #114 (ISO) » Wed Feb 21, 2024 10:53 pm

Post by yessiree »

In post 113, JacksonVirgo wrote:
In post 112, yessiree wrote:
In post 111, JacksonVirgo wrote:
In post 104, yessiree wrote: quick question @JV, why did you decide to use a package like zod, as opposed to just regular TSDoc? zod is kind of intimidating to see in a ts project ngl
Can TSDoc validate objects? Because I'm mostly using Zod to validate types so I don't have to go through and check them myself, as there is no typesafe layer when communicating from the content scripts and the bg scripts
if you are validating objects during runtime (from user input), there is no easy way, because types don't exist in runtime, you'd have to go through the good ol' user input validation step

this might help (i see you have a lot of optional fields in the game definition check)
https://www.typescriptlang.org/docs/han ... predicates
Yeah I know types don't exist in runtime, that's why I am using zod to validate it
yeah on a closer look of the codebase i dont think zod is as overkill as i thought it was lol
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #115 (ISO) » Wed Feb 21, 2024 10:58 pm

Post by JacksonVirgo »

In post 114, yessiree wrote:
In post 113, JacksonVirgo wrote:
In post 112, yessiree wrote:
In post 111, JacksonVirgo wrote:
In post 104, yessiree wrote: quick question @JV, why did you decide to use a package like zod, as opposed to just regular TSDoc? zod is kind of intimidating to see in a ts project ngl
Can TSDoc validate objects? Because I'm mostly using Zod to validate types so I don't have to go through and check them myself, as there is no typesafe layer when communicating from the content scripts and the bg scripts
if you are validating objects during runtime (from user input), there is no easy way, because types don't exist in runtime, you'd have to go through the good ol' user input validation step

this might help (i see you have a lot of optional fields in the game definition check)
https://www.typescriptlang.org/docs/han ... predicates
Yeah I know types don't exist in runtime, that's why I am using zod to validate it
yeah on a closer look of the codebase i dont think zod is as overkill as i thought it was lol
:sweat_smile: well that's good at least
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
Psyche
Psyche
he/they
Survivor
User avatar
User avatar
Psyche
he/they
Survivor
Survivor
Posts: 10721
Joined: April 28, 2011
Pronoun: he/they

Post Post #116 (ISO) » Wed Feb 21, 2024 11:48 pm

Post by Psyche »

i am vry confused
maybe i stick to pythonland after all
User avatar
yessiree
yessiree
he
Mafia Scum
User avatar
User avatar
yessiree
he
Mafia Scum
Mafia Scum
Posts: 4389
Joined: June 6, 2013
Pronoun: he

Post Post #117 (ISO) » Thu Feb 22, 2024 2:31 pm

Post by yessiree »

In post 116, Psyche wrote: i am vry confused
maybe i stick to pythonland after all
Can ignore what I talked about
It's only about syntax so not very relevant to the actual features of the project
User avatar
Aureal
Aureal
she/her
Mafia Scum
User avatar
User avatar
Aureal
she/her
Mafia Scum
Mafia Scum
Posts: 3691
Joined: September 9, 2005
Pronoun: she/her

Post Post #118 (ISO) » Sun Mar 24, 2024 8:50 pm

Post by Aureal »

This thing still hates me no matter what I do. :lol: Can't even get it working with just the player list again. I recall last time I used it I had to workaround the dead section not working by just removing those players from the list.
"Yeah after a point it felt like Aureal was the only one talking sense despite being a goose so I just followed."
-furtiveglance
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #119 (ISO) » Sun Mar 24, 2024 11:35 pm

Post by JacksonVirgo »

In post 118, Aureal wrote: This thing still hates me no matter what I do. :lol: Can't even get it working with just the player list again. I recall last time I used it I had to workaround the dead section not working by just removing those players from the list.
I recall last time the issue was using tabs and not spaces or something (which is so silly of a problem) is it that again?
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
Aureal
Aureal
she/her
Mafia Scum
User avatar
User avatar
Aureal
she/her
Mafia Scum
Mafia Scum
Posts: 3691
Joined: September 9, 2005
Pronoun: she/her

Post Post #120 (ISO) » Mon Mar 25, 2024 3:34 am

Post by Aureal »

Nope, definitely using spaces. Repeatedly tried copy/pasting the both the last game's file and the formatting you gave me and just adjusting the names.
"Yeah after a point it felt like Aureal was the only one talking sense despite being a goose so I just followed."
-furtiveglance
User avatar
yessiree
yessiree
he
Mafia Scum
User avatar
User avatar
yessiree
he
Mafia Scum
Mafia Scum
Posts: 4389
Joined: June 6, 2013
Pronoun: he

Post Post #121 (ISO) » Mon Mar 25, 2024 8:28 pm

Post by yessiree »

In post 119, JacksonVirgo wrote:
In post 118, Aureal wrote: This thing still hates me no matter what I do. :lol: Can't even get it working with just the player list again. I recall last time I used it I had to workaround the dead section not working by just removing those players from the list.
I recall last time the issue was using tabs and not spaces or something (which is so silly of a problem) is it that again?
In post 120, Aureal wrote: Nope, definitely using spaces. Repeatedly tried copy/pasting the both the last game's file and the formatting you gave me and just adjusting the names.
https://github.com/JacksonVirgo/mafiasc ... ols/pull/3

I submitted a PR to fix the issue Aureal is having. Please review and merge, thanks!
User avatar
JacksonVirgo
JacksonVirgo
they/him
Survivor
User avatar
User avatar
JacksonVirgo
they/him
Survivor
Survivor
Posts: 13224
Joined: October 29, 2019
Pronoun: they/him
Location: ɐılɐɹʇsn∀
Contact:

Post Post #122 (ISO) » Tue Mar 26, 2024 12:03 am

Post by JacksonVirgo »

In post 121, yessiree wrote:
In post 119, JacksonVirgo wrote:
In post 118, Aureal wrote: This thing still hates me no matter what I do. :lol: Can't even get it working with just the player list again. I recall last time I used it I had to workaround the dead section not working by just removing those players from the list.
I recall last time the issue was using tabs and not spaces or something (which is so silly of a problem) is it that again?
In post 120, Aureal wrote: Nope, definitely using spaces. Repeatedly tried copy/pasting the both the last game's file and the formatting you gave me and just adjusting the names.
https://github.com/JacksonVirgo/mafiasc ... ols/pull/3

I submitted a PR to fix the issue Aureal is having. Please review and merge, thanks!
Merged. Thanks for catching that btw lol.

Sadly I don’t have a way to compile it at the moment (my computer is deadge)
"Am I a ghost like you, caught between the seams of two intertwining melodies?"


wiki // GTKAS
User avatar
yessiree
yessiree
he
Mafia Scum
User avatar
User avatar
yessiree
he
Mafia Scum
Mafia Scum
Posts: 4389
Joined: June 6, 2013
Pronoun: he

Post Post #123 (ISO) » Tue Mar 26, 2024 12:44 am

Post by yessiree »

In post 122, JacksonVirgo wrote: Merged. Thanks for catching that btw lol.

Sadly I don’t have a way to compile it at the moment (my computer is deadge)
glad to help

thanks to Aureal for being the guinea pig
User avatar
yessiree
yessiree
he
Mafia Scum
User avatar
User avatar
yessiree
he
Mafia Scum
Mafia Scum
Posts: 4389
Joined: June 6, 2013
Pronoun: he

Post Post #124 (ISO) » Tue Apr 02, 2024 5:36 pm

Post by yessiree »

submitted another PR for some refactoring

one of them is using "view=print" mode when scraping posts, which should drastically speed up votecount generation since it potentially reduces the response payload size by over 90%! (from over 1 MB to ~40 kB per request)
Post Reply

Return to “Mafia Discussion”