Skip to content

Conversation

@olethanh
Copy link
Collaborator

This was causing an error in the monitor payment task

AttributeError: 'FunctionEnvironment' object has no attribute 'trusted_execution'
  File "aleph/vm/utils/__init__.py", line 90, in run_and_log_exception
    return await coro
  File "aleph/vm/orchestrator/tasks.py", line 154, in monitor_payments
    executions = [execution for execution in executions if execution.is_confidential]
  File "aleph/vm/orchestrator/tasks.py", line 154, in <listcomp>
    executions = [execution for execution in executions if execution.is_confidential]
  File "aleph/vm/models.py", line 113, in is_confidential
    return True if self.message.environment.trusted_execution else False

To reproduce

Run a program so it's in the execution lists for example a permanent one,
Then wait for the monitory_payments task to run

This was causing an error in the monitor payment task

AttributeError: 'FunctionEnvironment' object has no attribute 'trusted_execution'
  File "aleph/vm/utils/__init__.py", line 90, in run_and_log_exception
    return await coro
  File "aleph/vm/orchestrator/tasks.py", line 154, in monitor_payments
    executions = [execution for execution in executions if execution.is_confidential]
  File "aleph/vm/orchestrator/tasks.py", line 154, in <listcomp>
    executions = [execution for execution in executions if execution.is_confidential]
  File "aleph/vm/models.py", line 113, in is_confidential
    return True if self.message.environment.trusted_execution else False
@olethanh olethanh force-pushed the ol-fix-is-confidential branch from b908afa to c3e065d Compare August 21, 2024 12:05
@codecov
Copy link

codecov bot commented Aug 21, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 61.53%. Comparing base (ff6c119) to head (c3e065d).
Report is 4 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #674      +/-   ##
==========================================
+ Coverage   61.43%   61.53%   +0.10%     
==========================================
  Files          68       68              
  Lines        5997     5997              
  Branches      635      635              
==========================================
+ Hits         3684     3690       +6     
+ Misses       2158     2153       -5     
+ Partials      155      154       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@nesitor nesitor merged commit 414ef8f into main Aug 21, 2024
@nesitor nesitor deleted the ol-fix-is-confidential branch August 21, 2024 15:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants