LmeSzinc / AzurLaneAutoScript

Azur Lane bot (CN/EN/JP/TW) 碧蓝航线脚本 | 无缝委托科研,全自动大世界
https://alas.azurlane.cloud
GNU General Public License v3.0
6.91k stars 831 forks source link

船坞满了强化出错 #1540

Open Moment0901 opened 2 years ago

Moment0901 commented 2 years ago

在提问之前...

描述你的问题

挂着活动图sp3的时候船坞满了,强化的时候出错。一次是没强化,一次是强化了没返回去刷图直接报错了

如何复现

  1. 前往 '...'
  2. 点击 '....'
  3. 滑动到 '....'
  4. 出现问题

预期行为

No response

相关 Logs

═══════════════════════════════════════════════════════════════════════════════════════════════════════════════════════
                                                         EVENT                                                         
═══════════════════════════════════════════════════════════════════════════════════════════════════════════════════════

═════════════════════════════════════════════════════════ SP3 ═════════════════════════════════════════════════════════
2022-08-19 16:12:55.318 | INFO | SP3                                                                                   
2022-08-19 16:12:55.321 | INFO | Count: 2                                                                              
2022-08-19 16:12:55.326 | INFO | In auto search menu, skip ensure_campaign_ui.                                         
───────────────────────────────────────────────────────── SP3 ─────────────────────────────────────────────────────────
2022-08-19 16:12:55.334 | INFO | SP3                                                                                   
2022-08-19 16:12:55.336 | INFO | Expect emotion reduce: (0, 12)                                                        
2022-08-19 16:12:55.353 | INFO | Bind task {'General', 'EventGeneral', 'Event', 'Alas'}                                
2022-08-19 16:12:55.356 | INFO | Save config ./config\alas.json, Event.Emotion.Fleet1Value=139,                        
Event.Emotion.Fleet1Record=datetime.datetime(2022, 8, 19, 16, 12, 55), Event.Emotion.Fleet2Value=122,                  
Event.Emotion.Fleet2Record=datetime.datetime(2022, 8, 19, 16, 12, 55)                                                  
2022-08-19 16:12:55.368 | INFO | [Emotion fleet_1] 139                                                                 
2022-08-19 16:12:55.370 | INFO | [Emotion fleet_2] 122                                                                 
2022-08-19 16:12:55.373 | INFO | <<< ENTER MAP >>>                                                                     
2022-08-19 16:12:55.381 | INFO | Handling 2x book setting, mode=auto.                                                  
2022-08-19 16:12:55.530 | INFO | Click ( 846,  627) @ AUTO_SEARCH_MENU_CONTINUE                                        
────────────────────────────────────────────────────── BATTLE_0 ───────────────────────────────────────────────────────
2022-08-19 16:12:57.162 | INFO | BATTLE_0                                                                              
2022-08-19 16:12:57.165 | INFO | Auto search moving                                                                    
2022-08-19 16:12:57.168 | INFO | Fleet: 1, fleet_current_index: 2                                                      
2022-08-19 16:12:57.207 | INFO | [OCR_OIL 0.037s] 11661                                                                
2022-08-19 16:13:00.206 | INFO | Fleet: 2, fleet_current_index: 1                                                      
2022-08-19 16:13:02.675 | INFO | [Loading] 6%                                                                          
2022-08-19 16:13:02.677 | INFO | Auto search combat loading                                                            
2022-08-19 16:13:02.679 | INFO | Screenshot interval set to 1.0s                                                       
2022-08-19 16:13:10.660 | INFO | Auto Search combat execute                                                            
2022-08-19 16:13:10.663 | INFO | <<< EMOTION REDUCE >>>                                                                
2022-08-19 16:13:10.678 | INFO | Bind task {'General', 'EventGeneral', 'Event', 'Alas'}                                
2022-08-19 16:13:10.681 | INFO | Save config ./config\alas.json, Event.Emotion.Fleet1Value=139,                        
Event.Emotion.Fleet1Record=datetime.datetime(2022, 8, 19, 16, 13, 10), Event.Emotion.Fleet2Value=120,                  
Event.Emotion.Fleet2Record=datetime.datetime(2022, 8, 19, 16, 13, 10)                                                  
2022-08-19 16:13:10.693 | INFO | [Emotion fleet_1] 139                                                                 
2022-08-19 16:13:10.695 | INFO | [Emotion fleet_2] 120                                                                 
2022-08-19 16:13:16.565 | INFO | Combat auto check timer reached                                                       
2022-08-19 16:13:35.622 | INFO | Screenshot interval set to 0.3s                                                       
2022-08-19 16:13:35.624 | INFO | Auto Search combat status                                                             
2022-08-19 16:13:37.589 | INFO | Combat end.                                                                           
────────────────────────────────────────────────────── BATTLE_1 ───────────────────────────────────────────────────────
2022-08-19 16:13:37.592 | INFO | BATTLE_1                                                                              
2022-08-19 16:13:37.595 | INFO | Auto search moving                                                                    
2022-08-19 16:13:37.598 | INFO | Fleet: 2, fleet_current_index: 1                                                      
2022-08-19 16:13:37.634 | INFO | [OCR_OIL 0.035s] 11644                                                                
2022-08-19 16:13:40.923 | INFO | Click ( 830,  513) @ RETIRE_APPEAR_3                                                  
2022-08-19 16:13:43.580 | INFO | <<< ENHANCEMENT BY TYPE >>>                                                           
2022-08-19 16:13:43.583 | INFO | [Enhance Order] [None]                                                                
2022-08-19 16:13:43.585 | INFO | Favourite=False, Ship Type=None                                                       
2022-08-19 16:13:43.588 | INFO | <<< UI CLICK >>>                                                                      
2022-08-19 16:13:43.599 | INFO | Click (1169,   16) @ DOCK_FILTER                                                      
2022-08-19 16:13:44.184 | INFO | Setting dock filter, sort=level, index=all, faction=all, rarity=all, extra=no_limit   
2022-08-19 16:13:44.196 | INFO | Setting dock filter, sort=level, index=all, faction=all, rarity=all, extra=enhanceable
2022-08-19 16:13:44.205 | INFO | Click ( 777,  485) @ FILTER_EXTRA_3_0                                                 
2022-08-19 16:13:44.430 | INFO | Setting dock filter, sort=level, index=all, faction=all, rarity=all, extra=enhanceable
2022-08-19 16:13:44.549 | INFO | Click ( 538,   79) @ FILTER_SORT_1_0                                                  
2022-08-19 16:13:44.742 | INFO | Click ( 378,  165) @ FILTER_INDEX_0_0                                                 
2022-08-19 16:13:44.940 | INFO | Click ( 336,  284) @ FILTER_FACTION_0_0                                               
2022-08-19 16:13:45.143 | INFO | Click ( 369,  419) @ FILTER_RARITY_0_0                                                
2022-08-19 16:13:45.347 | INFO | Click ( 822,  495) @ FILTER_EXTRA_3_0                                                 
2022-08-19 16:13:45.579 | INFO | Setting dock filter, sort=level, index=all, faction=all, rarity=all, extra=enhanceable
2022-08-19 16:13:45.797 | INFO | Click ( 840,  482) @ FILTER_EXTRA_3_0                                                 
2022-08-19 16:13:46.025 | INFO | Setting dock filter, sort=level, index=all, faction=all, rarity=all, extra=enhanceable
2022-08-19 16:13:46.227 | INFO | <<< UI CLICK >>>                                                                      
2022-08-19 16:13:46.232 | INFO | Click ( 778,  643) @ DOCK_FILTER_CONFIRM                                              
2022-08-19 16:13:48.332 | INFO | Click ( 176,  159) @ CARD_0_0                                                         
2022-08-19 16:13:49.206 | INFO | Call state function: state_enhance_check                                              
2022-08-19 16:13:49.209 | INFO | DETAIL_SIDE_NAVBAR set to right=4 bottom=4                                            
2022-08-19 16:13:49.212 | INFO | Nav item active: 1 from range (0, 4)                                                  
2022-08-19 16:13:49.399 | INFO | Call state function: state_enhance_ready                                              
2022-08-19 16:13:49.818 | INFO | Call state function: state_enhance_ready                                              
2022-08-19 16:13:49.820 | INFO | Click (1006,  619) @ ENHANCE_RECOMMEND                                                
2022-08-19 16:13:49.874 | INFO | Set enhancement material by recommendation.                                           
2022-08-19 16:13:50.084 | INFO | Call state function: state_enhance_recommend                                          
2022-08-19 16:13:50.310 | INFO | Call state function: state_enhance_ready                                              
2022-08-19 16:13:50.599 | INFO | Call state function: state_enhance_ready                                              
2022-08-19 16:13:50.999 | INFO | Call state function: state_enhance_ready                                              
2022-08-19 16:13:51.001 | INFO | Click (1047,  613) @ ENHANCE_RECOMMEND                                                
2022-08-19 16:13:51.054 | INFO | Set enhancement material by recommendation.                                           
2022-08-19 16:13:51.307 | INFO | Call state function: state_enhance_recommend                                          
2022-08-19 16:13:51.310 | INFO | Material found. Try enhancing...                                                      
2022-08-19 16:13:51.644 | INFO | Call state function: state_enhance_attempt                                            
2022-08-19 16:13:51.653 | INFO | Click (1212,  615) @ ENHANCE_CONFIRM                                                  
2022-08-19 16:13:51.850 | INFO | Call state function: state_enhance_confirm                                            
2022-08-19 16:13:52.220 | INFO | Call state function: state_enhance_attempt                                            
2022-08-19 16:13:52.223 | INFO | Click (1182,  620) @ ENHANCE_CONFIRM                                                  
2022-08-19 16:13:52.501 | INFO | Call state function: state_enhance_confirm                                            
2022-08-19 16:13:52.506 | INFO | Enhancement impossible, ship currently in battle. Swiping to next ship if feasible    
2022-08-19 16:13:52.700 | INFO | Call state function: state_enhance_fail                                               
2022-08-19 16:13:55.846 | INFO | Swipe ( 496,  269) -> ( 250,  265)                                                    
2022-08-19 16:13:57.292 | INFO | New ship detected on swipe                                                            
2022-08-19 16:13:57.459 | INFO | Call state function: state_enhance_check                                              
2022-08-19 16:13:57.462 | WARNING | Too few nav items found in DETAIL_SIDE_NAVBAR, items: []                           
2022-08-19 16:13:57.465 | ERROR | TypeError: unsupported operand type(s) for -: 'NoneType' and 'NoneType'              
┌───────────────────────────────────────── Traceback (most recent call last) ─────────────────────────────────────────┐
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\alas.py:62 in run                                                               │
│                                                                                                                     │
│    59 │   def run(self, command):                                                                                   │
│    60 │   │   try:                                                                                                  │
│    61 │   │   │   self.device.screenshot()                                                                          │
│ >  62 │   │   │   self.__getattribute__(command)()                                                                  │
│    63 │   │   │   return True                                                                                       │
│    64 │   │   except TaskEnd:                                                                                       │
│    65 │   │   │   return True                                                                                       │
│                                                                                                                     │
│ ┌────────────────────────────────────── locals ───────────────────────────────────────┐                             │
│ │ command = 'event'                                                                   │                             │
│ │       e = TypeError("unsupported operand type(s) for -: 'NoneType' and 'NoneType'") │                             │
│ │    self = <alas.AzurLaneAutoScript object at 0x000002CE5D6468C8>                    │                             │
│ └─────────────────────────────────────────────────────────────────────────────────────┘                             │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\alas.py:319 in event                                                            │
│                                                                                                                     │
│   316 │   def event(self):                                                                                          │
│   317 │   │   from module.campaign.run import CampaignRun                                                           │
│   318 │   │   CampaignRun(config=self.config, device=self.device).run(                                              │
│ > 319 │   │   │   name=self.config.Campaign_Name, folder=self.config.Campaign_Event,                                │
│       mode=self.config.Campaign_Mode)                                                                               │
│   320 │                                                                                                             │
│   321 │   def event2(self):                                                                                         │
│   322 │   │   from module.campaign.run import CampaignRun                                                           │
│                                                                                                                     │
│ ┌─────────────────────────────── locals ───────────────────────────────┐                                            │
│ │ CampaignRun = <class 'module.campaign.run.CampaignRun'>              │                                            │
│ │        self = <alas.AzurLaneAutoScript object at 0x000002CE5D6468C8> │                                            │
│ └──────────────────────────────────────────────────────────────────────┘                                            │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\campaign\run.py:254 in run                                               │
│                                                                                                                     │
│   251 │   │   │                                                                                                     │
│   252 │   │   │   # Run                                                                                             │
│   253 │   │   │   try:                                                                                              │
│ > 254 │   │   │   │   self.campaign.run()                                                                           │
│   255 │   │   │   except ScriptEnd as e:                                                                            │
│   256 │   │   │   │   logger.hr('Script end')                                                                       │
│   257 │   │   │   │   logger.info(str(e))                                                                           │
│                                                                                                                     │
│ ┌──────────────────────────────── locals ─────────────────────────────────┐                                         │
│ │ folder = 'event_20220818_cn'                                            │                                         │
│ │   mode = 'normal'                                                       │                                         │
│ │   name = 'sp3'                                                          │                                         │
│ │   self = <module.campaign.run.CampaignRun object at 0x000002CE3E3C5148> │                                         │
│ │  total = 0                                                              │                                         │
│ └─────────────────────────────────────────────────────────────────────────┘                                         │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\campaign\campaign_base.py:143 in run                                     │
│                                                                                                                     │
│   140 │   │   │   │   if not self.map_is_auto_search:                                                               │
│   141 │   │   │   │   │   self.execute_a_battle()                                                                   │
│   142 │   │   │   │   else:                                                                                         │
│ > 143 │   │   │   │   │   self.auto_search_execute_a_battle()                                                       │
│   144 │   │   │   except CampaignEnd:                                                                               │
│   145 │   │   │   │   logger.hr('Campaign end')                                                                     │
│   146 │   │   │   │   return True                                                                                   │
│                                                                                                                     │
│ ┌─────────────────────────────────── locals ────────────────────────────────────┐                                   │
│ │    _ = 1                                                                      │                                   │
│ │ self = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488> │                                   │
│ └───────────────────────────────────────────────────────────────────────────────┘                                   │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\campaign\campaign_base.py:174 in auto_search_execute_a_battle            │
│                                                                                                                     │
│   171 │                                                                                                             │
│   172 │   def auto_search_execute_a_battle(self):                                                                   │
│   173 │   │   logger.hr(f'{self.FUNCTION_NAME_BASE}{self.battle_count}', level=2)                                   │
│ > 174 │   │   self.auto_search_moving()                                                                             │
│   175 │   │   self.auto_search_combat(fleet_index=self.fleet_show_index)                                            │
│   176 │   │   self.battle_count += 1                                                                                │
│   177                                                                                                               │
│                                                                                                                     │
│ ┌─────────────────────────────────── locals ────────────────────────────────────┐                                   │
│ │ self = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488> │                                   │
│ └───────────────────────────────────────────────────────────────────────────────┘                                   │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\combat\auto_search_combat.py:156 in auto_search_moving                   │
│                                                                                                                     │
│   153 │   │   │   if self.is_auto_search_running():                                                                 │
│   154 │   │   │   │   checked_fleet = self.auto_search_watch_fleet(checked_fleet)                                   │
│   155 │   │   │   │   checked_oil = self.auto_search_watch_oil(checked_oil)                                         │
│ > 156 │   │   │   if self.handle_retirement():                                                                      │
│   157 │   │   │   │   self.map_offensive_auto_search()                                                              │
│   158 │   │   │   │   continue                                                                                      │
│   159 │   │   │   if self.handle_auto_search_map_option():                                                          │
│                                                                                                                     │
│ ┌──────────────────────────────────────────── locals ────────────────────────────────────────────┐                  │
│ │         checked_fleet = True                                                                   │                  │
│ │           checked_oil = True                                                                   │                  │
│ │                  self = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488> │                  │
│ │ skip_first_screenshot = False                                                                  │                  │
│ └────────────────────────────────────────────────────────────────────────────────────────────────┘                  │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\retire\retirement.py:270 in handle_retirement                            │
│                                                                                                                     │
│   267 │   │   │   │   return False                                                                                  │
│   268 │   │   │   if self.appear(DOCK_CHECK, offset=(20, 20), interval=10):                                         │
│   269 │   │   │   │   self.handle_dock_cards_loading()                                                              │
│ > 270 │   │   │   │   total, remain = self._enhance_handler()                                                       │
│   271 │   │   │   │   if not total:                                                                                 │
│   272 │   │   │   │   │   logger.info(                                                                              │
│   273 │   │   │   │   │   │   'No ship to enhance, but dock full, will try retire')                                 │
│                                                                                                                     │
│ ┌─────────────────────────────────── locals ────────────────────────────────────┐                                   │
│ │ self = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488> │                                   │
│ └───────────────────────────────────────────────────────────────────────────────┘                                   │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\retire\enhancement.py:340 in _enhance_handler                            │
│                                                                                                                     │
│   337 │   │   │   in: DOCK_CHECK                                                                                    │
│   338 │   │   │   out: the page before retirement popup                                                             │
│   339 │   │   """                                                                                                   │
│ > 340 │   │   total = self.enhance_ships()                                                                          │
│   341 │   │   _, remain, _ = OCR_DOCK_AMOUNT.ocr(self.device.image)                                                 │
│   342 │   │                                                                                                         │
│   343 │   │   self.dock_quit()                                                                                      │
│                                                                                                                     │
│ ┌─────────────────────────────────── locals ────────────────────────────────────┐                                   │
│ │ self = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488> │                                   │
│ └───────────────────────────────────────────────────────────────────────────────┘                                   │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\retire\enhancement.py:316 in enhance_ships                               │
│                                                                                                                     │
│   313 │   │   │   current_count = self.config.Retirement_EnhanceCheckPerCategory                                    │
│   314 │   │   │   while 1:                                                                                          │
│   315 │   │   │   │   choose_result, current_count = self._enhance_choose(                                          │
│ > 316 │   │   │   │   │   ship_count=current_count)                                                                 │
│   317 │   │   │   │   if not choose_result:                                                                         │
│   318 │   │   │   │   │   break                                                                                     │
│   319 │   │   │   │   total += 10                                                                                   │
│                                                                                                                     │
│ ┌─────────────────────────────────────────── locals ────────────────────────────────────────────┐                   │
│ │ available_ship_types = ['dd', 'ss', 'cl', 'ca', 'bb', 'cv', 'repair', 'others']               │                   │
│ │        current_count = 2                                                                      │                   │
│ │            favourite = False                                                                  │                   │
│ │                 self = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488> │                   │
│ │            ship_type = None                                                                   │                   │
│ │           ship_types = [None]                                                                 │                   │
│ │                total = 0                                                                      │                   │
│ └───────────────────────────────────────────────────────────────────────────────────────────────┘                   │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\retire\enhancement.py:244 in _enhance_choose                             │
│                                                                                                                     │
│   241 │   │   │   │   raise ScriptError('Too many state transitions')                                               │
│   242 │   │   │                                                                                                     │
│   243 │   │   │   try:                                                                                              │
│ > 244 │   │   │   │   state = locals()[state]()                                                                     │
│   245 │   │   │   except KeyError as e:                                                                             │
│   246 │   │   │   │   logger.warning(f'Unknown state function: {state}')                                            │
│   247 │   │   │   │   raise ScriptError(f'Unknown state function: {state}')                                         │
│                                                                                                                     │
│ ┌──────────────────────────────────────────────────── locals ─────────────────────────────────────────────────────┐ │
│ │            need_to_skip = False                                                                                 │ │
│ │                    self = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488>                │ │
│ │              ship_count = 2                                                                                     │ │
│ │   skip_first_screenshot = False                                                                                 │ │
│ │                   state = 'state_enhance_check'                                                                 │ │
│ │   state_enhance_attempt = <function Enhancement._enhance_choose.<locals>.state_enhance_attempt at               │ │
│ │                           0x000002CE3E2700D8>                                                                   │ │
│ │     state_enhance_check = <function Enhancement._enhance_choose.<locals>.state_enhance_check at                 │ │
│ │                           0x000002CE3E9F1D38>                                                                   │ │
│ │   state_enhance_confirm = <function Enhancement._enhance_choose.<locals>.state_enhance_confirm at               │ │
│ │                           0x000002CE3E270168>                                                                   │ │
│ │      state_enhance_exit = <function Enhancement._enhance_choose.<locals>.state_enhance_exit at                  │ │
│ │                           0x000002CE3E2703A8>                                                                   │ │
│ │      state_enhance_fail = <function Enhancement._enhance_choose.<locals>.state_enhance_fail at                  │ │
│ │                           0x000002CE3E2701F8>                                                                   │ │
│ │     state_enhance_ready = <function Enhancement._enhance_choose.<locals>.state_enhance_ready at                 │ │
│ │                           0x000002CE3E270048>                                                                   │ │
│ │ state_enhance_recommend = <function Enhancement._enhance_choose.<locals>.state_enhance_recommend at             │ │
│ │                           0x000002CE3E270288>                                                                   │ │
│ │   state_enhance_success = <function Enhancement._enhance_choose.<locals>.state_enhance_success at               │ │
│ │                           0x000002CE3E270318>                                                                   │ │
│ │              state_list = ['state_enhance_check']                                                               │ │
│ └─────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘ │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\retire\enhancement.py:142 in state_enhance_check                         │
│                                                                                                                     │
│   139 │   │   │   │   logger.info(                                                                                  │
│   140 │   │   │   │   │   'Reached maximum number to check, exiting current category')                              │
│   141 │   │   │   │   return "state_enhance_exit"                                                                   │
│ > 142 │   │   │   if not self.equip_side_navbar_ensure(bottom=4):                                                   │
│   143 │   │   │   │   return "state_enhance_check"                                                                  │
│   144 │   │   │                                                                                                     │
│   145 │   │   │   self.wait_until_appear(ENHANCE_RECOMMEND, offset=(                                                │
│                                                                                                                     │
│ ┌─────────────────────────────────────── locals ────────────────────────────────────────┐                           │
│ │ need_to_skip = False                                                                  │                           │
│ │         self = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488> │                           │
│ │   ship_count = 2                                                                      │                           │
│ └───────────────────────────────────────────────────────────────────────────────────────┘                           │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\equipment\equipment.py:129 in equip_side_navbar_ensure                   │
│                                                                                                                     │
│   126 │   │   Returns:                                                                                              │
│   127 │   │   │   bool: if side_navbar set ensured                                                                  │
│   128 │   │   """                                                                                                   │
│ > 129 │   │   if self._equip_side_navbar.get_total(main=self) == 3:                                                 │
│   130 │   │   │   if upper == 1 or bottom == 3:                                                                     │
│   131 │   │   │   │   logger.warning('Transitions to "research" is not supported')                                  │
│   132 │   │   │   │   return False                                                                                  │
│                                                                                                                     │
│ ┌──────────────────────────────────── locals ─────────────────────────────────────┐                                 │
│ │ bottom = 4                                                                      │                                 │
│ │   self = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488> │                                 │
│ │  upper = None                                                                   │                                 │
│ └─────────────────────────────────────────────────────────────────────────────────┘                                 │
│                                                                                                                     │
│ D:\AlasApp_0.3.7\AzurLaneAutoScript\module\ui\navbar.py:86 in get_total                                             │
│                                                                                                                     │
│    83 │   │   │   int: Numbers of nav items that appears                                                            │
│    84 │   │   """                                                                                                   │
│    85 │   │   _, left, right = self.get_info(main=main)                                                             │
│ >  86 │   │   return right - left + 1                                                                               │
│    87 │                                                                                                             │
│    88 │   def set(self, main, left=None, right=None, upper=None, bottom=None,                                       │
│       skip_first_screenshot=True):                                                                                  │
│    89 │   │   """                                                                                                   │
│                                                                                                                     │
│ ┌──────────────────────────────────── locals ────────────────────────────────────┐                                  │
│ │     _ = None                                                                   │                                  │
│ │  left = None                                                                   │                                  │
│ │  main = <campaign.event_20220818_cn.sp3.Campaign object at 0x000002CE3E111488> │                                  │
│ │ right = None                                                                   │                                  │
│ │  self = <module.ui.navbar.Navbar object at 0x000002CE3E24E688>                 │                                  │
│ └────────────────────────────────────────────────────────────────────────────────┘                                  │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
TypeError: unsupported operand type(s) for -: 'NoneType' and 'NoneType'                                                
2022-08-19 16:13:58.413 | WARNING | Saving error: ./log/error/1660893238413

截图

2022-08-19_16-13-56-970804 2022-08-19_16-13-57-283283 2022-08-19_16-13-57-459363

还有别的吗?

夕张并没有上场

Horizon101011 commented 2 years ago

log显示切换到下一艘船(夕张)成功,但是在强化的检查阶段检测不到状态栏了,也就是你提供的最后一张截图,黑屏了

目前的信息来看似乎和alas没有关系(?) 错误是由于那张黑屏的截图导致的 需要更多信息或者进一步观察

然后是关于没有强化这一点,建议将强化的数量增大一些比如5,或者指定舰船类型 这可能是由于当前可强化的船的属性和可供使用的素材提供的属性不一致导致的

举个例子比如你所提供的截图里的夕张,如果可供使用的素材只有白皮航母(提供装填和航空),由于装填已经满了,那么点击推荐按钮是不会有素材出现的,从而被判定为强化失败

Moment0901 commented 2 years ago

素材是有的,我看见它不动了,我自己手动强化了,发现是可以强化的。 另外就是还有一种情况我没发上来,最后一张也是黑屏,只不过这次我看船坞发现已经强化完了。 用的是 aScreenCap和minitouch 然后现在我换成一键退役,从下午到现在没有出现错误

Horizon101011 commented 2 years ago

如果你愿意并且有时间的话,可以选择强化,然后尝试先增大强化数量,看看后续还会不会有类似的错误发生,并提供相关的log和截图 或者更进一步的,保持现有的强化数量2,然后在触发强化的时候试着录个屏(包含屏幕和log)

目前提供的信息不好复现这个问题 或者可以暂时先保持现状不使用强化

Moment0901 commented 2 years ago

好,我找个时间复现一下

Moment0901 commented 2 years ago

刚刚去试了下,感觉首位可强化的舰娘出击了,触发bug的概率会高很多。只见过一次出击前强化结果出bug的,可惜没录下来。 然后就是录完才意识到模拟器位置忘调了()如果不行的话我再去复现几次

↓这是强化数量为2的时候的视频↓

https://user-images.githubusercontent.com/78264687/185677181-c271eb74-409e-49fd-8be0-5b5a84b69f91.mp4

如果首位能强化的舰娘出击了(像视频那样),那100%bug(体感)

↓这两个是强化数量为5的时候的视频↓

https://user-images.githubusercontent.com/78264687/185677536-4856ecc3-1b6f-4a5f-9afb-28bc82d01191.mp4

https://user-images.githubusercontent.com/78264687/185677558-ec4543ba-5d25-474d-b45e-1a800b912b25.mp4

然后强化数量为5的时候会出现一些奇奇怪怪的情况,比如第一个视频里,他干脆不强化了()不知道是bug还是程序的设计,反正能运行。然后不触发bug的概率感觉会低点。

然后bug截图最后一张都是黑的,log好像也大差不差,如果需要的话我就贴在下边

Horizon101011 commented 2 years ago

从录屏的结果来看,似乎是截图的问题

视频1和视频3最后都出现了issue中提到的相同错误,都是没有检测到侧边栏 视频2中切换到卡萨布兰卡后本应检测到新船,但是alas认为出现了滑动失败所以多滑了一次切到了绫波

结合你说的最后的截图都是黑屏来看,有可能是截图方式引起的问题 建议更换一个截图方式看一下结果如何

Moment0901 commented 2 years ago

好像从上传了视频到现在也没出现过bug了,如果再这么频繁有bug的话再试下换截图方式看看 话说我这里截图方式中最快那两个(带nc那两个)都用不了,是正常的吗?我这个夜神本来是从日语的官网上下载的

Horizon101011 commented 2 years ago

话说我这里截图方式中最快那两个(带nc那两个)都用不了,是正常的吗?我这个夜神本来是从日语的官网上下载的

nc是netcat缩写,一个工具,有些模拟器可能没装所以不能用,很正常,问题不大