oh-my-dear-ai commited on
Commit
1ff3947
Β·
1 Parent(s): fbb4dba

fix(app): correct task completion tracking and update CSV

Browse files

Correct the task completion logic in process_data function to match the intended behavior
by updating how plant_tasks_done list is populated. Also, reordering fanwort and lady' mantle

CHANGELOG.md CHANGED
@@ -5,3 +5,4 @@
5
  - 24/09/04: Correct Radiant count for water hyacinth
6
  - 24/09/05: Support image generated by plotly
7
  - 24/09/13: Update Water Lily tasks and color options
 
 
5
  - 24/09/04: Correct Radiant count for water hyacinth
6
  - 24/09/05: Support image generated by plotly
7
  - 24/09/13: Update Water Lily tasks and color options
8
+ - 24/09/15: Fixed a very silly bug caused by mistakenly using n instead of i, which led to data corruption
app.py CHANGED
@@ -88,7 +88,7 @@ def process_data(*args):
88
  plant_tasks_done = [0 for _ in range(len(TASKS))]
89
 
90
  for n, i in enumerate(plant_tasks):
91
- plant_tasks_done[n] = 1
92
  almanac_df.loc[almanac_df["plant"] == pl, TASKS[i]] = "βœ”"
93
 
94
  almanac_bin_ls += plant_tasks_done
@@ -389,6 +389,7 @@ if __name__ == "__main__":
389
  - 2024/09/04: Correct Radiant count for water hyacinth
390
  - 2024/09/05: Support image generated by plotly
391
  - 2024/09/13: Update Water Lily tasks and color options
 
392
  """
393
  )
394
 
 
88
  plant_tasks_done = [0 for _ in range(len(TASKS))]
89
 
90
  for n, i in enumerate(plant_tasks):
91
+ plant_tasks_done[i] = 1
92
  almanac_df.loc[almanac_df["plant"] == pl, TASKS[i]] = "βœ”"
93
 
94
  almanac_bin_ls += plant_tasks_done
 
389
  - 2024/09/04: Correct Radiant count for water hyacinth
390
  - 2024/09/05: Support image generated by plotly
391
  - 2024/09/13: Update Water Lily tasks and color options
392
+ - 2024/09/15: Fixed a very silly bug caused by mistakenly using n instead of i, which led to data corruption
393
  """
394
  )
395
 
herbologist_almanac_checklist_data.csv CHANGED
@@ -1,12 +1,12 @@
1
- plant,name,sort,HARVEST_score>100,task1,state1,task2,state2,task3,state3,task4,state4,color1,color2,color3,color4,color5,color6,count,is_combat,is_land,level, growth_cycle
2
  fanged_geranium,Fanged Geranium,1,False,Provide 100 MOISTURE points,100,SELL 5,5,HARVEST 10 Radiant,10,HARVEST 100,100,,,,,,,5,1,1,0,12
3
  gillyweed,Gillyweed,2,False,HARVEST 10,10,"Provide 5,000 HYGIENE points",5000,HARVEST 10 in the black Lake,10,SELL 25 Radiant,25,,,,,,,5,0,0,1,6
4
  rose,Rose,3,False,HARVEST 5 in non-default color,5,SELL 10 Flourishing or above,10,COLLECT 10 starters,10,HARVEST 30 Flourishing or above,30,red,yellow,pink,blue,white,black,11,0,1,2,24
5
  puffapod,Puffapod,4,False,HARVEST 1 with MOISTURE never reaching 0,False,HARVEST 5,False,HARVEST 10 Radiant,False,"Provide 30,000 MOISTURE points",False,,,,,,,5,1,1,3,48
6
  wild_pansy,Wild Pansy,4,False,Remove 10 PESTS,10,Show off 1 rare-colored,1,HARVEST 30 Radiant,30,SELL 10 rare-colored,10,turquoise,yellow,orange,pink,white,purple,11,0,1,3,48
7
  nifflers_fancy,Niffler's Fancy,5,False,COLLECT 1 starter,1,Make 100 gems from SELLing,100,SELL 5 Radiant,5,HARVEST 15 Radiant,15,,,,,,,5,0,1,4,72
8
- ladys_mantle,Lady's Mantle,6,False,HARVEST 1 special color,1,HARVEST 5 Flourishing or above,5,HARVEST 3 special color,3,"Accumulate 80,000 LIGHT points",80000,yellow,white,orange,turquoise,viridian,purple,11,0,1,5,48
9
  fanwort,Fanwort,6,False,HARVEST 45 never damaged by PESTS,45,"Accumulate 10,000 LIGHT points",10000,SELL 150 Radiant,150,HARVEST 100 in non-default colors,100,chartreuse,orange,red,turquoise,purple,white,11,0,0,5,60
 
10
  mandrake,Mandrake,7,False,Remove 50 PESTS,50,Show off 1 Radiant,1,SELL 200 Flourishing or above,200,HARVEST 500,500,,,,,,,5,1,1,6,24
11
  kelp,Kelp,7,False,Remove 30 PESTS,30,"Provide 5,000 MOOD points",5000,HARVEST 150 in the black Lake,150,SELL 300 Radiant,300,chartreuse,turquoise,orange,purple,pink,red,11,0,0,6,24
12
  cabbage,Cabbage,8,False,HARVEST 5 with MOOD over 60,5,"Provide 50,000 MOOD points",50000,SELL 100 Radiant,100,"HARVEST 1,000",1000,,,,,,,5,1,1,7,36
 
1
+ plant,name,sort,HARVEST_score>100,task1,state1,task2,state2,task3,state3,task4,state4,color1,color2,color3,color4,color5,color6,count,is_combat,is_land,level,growth_cycle
2
  fanged_geranium,Fanged Geranium,1,False,Provide 100 MOISTURE points,100,SELL 5,5,HARVEST 10 Radiant,10,HARVEST 100,100,,,,,,,5,1,1,0,12
3
  gillyweed,Gillyweed,2,False,HARVEST 10,10,"Provide 5,000 HYGIENE points",5000,HARVEST 10 in the black Lake,10,SELL 25 Radiant,25,,,,,,,5,0,0,1,6
4
  rose,Rose,3,False,HARVEST 5 in non-default color,5,SELL 10 Flourishing or above,10,COLLECT 10 starters,10,HARVEST 30 Flourishing or above,30,red,yellow,pink,blue,white,black,11,0,1,2,24
5
  puffapod,Puffapod,4,False,HARVEST 1 with MOISTURE never reaching 0,False,HARVEST 5,False,HARVEST 10 Radiant,False,"Provide 30,000 MOISTURE points",False,,,,,,,5,1,1,3,48
6
  wild_pansy,Wild Pansy,4,False,Remove 10 PESTS,10,Show off 1 rare-colored,1,HARVEST 30 Radiant,30,SELL 10 rare-colored,10,turquoise,yellow,orange,pink,white,purple,11,0,1,3,48
7
  nifflers_fancy,Niffler's Fancy,5,False,COLLECT 1 starter,1,Make 100 gems from SELLing,100,SELL 5 Radiant,5,HARVEST 15 Radiant,15,,,,,,,5,0,1,4,72
 
8
  fanwort,Fanwort,6,False,HARVEST 45 never damaged by PESTS,45,"Accumulate 10,000 LIGHT points",10000,SELL 150 Radiant,150,HARVEST 100 in non-default colors,100,chartreuse,orange,red,turquoise,purple,white,11,0,0,5,60
9
+ ladys_mantle,Lady's Mantle,6,False,HARVEST 1 special color,1,HARVEST 5 Flourishing or above,5,HARVEST 3 special color,3,"Accumulate 80,000 LIGHT points",80000,yellow,white,orange,turquoise,viridian,purple,11,0,1,5,48
10
  mandrake,Mandrake,7,False,Remove 50 PESTS,50,Show off 1 Radiant,1,SELL 200 Flourishing or above,200,HARVEST 500,500,,,,,,,5,1,1,6,24
11
  kelp,Kelp,7,False,Remove 30 PESTS,30,"Provide 5,000 MOOD points",5000,HARVEST 150 in the black Lake,150,SELL 300 Radiant,300,chartreuse,turquoise,orange,purple,pink,red,11,0,0,6,24
12
  cabbage,Cabbage,8,False,HARVEST 5 with MOOD over 60,5,"Provide 50,000 MOOD points",50000,SELL 100 Radiant,100,"HARVEST 1,000",1000,,,,,,,5,1,1,7,36