Skip to content
This repository has been archived by the owner on May 3, 2021. It is now read-only.

Latest commit

 

History

History
107 lines (107 loc) · 4.46 KB

todo.org

File metadata and controls

107 lines (107 loc) · 4.46 KB

[/] Bugs

DB Improvements [4/8]

  • [ ] retest each clip for fencer names and scores
  • [ ] sanitize db for duplicate names
  • [ ] sanitize db for names that should be separated
  • [X] sanitize db for extra bouts
  • [ ] investigate every clip that throws an error on running normalize_names
  • [X] add tournaments table
  • [X] data cleaning queries
    • [X] `update gfycats set tournament_id=’budapestwch2019’, gender=’female’ where valid and left_fencer_id is NULL and fotl_name = ‘NAVARRIA M’;`
    • [X] `insert into canonical_names (gfy_name, canonical_name) values (‘kovalav n’, ‘kovalev nikolai’);`
  • [X] add bouts table
    • [X] each tournament has many bouts
    • [X] each bout has many touches
    • [X] columns: id, tournament_id, round, left_fencer_id, right_fencer_id

Pages To Add [1/3]

  • [X] filter touches [4/4]
    • [X] touches by fencer
    • [X] touches by location on body
    • [X] touches by location on strip
    • [X] all of the above
  • [-] fencer-specific page
    • [X] touches scored
    • [ ] touches scored per year
  • [-] my account page
    • [ ] logout button
    • [X] count of clips reviewed
    • [ ] badges?

[2/6] Albert’s Page

  • [-] DB changes
    • [X] list of keycodes/meanings
    • [ ] save reviewed touches - make them a special reel with all sabre clips, probably
    • [ ] save results - who reviewed, what the result was, and what clip it was
  • [X] clip page:
    • [X] fencers
    • [X] whose touch
    • [X] tournament name
    • [X] list of keycodes - pull from db
  • [ ] submit js
    • [ ] pull keycodes/meanings from db
  • [ ] stats page:
    • [ ] each key’s total
    • [ ] link to list of gfys for each key
    • [ ] API variant
  • [ ] submit endpoint
  • [X] keycodes endpoint

search page improvement [2/6]

  • [ ] search by opponent’s score
  • [ ] search by two fencers, get all touches between them
  • [X] add second search option “search fencers” and “search touches”
  • [ ] search form should remember answers
  • [X] “next page” button isn’t working
  • [ ] add foil to the various dropdown lists

gfy upload improvements [3/3]

  • [X] get updated list of fencers
  • [X] get list of fencers in a tournament
  • [X] deduplicate fencers in gfycats based on the list of fencers in the tournament, not in the whole list

gfy page improvements [3/3]

  • [X] add “report this touch” for errors
  • [X] show derived data, like fencer names and touch scored
  • [X] path should be `/clip/gfy_id` not `/clip?gfycat_gfy_id=gfy_id`

stats page improvements [1/1]

  • [X] filter stats by weapon
  • [ ] heatmap doesn’t filter by weapon

export reel update [3/3]

  • [X] add “can have us upload it for you” to /reels/help
  • [X] add “upload reel for me” button
  • [X] add endpoint for `/reels/upload`

reel creation improvements [0/3]

  • [ ] sort clips by tournament, then bout
  • [ ] allow option to categorize, not just yes/no
  • [ ] report clip directly from selection page

fencer page improvements [0/1]

  • [ ] add link to FIE page

add accounts [6/6]

  • [X] accounts table/model
  • [X] create new account
  • [X] login page
  • [X] associate reels with accounts
  • [X] associate form responses with accounts
  • [X] catch invalid hash error

help additions [2/2]

  • [X] API documentation
  • [X] “upload it for me” explanation

Notes

To fix the bout/fencer info:

update gfycats set left_fencer_id = NULL, right_fencer_id = NULL, bout_id = NULL;

delete from bouts;

delete from fencers;

delete from fencers_tournaments;

alter sequence fencers_tournaments_id_seq restart with 1;

alter sequence fencers_id_seq restart with 1;

alter sequence bout_id_seq restart with 1;

ruby download_tournament_entries.rb

rake db:normalize_names

rake db:add_bouts

DO NOT delete the gfycats table. There’s too much info there that can’t be replicated anymore.

Update Gfycats Bug

b-search requires a sorted array to work properly

Postgres search, by default (in my locale) sorts case-insensitive, but bsearch works case-sensitive

This causes bsearch to miss the gfy id DimwittedWealthyHalicore

The difference is in index 3446 (for the nonce). For that, postgres sorts ‘AppropriateOldfashionedEstuarinecrocodile’ before ‘AppropriateOldIndianjackal’, but array#sort flips the order.

Getting postgres to sort case-insensitive is locale dependent and depends on the machine you’re running it on

So we’ll lowercase everything

that didn’t work, so we’ll stop using bsearch?

that’s super slow, so we’ll just sort in ruby instead of postgres