increment game and match counter at the end of a game
[brisk.git] / TODO.txt
1  TODO |
2 ------+
3
4   FEATURES |
5  ----------+
6    - APPRENTICE
7      Phase1
8      DONE - ip check and time limit
9        DONE . sql
10          DONE . temporary table limitation
11        DONE . message
12      DONE - usermgmt extension
13      DONE - add close button
14      DONE - add apprentice icon
15      - match counters
16        . sql for match counters
17        . migration script for old users
18
19      Phase2
20      - new info system
21      - guarantee for apprentice
22    
23     - MENTORS
24      - listen all
25
26    - BUDDY LIST
27      - white list
28      - black list
29      - delegate
30
31    - DEANONYMIZER
32       . study how to move login delta injection
33
34    - CERTIFICATIONS
35       DONE . Guarantes for certified-only (buttons choice managed)
36       DONE . Tables for certified-only
37       . Term Of Use
38       . Placing for certified-only
39
40    - IP CLASSES BAN
41       DONE . BAN and BLACK lists added
42       DONE . update method to SIGHUP manager
43       DONE . create constructor refactored
44
45    - PLACEMENT-NORMALIZATION
46       DONE . Normalize previous points
47       DONE . Denormalize "Info" view
48       DONE . Denormalize explained matches
49       DONE . Check placement
50       DONE . Distinguish between inherited mult and local mult
51
52    - AUTO-MAINTENANCE
53      DONE . Terms Of Service acceptance
54        DONE . print date of hard switch
55        DONE . TOS version
56        DONE . user TOS acceptance (db field)
57        DONE . show TOS ([show me later, yes, no]/[yes, no])
58        DONE . switch-off date
59        DONE . manage accept
60        DONE . manage refuse
61        DONE . show current TOS
62        DONE . disable user reason integer field and remove SUSPEND state (db, php)
63        DONE . fix tos layout
64        DONE . opt - download TOS
65        . opt - checkbox for anonimous users with message when not checked
66        . opt - button enabled when arrived to the bottom of the TOS only
67        . opt - check TOS version between config file and TOS file
68      DONE . show guarantee (/guar <login> command)
69        DONE . multi-language
70        DONE . command documentation
71        DONE . manage disagreeding users investigation
72        DONE . self guaranteed
73      . DONE New Users Guarantee Procedure
74        . DONE Change guarantee workflow
75        . DONE Db update
76
77          UserA                 UserB                      Admin
78 -------------------------------------------------------------------------
79       guarante UserB
80            |
81            v
82       Save on mail
83          table,
84       email to UserB
85     (Disabled, MAILED)
86 -------------------------------------------------------------------------
87                            Receive email
88                            to check address
89                                  |
90                                  v
91                            Click on link
92                                  |
93                                  v
94                            Check on mail
95                                table,
96                            update user status,
97                            delete mail rec
98                           (Disabled, TOBECHK)
99 -------------------------------------------------------------------------
100                                                        admin panel
101                                                        accept user
102                                                             |
103                                                             v
104                                                      send email with
105                                                      password,
106                                                      update user status
107                                                       (Normal, NONE)
108 -------------------------------------------------------------------------
109                            Receive email
110                            with password
111 -------------------------------------------------------------------------
112
113      DONE . More user info in the list
114      DONE . Manage date to display when a user was required
115      . Email-address expiration check
116      . Account expiration
117
118
119    DONE - CONTINUE FEATURE
120      DONE . replace explicit strings with multilanguage array
121      DONE . add a php downloader with filtering on allowed requests
122      DONE . save points every game
123      DONE . modify points calculation to include order and mazzo
124      DONE . exclude not standard types from statistics
125          DONE . daily reports (1 for each active tournament)
126          DONE . monthly stats (for normal match only)
127      DONE . show current match ID when created
128      DONE . add info about continue to the info page
129      DONE . add command to continue
130          DONE . check consistency of the request
131      DONE . rearrange users and game status to continue the selected match
132      DONE . investigate user reordering ??
133
134    - WEBSOCKET TRANSPORT
135      . refactoring $enc attribute management
136      DONE . reintroduced $enc = 'plain' for websocket
137      DONE . fallback for not correct WS version
138      DONE . fini of ws stream
139      DONE . reactivate compression
140      DONE . fix xynt_test01
141      DONE M2: brisk working
142      DONE . manage multiport apache config
143      DONE . manage headers correctly in sac-a-push
144      DONE . manage transport.close method where required
145      DONE . xynt_stream: manage fallback to multiple ports
146      DONE . manage fini for ws
147      POST . server: manage input data from clients
148      POST . manage ping/pong (seems not required)
149
150      DONE . client (xynt_streaming.js)
151      DONE . server (transport.phh)
152
153      DONE M1: xynt_test01.php working
154
155
156    - improved S
157      . db update (add components, maybe single string)
158      . filter in index.php
159      . filter in index_wr.php
160
161    - prefs API:
162      . prefs_assign(content): assign json content as output var
163      . prefs_apply(prefs_new): apply new content to g_prefs and system
164      . prefs_load(content): load json content and apply to g_prefs and system
165
166      . prefs_update: update preferences temporarly
167      . prefs_save: save to the server the new prefs
168
169    - preferences (listen into preferences)
170         // js var, volatile server, (db server || cookie)
171         temporary: js var, volatile server
172         permanent: js var, volatile server, (db server || cookie)
173
174      . data from db OR, if missing, from cookies
175
176      . update values
177      . database change
178      . MANAGE NOT AUTH USERS
179
180    - preferences (with "modifiable S")
181      . Mod. S: new flag into database
182      . graph infrastructure
183      . new box to edit color
184
185   MAJOR |
186  -------+
187    - BUG: some connection to the named socket fails
188    - Not simultaneous more then one stream
189
190
191   MINOR |
192  -------+
193    WIP - try to be more antivirus-friendly
194    - multiple rows between games
195    - packetize and automatize php-ancillary and apache module
196    - DISABLED_TO_FIX: DNS access (perform blocking dns requests, must be fixed)
197
198
199   DONE |
200  ------+
201    DONE - temporarly server hung not reflected on user timeouts
202    DONE - timeouted users are still be able to sit down (only the first at the table is banned)
203    DONE - page still opened after the server restart
204    DONE - log_legal address fix
205    DONE - manage too fast reload in xynt-streaming
206    DONE - add xhr as transport layer and manage different streams better
207    TEST - BUG: pari + 72 non fa 4x ma attualmente fa 3x, da correggere
208    TEST - BUG: lurker are logged out (and remain a pending socket opened (look the spush log)
209    DONE - save/restore database
210    DONE - into the room local step remains -1
211    DONE - centralize all '<script ...' incapsulation to allow multiple transport system.
212    DONE - BUG: access with password from 2 diff browsers the second go in strange "page not found" 
213           in the first tentative, the second works
214    DONE - BUG: access with password from 2 diff browsers place the first in a strict loop (the 
215           problem was a call to a static parent method instead of the overrided child method,
216           substitute self:: with the dynamically get class::)
217    DONE - garbage management
218
219    DONE/FROZEN - problem with getpeer (HOSTADDR)
220
221    DONE - slow cards distribution
222    DONE - substr to mb_substr
223    DONE - parametrizations:
224           . parametrization of $DOCUMENT_ROOT  var in brisk-spush.phh file
225           . parametrization of SITE_PREFIX(_LEN) define
226           . move the name of the named socket into the configuration file
227    DONE - manage and test cross forwarder between table and room
228    DONE - setcookie (for tables only and persist prefs)
229    DONE - images flickering on slow windows: try to poll stream every 300 ms (seems to be download problem)
230    DONE - database connection fails after a while, check close and try PGSQL_CONNECT_FORCE_NEW.
231    DONE - unneeded garbage_time.expired access
232    DONE - BUG: fast loop on stream index_rd_ifra page (js watchdog start without timeout corrupt counts)
233    DONE - BUG: logout failed (fixed with a garbage_collector wrapper at sac-a-push level
234    DONE - 404 wrong page management (remove directories redirections (es. brisk/))
235    DONE - configuration file management
236    DONE - app level keep-alive
237    DONE - index_wr other issues
238    DONE - from room to table
239    DONE - from table to room
240    DONE - chunked
241    DONE - bug: read from a not resource handle (already closed because a new socket substitute it)
242    DONE - partial write for normal page management
243    DONE - index_rd_ifra: last_clean issue
244    DONE - fwrite failed error management (select, buffer where store unsent data, and fwrite check and retry)
245    DONE - bug: after restart index_rd.php receive from prev clients a lot of req
246    DONE - index_wr.php::chat
247    DONE - index_wr.php::exit
248    DONE - index_rd.php porting
249    DONE - generic var management from internet
250    DONE - index.php auth part
251    ABRT - index_wr.php::reload - reload is js-only function
252    ABRT - keepalive management - not interesting for our purposes
253
254  BRISK4 (mammuth)
255  ======
256
257  - STEP MANAGEMENT VERIFY
258  Slim Paragraph
259  DONE - move the garbage timeout on file
260  DONE - in index_rd load all data only when required
261  - briskin5 alignment
262    DONE . extern del garb_timeout
263    DONE . user_load parameters verify
264    DONE . Bin5::load_data and Bin5::save_data refactoring with
265           data split
266    . move many function into "Bin5 class"
267  - garbaging of .step files
268
269  DB: - initial usage
270      DONE - configurabilitĂ  file o db
271      DONE - aggiornare le funz di gestione db in modo che prevedano anche il flag DISABLE
272      DONE - travasatore file to pg
273        DONE - travaso punteggi
274        DONE - memorizzazione nuovi i punteggi nel db
275        DONE - gestione classifiche in SQL
276          DONE - produrle
277          DONE - mostrarle
278
279      STEP 1.1
280        DONE - points archiver
281
282      STEP 1.2
283        DONE - partial usability if database go down.
284
285      STEP 1.5
286      - sistema di inserimento nuovi utenti (riversatore da form di inserimento)
287
288      STEP 2
289      - modifica password   
290      - ripristino password 
291
292      STEP 3
293      - comunicazioni di aggiornamento (stato salvato sul server) 
294
295  DONE - var $G_base aggiunta per gestire include in include da path differenti
296
297  BRISK3 (trusty)
298  ======
299   DONE - donameter
300     DONE - G_donors
301     DONE (WOW!) - js object with infos
302     DONE - main logic at login (cookie check in index_rd.php; show_message and createCookie via snippets with block
303            to prevent fast reload)
304     DONE - cookie per non assillare e visualizz.
305     DONE - graphical donameter
306     WIP content (in conf.)
307
308   DONE - numero di tavoli auth-only nel .brisk-install
309   - isolation
310     TEST - ricalcolo delle persone in piedi quando si cambia modalitĂ 
311     DONE - se si e' in isolation non si può cambiare nick perdendo l' auth
312     DONE - non leggere le chat di quelli non autenticati (in isolation)
313     DONE - regole per passare alla modalita' (in piedi o ai tavoli autenticati) 
314     DONE - treni non auth da nascondere 
315     DONE - verso gli altri ??: uguale a prima
316
317   finire multilingua (briskin5/index_wr.php e altri se ce ne sono)
318   coniglio
319   only auth strictly
320   placing limits to config file
321
322 Dunque, 
323
324 - come vengono aggiornate le classifiche: ogni giorno alle 23:58
325
326 - cosa cambia tra le tre coppie di classifiche: 
327   ci sono le classifiche dell' ultima settimana, quelle dell' ultimo mese,  e quelle dell' ultimo trimestre,
328   per ognuno di questi lassi di tempo poi c'è la classifica di chi ha giocato piĂą di TOT partite o meno di TOT partite, con TOT che cambia a seconda del lasso di tempo.
329
330 - come vengono calcolate le classifiche: per ogni utente vengono presi tutti i punti fatti ai tavoli con lucchetto nel lasso di tempo preso in considerazione (ultima settimana, ultimo mese o ultimo trimestre), sommati e divisi per il numero di partite fatte in quello stesso lasso di tempo per normalizzare i valori; poi siccome la gente quando vede 0.18734 sbarella ho deciso di moltiplicare il tutto per 100.
331
332 Un esempio per chiarire:
333
334   l'utente 'pippo' che Ă¨ nuovo gioca 4 partite nell'ultima settimana con i seguenti punteggi:
335     -2, 1, 2, 1
336   lo score viene { [ (-2) + (1) + (2) + (1) ] / 4 }  * 100 = 50.0
337   
338   a paritĂ  di score tra utenti va piĂą in alto chi ha giocato piĂą partite.
339
340 Se dopo quelle 4 partite 'pippo' non ne giocherĂ  piĂą, passata una settimana dall'ultima giocata 
341 sparirĂ  dalla classifica settimanale e rimarrĂ  in quelle mensili e trimestrali.
342
343
344   
345
346
347
348
349  BUG
350  ---
351  
352   DONE - paste da demauroparavia
353   DONE - recupero partita per re-login con password
354   DONE - problema "|" nei nomi (manca enhance degli script lato server)
355   - problema col treno se mouse sopra mentre stringe (verif)
356   
357  MINOR
358  -----
359
360  NORMAL
361  ------
362
363   - win test
364   WIP - /listen 
365     DONE - skin della textarea
366     DONE - set cookie 
367     DONE - init client (read from cookie) - ALWAYS BY SERVER
368     DONE - init server
369     DONE - after cookie check auth-only when no-auth case
370     DONE - aggiungi info accanto a "Chat"
371   DONE - /mesgtoadm
372   DONE - img dei comandi
373
374   DONE - form per garantire utenti (accoda in un file nel formato corretto)
375   DONE -   process request
376   DONE -   show form
377   DONE -   close butt
378   DONE -   submit form
379   DONE -   process form js side 
380   DONE -   process form
381   DONE -   documentazione in help
382
383   DONE - user status
384
385   DONE - aggiornare help
386   DONE -   overflow management
387   DONE -   for status
388   -   for password
389
390   DONE - reload home
391   - notify for long pages
392
393   - buddy list
394   - silenziastolti vari (fino al buddy import)
395   - restrict challenge per IP
396   - restricted charset for login
397   - watchdog
398
399   - db (minimal)
400     - db admin page
401     - user db admin
402     - use db 
403     - admin db
404
405     - studiare un anti-dos
406   - login modify
407  DONE  - db (fake)
408  DONE  - display auth
409     - manage preferences 
410
411  minor
412  -----
413    - auth after login
414
415 ----- done ------
416
417  BUG
418  ---
419   DONE   righe troncate
420   DONE - questione "a monte" che:
421   DONE   - lascia fuori il bottone
422   DONE   - scrive &agrave e compagnia
423   DONE - refresh act_table when unauthorized
424   DONE - problema ghost autenticato (ne prendi il posto ovunque sia)
425
426  MINOR
427  -----
428   DONE - refactoring of the owner name (auth attr for owner name)
429   DONE   - room
430   DONE     - at chat input line 
431   DONE     - in the chat output line
432   DONE     - deauth management
433   DONE - table
434   DONE   - at chat input line
435   DONE   - in the chat output line
436   DONE   - for user area of other users
437   DONE   - deauth management
438   DONE - alart to one user
439
440
441  NORMAL
442  ------
443   DONE - strong ban: "expire time|IP|session|(nick if authenticated)"
444   DONE   - login: se auth      -  verifica solo gli expire per quel nick
445   DONE   -        se non auth  -  verifica gli expire per IP e sessione
446   DONE   - riscrivere messaggi
447
448   DONE - login 
449   DONE   - se pass:
450   DONE     - richiede per l' utente un token (tutta la parte backend va un minimo studiata)
451   DONE     - lo legge, ci hasha la password
452   DONE     - invia la pass al server hashata
453   DONE   - se non pass:
454   DONE     - check del login e return corretto
455   DONE     - oggetto in shm single table con ( "ip", "login", timestamp ) e suo management
456   DONE     - rename ghost if logged
457   DONE     - onunload_cb e onbeforeunload_cb !!! 
458   DONE   - da change attrs a change class (input field)
459   DONE     - colore del bg per arrivare ad essere omogeneo
460   DONE     - cambiare path e file di config
461   DONE   - login with or without pass
462   DONE   - registered nick notice (METTERE IL MSG NELLA PAG DI LOGIN)
463   DONE     - segnalare tavoli solo per auth
464   DONE     - rename restriction at auth table
465   DONE     - change nick (strcasecmp)
466   DONE   - refact js tables to handle flags
467   DONE - room javascript refactoring
468
469   DONE - work background
470   DONE - reserved tables
471
472
473  BRISK2 (spawn)
474  ======
475
476    
477    URGENT - tables spawn
478             DONE - link with photos
479             DONE - top banner in Etc file
480             DONE - spawn of a table
481             DONE - data to cookies (removed table_idx from xhr calls also)
482             DONE - set subst to shutdowner/shutdowned
483             DONE - return to index.php
484             DONE - game's token
485             DONE - recover of corrupted table data
486             DONE - closure of a table
487             DONE - flush of the table
488             DONE - security checks for right scope access
489             DONE - garbage collector management
490             DONE -    recursive garbage - howto ?
491             DONE - stat & subst in browser
492             DONE - laccwr setting and exit if all players are unactive for some time
493             DONE - the list of test case
494             DONE - shm dimension
495             DONE - remove unused parts
496             DONE - move images
497             DONE - optimizations
498             DONE - cambiare titolo al tavolo
499             DONE - shutdowning lock tables
500             DONE - topbanner
501             DONE - public announcements
502             DONE - 10 sec to exit from table
503
504             FAR - inheritances
505    
506    TRAIN  -  DONE - add again in reload   
507              DONE - wag_set refact
508              DONE - filtra char speciali per title
509              DONE - chatt_send refact 
510              DONE - elenco dei giocatori
511              DONE - documentazione online
512              DONE - timeout management     
513              LATER - border color a muzzo
514        
515    NORM   - testament
516    NORM   - public announcements
517    NORM   - 10 sec to exit from table
518    NORM   - moving label for tables click
519
520 ----------------- join -----------------
521    NORM   - map
522
523    NORM   - restart preload img
524    NORM   - tools dir with a main and some pages where check briscola tools.
525    NORM   - watchdog
526
527    NORM   - chat vecchie in reload (forse)
528
529  MIDDLE TODO
530  ===========
531
532    - user assistant (with button to enable disable)
533    - documentation
534
535
536  FAR TODO
537  ========
538    NORM - internationalization
539    NORM - img -> div + css
540    
541  WEB
542  ===
543
544    - link to stable/unstable
545
546 -------------------------------------------------------------------
547  DONE
548  ====
549
550    ABORTED - asta: highlight buttons (css hover) - change pointer when over
551    DONE - step proxy
552    DONE - special chars in js
553    DONE - ban temporaneo dai tavoli
554    DONE - flash player to play sound
555    DONEBUG - (aum. il timeout) - carte giocate che restano girate
556          Sembra non migliorare di molto la cosa, gestita la cache
557          correttamente, sono apposto.
558
559    DONE - one player reject a game, to less points (<= 2)
560    DONE - help page
561    DONE - test di download per la cache
562    DONE - se passano tutti tranne l'ultimo l'asta va al penultimo.
563           Corretto il codice, occorre verificare se questo
564           ingenera qualche problema.
565    DONE - raddoppiato il numero di righe nella chat
566    DONE - corretto bug del /nick
567    DONE - carosello pubblicitĂ  altout
568    DONE - smammamorti
569    DONE - unload of the stream
570    DONE - standup centrati
571    DONE - current player - in info
572    DONE - HELP butt con ABOUT, REGOLE, VERSIONE
573    DONE - welcome lines in the chats (room and table)
574    DONE - welcome lines in the chats (room and table)
575    DONE - nomi in primo piano se vai sul quadrato   
576    DONE - to pass explicit config file to INSTALL.sh
577    DONE - flag to create a config file
578    ABRT - bottoni => immagini
579    DONE - aggiungere bottone al login
580    DONE - nomi in primo piano se vai sul quadrato   
581    DONE - installer to set cookie path
582    DONE - change name
583    DONE - automatic and manual logout
584    DONE - cache problems solved via .htaccess
585    DONE - all players out of the auction
586    DONE - time to send cards
587    DONE - hide cards before sends at a new game
588    DONE - well recognization of the browser and O.S.
589    DONE - login consistency !!!!
590    DONE - functionalization of garbage
591    DONE - call garbage function into login
592    DONE - game
593    DONE - manage the reload from scratch of the table page
594    DONE - table reset
595    DONE - sendcard => card_send(idx, ....)
596    DONE - show table for game
597    DONE - points calculation
598    DONE - make-up of the chooser
599    DONE - where place the briscola on the table
600    DONE - users info
601    DONE - show current auction position
602    DONE - table with internal management of the transition between pages.
603    DONE - server side page abort management  
604    DONE - cookie problem with Ajax
605    DONE - spostare il tasto "esco"
606    DONE - to pass explicit config file to INSTALL.sh 
607    DONE - 8 tables
608    DONE - safety out management
609    DONE - info enhancement and related button (how win the last game and
610           with how much points ?)
611
612  WEB
613    DONE - homepage
614    DONE - screenshots
615
616 DOC
617    CHAPTERS
618       HTTP Streaming
619       Local serializer
620       Database on shmem
621       Page abort (reload on http streaming case)
622       Chat
623       Cookies management
624       CSS tricks
625
626 CHECK ON NEW SERVERS
627 .htaccess AllowOverwrite mode for Cache-Control directive
628
629
630
631
632 */
633