Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: AttributeError: 'EventStreamRuntime' object has no attribute 'sid' if runtime_extra_deps is not None #5277

Closed
1 task done
grizxlyzx opened this issue Nov 26, 2024 · 2 comments · Fixed by #5330
Closed
1 task done
Labels
bug Something isn't working fix-me Attempt to fix this issue with OpenHands

Comments

@grizxlyzx
Copy link

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Describe the bug and reproduction steps

  • in config.toml, add field runtime_extra_deps = <any dockerfile command> under [sandbox]
  • set log level to debug
  • make run and start a task

backend will raise AttributeError: 'EventStreamRuntime' object has no attribute 'sid' from EventStreamRuntime.__init__

OpenHands Installation

Development workflow

OpenHands Version

main

Operating System

Linux

Logs, Errors, Screenshots, and Additional Context

In EventStreamRuntime's __init__:

......
      if self.config.sandbox.runtime_extra_deps:
          self.log(
              'debug',
              f'Installing extra user-provided dependencies in the runtime image: {self.config.sandbox.runtime_extra_deps}',
          )

      self.init_base_runtime(
          config,
          event_stream,
          sid,
          plugins,
          env_vars,
          status_callback,
          attach_to_existing,
          headless_mode,
      )
......

check runtime_extra_deps and log happens before initializing base class Runtime, but self.log() reads self.sid, which at the time is not initialized yet.

@grizxlyzx grizxlyzx added the bug Something isn't working label Nov 26, 2024
SmartManoj added a commit to SmartManoj/Kevin that referenced this issue Nov 26, 2024
@enyst enyst added the fix-me Attempt to fix this issue with OpenHands label Nov 29, 2024
Copy link
Contributor

OpenHands started fixing the issue! You can monitor the progress here.

Copy link
Contributor

A potential fix has been generated and a draft PR #5330 has been created. Please review the changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fix-me Attempt to fix this issue with OpenHands
Projects
None yet
2 participants