Browse Source

fix: do not raise error when failed to delete ~/.bashrc (#1701)

Xingyao Wang 1 year ago
parent
commit
33e141e626
1 changed files with 1 additions and 7 deletions
  1. 1 7
      opendevin/runtime/plugins/mixin.py

+ 1 - 7
opendevin/runtime/plugins/mixin.py

@@ -21,10 +21,6 @@ class PluginMixin:
 
         # clean-up ~/.bashrc and touch ~/.bashrc
         exit_code, output = self.execute('rm -f ~/.bashrc && touch ~/.bashrc')
-        if exit_code != 0:
-            raise RuntimeError(
-                f'Failed to clean-up ~/.bashrc with exit code {exit_code} and output {output}'
-            )
 
         for requirement in requirements:
             # copy over the files
@@ -45,9 +41,7 @@ class PluginMixin:
                 raise RuntimeError(
                     f'Failed to initialize plugin {requirement.name} with exit code {exit_code} and output {output}'
                 )
-            logger.info(
-                f'Plugin {requirement.name} initialized successfully.'
-            )
+            logger.info(f'Plugin {requirement.name} initialized successfully.')
 
         if len(requirements) > 0:
             exit_code, output = self.execute('source ~/.bashrc')