Merge branch 'main' of github.com:xlang-ai/OSWorld
This commit is contained in:
@@ -459,7 +459,11 @@ def load_xlsx_styles(xlsx_file: Workbook, sheet_name: str, book_name: str, **opt
|
|||||||
for r in fmt.rules:
|
for r in fmt.rules:
|
||||||
active_cells: List[Cell] = []
|
active_cells: List[Cell] = []
|
||||||
if r.type == "expression":
|
if r.type == "expression":
|
||||||
condition: Callable[[str], bool] = formula_parser.ast("=" + r.formula[0])[1].compile()
|
try:
|
||||||
|
condition: Callable[[str], bool] = formula_parser.ast("=" + r.formula[0])[1].compile()
|
||||||
|
except:
|
||||||
|
logger.exception("Formula parsing error: %s. Skipping.", repr(r.formula[0]))
|
||||||
|
continue
|
||||||
logger.debug("Expression condition: %s", r.formula[0])
|
logger.debug("Expression condition: %s", r.formula[0])
|
||||||
|
|
||||||
arguments: List[Any] = []
|
arguments: List[Any] = []
|
||||||
@@ -493,9 +497,15 @@ def load_xlsx_styles(xlsx_file: Workbook, sheet_name: str, book_name: str, **opt
|
|||||||
if nb_contiguous_nothings>50:
|
if nb_contiguous_nothings>50:
|
||||||
break
|
break
|
||||||
continue
|
continue
|
||||||
elif condition(cell_value, *arguments):
|
else:
|
||||||
logger.debug("Active Cell %s(%s) for %s", repr(cell), str(cell_value), r.formula[0])
|
try:
|
||||||
active_cells.append(cell)
|
satisfies_condition: bool = condition(cell_value, *arguments)
|
||||||
|
except:
|
||||||
|
logger.exception("Error in formula calculation with cell value %d", repr(cell_value))
|
||||||
|
satisfies_condition = False
|
||||||
|
if satisfies_condition:
|
||||||
|
logger.debug("Active Cell %s(%s) for %s", repr(cell), repr(cell_value), r.formula[0])
|
||||||
|
active_cells.append(cell)
|
||||||
else:
|
else:
|
||||||
raise NotImplementedError("Not Implemented Condition Type: {:}".format(r.type))
|
raise NotImplementedError("Not Implemented Condition Type: {:}".format(r.type))
|
||||||
|
|
||||||
|
|||||||
@@ -82,4 +82,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -91,4 +91,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -87,4 +87,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -82,4 +82,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -109,4 +109,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -95,4 +95,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -176,4 +176,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -82,4 +82,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -32,4 +32,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -91,4 +91,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -88,4 +88,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -61,4 +61,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -82,4 +82,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -109,4 +109,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -82,4 +82,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"id": "0a211154-fda0-48d0-9274-eaac4ce5486d",
|
"id": "0a211154-fda0-48d0-9274-eaac4ce5486d",
|
||||||
"snapshot": "libreoffice_impress",
|
"snapshot": "libreoffice_impress",
|
||||||
"instruction": "Set the background color of slides with a real person picture as yellow and set the title of slide 2 as \"Let's start\".",
|
"instruction": "Set the background color to yellow for any slide that contains one or more images of real people, and set the title of slide 2 as \"Let's start\".",
|
||||||
"source": "https://arxiv.org/pdf/2311.01767.pdf",
|
"source": "https://arxiv.org/pdf/2311.01767.pdf",
|
||||||
"config": [
|
"config": [
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -83,4 +83,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -112,4 +112,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -168,4 +168,4 @@
|
|||||||
"proxy": false,
|
"proxy": false,
|
||||||
"fixed_ip": false,
|
"fixed_ip": false,
|
||||||
"possibility_of_env_change": "low"
|
"possibility_of_env_change": "low"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -73,7 +73,7 @@
|
|||||||
<div class="video-player">
|
<div class="video-player">
|
||||||
<video id="task-recording" controls playsinline webkit-playsinline
|
<video id="task-recording" controls playsinline webkit-playsinline
|
||||||
preload="metadata" width="100%" controlslist="nodownload">
|
preload="metadata" width="100%" controlslist="nodownload">
|
||||||
<source src="/task/{{ task_type }}/{{ task_id }}/recording" type="video/mp4">
|
<source src="/task/{{ task_type }}/{{ task_id }}/recording?action_space={{ action_space }}&observation_type={{ observation_type }}&model_name={{ model_name }}" type="video/mp4">
|
||||||
Your browser does not support the video tag.
|
Your browser does not support the video tag.
|
||||||
</video>
|
</video>
|
||||||
<div id="video-status" class="video-status">Loading video...</div>
|
<div id="video-status" class="video-status">Loading video...</div>
|
||||||
@@ -103,7 +103,7 @@
|
|||||||
{% endif %}</pre>
|
{% endif %}</pre>
|
||||||
{% if step.screenshot_file %}
|
{% if step.screenshot_file %}
|
||||||
<div>
|
<div>
|
||||||
<img src="/task/{{ task_type }}/{{ task_id }}/screenshot/{{ step.screenshot_file }}"
|
<img src="/task/{{ task_type }}/{{ task_id }}/screenshot/{{ step.screenshot_file }}?action_space={{ action_space }}&observation_type={{ observation_type }}&model_name={{ model_name }}"
|
||||||
alt="Step {{ step.step_num }} Screenshot" class="step-image">
|
alt="Step {{ step.step_num }} Screenshot" class="step-image">
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
@@ -155,7 +155,7 @@
|
|||||||
}, 2000);
|
}, 2000);
|
||||||
|
|
||||||
// Directly check video source availability with fetch API
|
// Directly check video source availability with fetch API
|
||||||
fetch('/task/{{ task_type }}/{{ task_id }}/recording', {method: 'HEAD'})
|
fetch('/task/{{ task_type }}/{{ task_id }}/recording?action_space={{ action_space }}&observation_type={{ observation_type }}&model_name={{ model_name }}', {method: 'HEAD'})
|
||||||
.then(function(response) {
|
.then(function(response) {
|
||||||
if (response.ok && videoStatus.textContent === 'Loading video...') {
|
if (response.ok && videoStatus.textContent === 'Loading video...') {
|
||||||
// If HEAD request succeeds but video events haven't fired
|
// If HEAD request succeeds but video events haven't fired
|
||||||
|
|||||||
Reference in New Issue
Block a user