add WebSocket to the TODO list
[brisk.git] / TODO.txt
1  TODO |
2 ------+
3
4   FEATURES |
5  ----------+
6    - WEBSOCKET TRANSPORT
7      . client (xynt_streaming.js)
8      . server (transport.phh)
9
10      M1: xynt_test01.php working
11
12      . manage headers correctly in sac-a-push
13
14    - improved S
15      . db update (add components, maybe single string)
16      . filter in index.php
17      . filter in index_wr.php
18
19    - prefs API:
20      . prefs_assign(content): assign json content as output var
21      . prefs_apply(prefs_new): apply new content to g_prefs and system
22      . prefs_load(content): load json content and apply to g_prefs and system
23
24      . prefs_update: update preferences temporarly
25      . prefs_save: save to the server the new prefs
26
27    - preferences (listen into preferences)
28         // js var, volatile server, (db server || cookie)
29         temporary: js var, volatile server
30         permanent: js var, volatile server, (db server || cookie)
31
32      . data from db OR, if missing, from cookies
33
34      . update values
35      . database change
36      . MANAGE NOT AUTH USERS
37
38    - preferences (with "modifiable S")
39      . Mod. S: new flag into database
40      . graph infrastructure
41      . new box to edit color
42
43   MAJOR |
44  -------+
45    - BUG: some connection to the named socket fails
46    - Not simultaneous more then one stream
47
48
49   MINOR |
50  -------+
51    WIP - try to be more antivirus-friendly
52    - multiple rows between games
53    - packetize and automatize php-ancillary and apache module
54    - DISABLED_TO_FIX: DNS access (perform blocking dns requests, must be fixed)
55
56
57   DONE |
58  ------+
59    DONE - temporarly server hung not reflected on user timeouts
60    DONE - timeouted users are still be able to sit down (only the first at the table is banned)
61    DONE - page still opened after the server restart
62    DONE - log_legal address fix
63    DONE - manage too fast reload in xynt-streaming
64    DONE - add xhr as transport layer and manage different streams better
65    TEST - BUG: pari + 72 non fa 4x ma attualmente fa 3x, da correggere
66    TEST - BUG: lurker are logged out (and remain a pending socket opened (look the spush log)
67    DONE - save/restore database
68    DONE - into the room local step remains -1
69    DONE - centralize all '<script ...' incapsulation to allow multiple transport system.
70    DONE - BUG: access with password from 2 diff browsers the second go in strange "page not found" 
71           in the first tentative, the second works
72    DONE - BUG: access with password from 2 diff browsers place the first in a strict loop (the 
73           problem was a call to a static parent method instead of the overrided child method,
74           substitute self:: with the dynamically get class::)
75    DONE - garbage management
76
77    DONE/FROZEN - problem with getpeer (HOSTADDR)
78
79    DONE - slow cards distribution
80    DONE - substr to mb_substr
81    DONE - parametrizations:
82           . parametrization of $DOCUMENT_ROOT  var in brisk-spush.phh file
83           . parametrization of SITE_PREFIX(_LEN) define
84           . move the name of the named socket into the configuration file
85    DONE - manage and test cross forwarder between table and room
86    DONE - setcookie (for tables only and persist prefs)
87    DONE - images flickering on slow windows: try to poll stream every 300 ms (seems to be download problem)
88    DONE - database connection fails after a while, check close and try PGSQL_CONNECT_FORCE_NEW.
89    DONE - unneeded garbage_time.expired access
90    DONE - BUG: fast loop on stream index_rd_ifra page (js watchdog start without timeout corrupt counts)
91    DONE - BUG: logout failed (fixed with a garbage_collector wrapper at sac-a-push level
92    DONE - 404 wrong page management (remove directories redirections (es. brisk/))
93    DONE - configuration file management
94    DONE - app level keep-alive
95    DONE - index_wr other issues
96    DONE - from room to table
97    DONE - from table to room
98    DONE - chunked
99    DONE - bug: read from a not resource handle (already closed because a new socket substitute it)
100    DONE - partial write for normal page management
101    DONE - index_rd_ifra: last_clean issue
102    DONE - fwrite failed error management (select, buffer where store unsent data, and fwrite check and retry)
103    DONE - bug: after restart index_rd.php receive from prev clients a lot of req
104    DONE - index_wr.php::chat
105    DONE - index_wr.php::exit
106    DONE - index_rd.php porting
107    DONE - generic var management from internet
108    DONE - index.php auth part
109    ABRT - index_wr.php::reload - reload is js-only function
110    ABRT - keepalive management - not interesting for our purposes
111
112  BRISK4 (mammuth)
113  ======
114
115  - STEP MANAGEMENT VERIFY
116  Slim Paragraph
117  DONE - move the garbage timeout on file
118  DONE - in index_rd load all data only when required
119  - briskin5 alignment
120    DONE . extern del garb_timeout
121    DONE . user_load parameters verify
122    DONE . Bin5::load_data and Bin5::save_data refactoring with
123           data split
124    . move many function into "Bin5 class"
125  - garbaging of .step files
126
127  DB: - initial usage
128      DONE - configurabilità file o db
129      DONE - aggiornare le funz di gestione db in modo che prevedano anche il flag DISABLE
130      DONE - travasatore file to pg
131        DONE - travaso punteggi
132        DONE - memorizzazione nuovi i punteggi nel db
133        DONE - gestione classifiche in SQL
134          DONE - produrle
135          DONE - mostrarle
136
137      STEP 1.1
138        DONE - points archiver
139
140      STEP 1.2
141        DONE - partial usability if database go down.
142
143      STEP 1.5
144      - sistema di inserimento nuovi utenti (riversatore da form di inserimento)
145
146      STEP 2
147      - aggiornare le funz di gestione db in modo che prevedano anche il flag SUSPEND
148      - modifica password   
149      - ripristino password 
150
151      STEP 3
152      - comunicazioni di aggiornamento (stato salvato sul server) 
153
154  DONE - var $G_base aggiunta per gestire include in include da path differenti
155
156  BRISK3 (trusty)
157  ======
158   DONE - donameter
159     DONE - G_donors
160     DONE (WOW!) - js object with infos
161     DONE - main logic at login (cookie check in index_rd.php; show_message and createCookie via snippets with block
162            to prevent fast reload)
163     DONE - cookie per non assillare e visualizz.
164     DONE - graphical donameter
165     WIP content (in conf.)
166
167   DONE - numero di tavoli auth-only nel .brisk-install
168   - isolation
169     TEST - ricalcolo delle persone in piedi quando si cambia modalità
170     DONE - se si e' in isolation non si può cambiare nick perdendo l' auth
171     DONE - non leggere le chat di quelli non autenticati (in isolation)
172     DONE - regole per passare alla modalita' (in piedi o ai tavoli autenticati) 
173     DONE - treni non auth da nascondere 
174     DONE - verso gli altri ??: uguale a prima
175
176   finire multilingua (briskin5/index_wr.php e altri se ce ne sono)
177   coniglio
178   only auth strictly
179   placing limits to config file
180
181 Dunque, 
182
183 - come vengono aggiornate le classifiche: ogni giorno alle 23:58
184
185 - cosa cambia tra le tre coppie di classifiche: 
186   ci sono le classifiche dell' ultima settimana, quelle dell' ultimo mese,  e quelle dell' ultimo trimestre,
187   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.
188
189 - 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.
190
191 Un esempio per chiarire:
192
193   l'utente 'pippo' che è nuovo gioca 4 partite nell'ultima settimana con i seguenti punteggi:
194     -2, 1, 2, 1
195   lo score viene { [ (-2) + (1) + (2) + (1) ] / 4 }  * 100 = 50.0
196   
197   a parità di score tra utenti va più in alto chi ha giocato più partite.
198
199 Se dopo quelle 4 partite 'pippo' non ne giocherà più, passata una settimana dall'ultima giocata 
200 sparirà dalla classifica settimanale e rimarrà in quelle mensili e trimestrali.
201
202
203   
204
205
206
207
208  BUG
209  ---
210  
211   DONE - paste da demauroparavia
212   DONE - recupero partita per re-login con password
213   DONE - problema "|" nei nomi (manca enhance degli script lato server)
214   - problema col treno se mouse sopra mentre stringe (verif)
215   
216  MINOR
217  -----
218
219  NORMAL
220  ------
221
222   - win test
223   WIP - /listen 
224     DONE - skin della textarea
225     DONE - set cookie 
226     DONE - init client (read from cookie) - ALWAYS BY SERVER
227     DONE - init server
228     DONE - after cookie check auth-only when no-auth case
229     DONE - aggiungi info accanto a "Chat"
230   DONE - /mesgtoadm
231   DONE - img dei comandi
232
233   DONE - form per garantire utenti (accoda in un file nel formato corretto)
234   DONE -   process request
235   DONE -   show form
236   DONE -   close butt
237   DONE -   submit form
238   DONE -   process form js side 
239   DONE -   process form
240   DONE -   documentazione in help
241
242   DONE - user status
243
244   DONE - aggiornare help
245   DONE -   overflow management
246   DONE -   for status
247   -   for password
248
249   DONE - reload home
250   - notify for long pages
251
252   - buddy list
253   - silenziastolti vari (fino al buddy import)
254   - restrict challenge per IP
255   - restricted charset for login
256   - watchdog
257
258   - db (minimal)
259     - db admin page
260     - user db admin
261     - use db 
262     - admin db
263
264     - studiare un anti-dos
265   - login modify
266  DONE  - db (fake)
267  DONE  - display auth
268     - manage preferences 
269
270  minor
271  -----
272    - auth after login
273
274 ----- done ------
275
276  BUG
277  ---
278   DONE   righe troncate
279   DONE - questione "a monte" che:
280   DONE   - lascia fuori il bottone
281   DONE   - scrive &agrave e compagnia
282   DONE - refresh act_table when unauthorized
283   DONE - problema ghost autenticato (ne prendi il posto ovunque sia)
284
285  MINOR
286  -----
287   DONE - refactoring of the owner name (auth attr for owner name)
288   DONE   - room
289   DONE     - at chat input line 
290   DONE     - in the chat output line
291   DONE     - deauth management
292   DONE - table
293   DONE   - at chat input line
294   DONE   - in the chat output line
295   DONE   - for user area of other users
296   DONE   - deauth management
297   DONE - alart to one user
298
299
300  NORMAL
301  ------
302   DONE - strong ban: "expire time|IP|session|(nick if authenticated)"
303   DONE   - login: se auth      -  verifica solo gli expire per quel nick
304   DONE   -        se non auth  -  verifica gli expire per IP e sessione
305   DONE   - riscrivere messaggi
306
307   DONE - login 
308   DONE   - se pass:
309   DONE     - richiede per l' utente un token (tutta la parte backend va un minimo studiata)
310   DONE     - lo legge, ci hasha la password
311   DONE     - invia la pass al server hashata
312   DONE   - se non pass:
313   DONE     - check del login e return corretto
314   DONE     - oggetto in shm single table con ( "ip", "login", timestamp ) e suo management
315   DONE     - rename ghost if logged
316   DONE     - onunload_cb e onbeforeunload_cb !!! 
317   DONE   - da change attrs a change class (input field)
318   DONE     - colore del bg per arrivare ad essere omogeneo
319   DONE     - cambiare path e file di config
320   DONE   - login with or without pass
321   DONE   - registered nick notice (METTERE IL MSG NELLA PAG DI LOGIN)
322   DONE     - segnalare tavoli solo per auth
323   DONE     - rename restriction at auth table
324   DONE     - change nick (strcasecmp)
325   DONE   - refact js tables to handle flags
326   DONE - room javascript refactoring
327
328   DONE - work background
329   DONE - reserved tables
330
331
332  BRISK2 (spawn)
333  ======
334
335    
336    URGENT - tables spawn
337             DONE - link with photos
338             DONE - top banner in Etc file
339             DONE - spawn of a table
340             DONE - data to cookies (removed table_idx from xhr calls also)
341             DONE - set subst to shutdowner/shutdowned
342             DONE - return to index.php
343             DONE - game's token
344             DONE - recover of corrupted table data
345             DONE - closure of a table
346             DONE - flush of the table
347             DONE - security checks for right scope access
348             DONE - garbage collector management
349             DONE -    recursive garbage - howto ?
350             DONE - stat & subst in browser
351             DONE - laccwr setting and exit if all players are unactive for some time
352             DONE - the list of test case
353             DONE - shm dimension
354             DONE - remove unused parts
355             DONE - move images
356             DONE - optimizations
357             DONE - cambiare titolo al tavolo
358             DONE - shutdowning lock tables
359             DONE - topbanner
360             DONE - public announcements
361             DONE - 10 sec to exit from table
362
363             FAR - inheritances
364    
365    TRAIN  -  DONE - add again in reload   
366              DONE - wag_set refact
367              DONE - filtra char speciali per title
368              DONE - chatt_send refact 
369              DONE - elenco dei giocatori
370              DONE - documentazione online
371              DONE - timeout management     
372              LATER - border color a muzzo
373        
374    NORM   - testament
375    NORM   - public announcements
376    NORM   - 10 sec to exit from table
377    NORM   - moving label for tables click
378
379 ----------------- join -----------------
380    NORM   - map
381
382    NORM   - restart preload img
383    NORM   - tools dir with a main and some pages where check briscola tools.
384    NORM   - watchdog
385
386    NORM   - chat vecchie in reload (forse)
387
388  MIDDLE TODO
389  ===========
390
391    - user assistant (with button to enable disable)
392    - documentation
393
394
395  FAR TODO
396  ========
397    NORM - internationalization
398    NORM - img -> div + css
399    
400  WEB
401  ===
402
403    - link to stable/unstable
404
405 -------------------------------------------------------------------
406  DONE
407  ====
408
409    ABORTED - asta: highlight buttons (css hover) - change pointer when over
410    DONE - step proxy
411    DONE - special chars in js
412    DONE - ban temporaneo dai tavoli
413    DONE - flash player to play sound
414    DONEBUG - (aum. il timeout) - carte giocate che restano girate
415          Sembra non migliorare di molto la cosa, gestita la cache
416          correttamente, sono apposto.
417
418    DONE - one player reject a game, to less points (<= 2)
419    DONE - help page
420    DONE - test di download per la cache
421    DONE - se passano tutti tranne l'ultimo l'asta va al penultimo.
422           Corretto il codice, occorre verificare se questo
423           ingenera qualche problema.
424    DONE - raddoppiato il numero di righe nella chat
425    DONE - corretto bug del /nick
426    DONE - carosello pubblicità altout
427    DONE - smammamorti
428    DONE - unload of the stream
429    DONE - standup centrati
430    DONE - current player - in info
431    DONE - HELP butt con ABOUT, REGOLE, VERSIONE
432    DONE - welcome lines in the chats (room and table)
433    DONE - welcome lines in the chats (room and table)
434    DONE - nomi in primo piano se vai sul quadrato   
435    DONE - to pass explicit config file to INSTALL.sh
436    DONE - flag to create a config file
437    ABRT - bottoni => immagini
438    DONE - aggiungere bottone al login
439    DONE - nomi in primo piano se vai sul quadrato   
440    DONE - installer to set cookie path
441    DONE - change name
442    DONE - automatic and manual logout
443    DONE - cache problems solved via .htaccess
444    DONE - all players out of the auction
445    DONE - time to send cards
446    DONE - hide cards before sends at a new game
447    DONE - well recognization of the browser and O.S.
448    DONE - login consistency !!!!
449    DONE - functionalization of garbage
450    DONE - call garbage function into login
451    DONE - game
452    DONE - manage the reload from scratch of the table page
453    DONE - table reset
454    DONE - sendcard => card_send(idx, ....)
455    DONE - show table for game
456    DONE - points calculation
457    DONE - make-up of the chooser
458    DONE - where place the briscola on the table
459    DONE - users info
460    DONE - show current auction position
461    DONE - table with internal management of the transition between pages.
462    DONE - server side page abort management  
463    DONE - cookie problem with Ajax
464    DONE - spostare il tasto "esco"
465    DONE - to pass explicit config file to INSTALL.sh 
466    DONE - 8 tables
467    DONE - safety out management
468    DONE - info enhancement and related button (how win the last game and
469           with how much points ?)
470
471  WEB
472    DONE - homepage
473    DONE - screenshots
474
475 DOC
476    CHAPTERS
477       HTTP Streaming
478       Local serializer
479       Database on shmem
480       Page abort (reload on http streaming case)
481       Chat
482       Cookies management
483       CSS tricks
484
485 CHECK ON NEW SERVERS
486 .htaccess AllowOverwrite mode for Cache-Control directive
487
488
489
490
491 */
492