Self-Evolving Coding Agents via Harness-Policy Optimization
Paper • 2610.22791 • Published • 55
Error code: DatasetGenerationError
Exception: TypeError
Message: Couldn't cast array of type
struct<dataset: string, instance_id: string, image_url: string, workdir: string, pre_commands: string, repo: string, base_commit: string, version: string, test_patch: string, hints_text: string, created_at: string, environment_setup_commit: string, FAIL_TO_PASS: string, PASS_TO_PASS: string, install_config: struct<base_image_name: string, docker_specs: struct<_variant: null, bazel_version: null, bun_version: null, cargo_version: null, deno_version: null, docker_version: null, erlang_version: null, gcc_version: null, go_version: null, helm_version: null, java_version: null, jdk_version: null, llvm_version: null, lua_version: null, luajit_version: null, neovim_version: null, node_version: null, npm_version: null, nvim_version: null, pnpm_version: null, python_image: string, python_version: null, redis_version: null, ruby_version: null, rust_version: null, rustc_version: null, solana_version: null, sqlite_version: null>, install: string, log_parser: string, test_cmd: string>>
to
{'dataset': Value('string'), 'instance_id': Value('string'), 'image_url': Value('string'), 'install_config': {'base_image_name': Value('string'), 'docker_specs': {'_variant': Value('null'), 'bazel_version': Value('null'), 'bun_version': Value('null'), 'cargo_version': Value('null'), 'deno_version': Value('null'), 'docker_version': Value('null'), 'erlang_version': Value('null'), 'gcc_version': Value('null'), 'go_version': Value('null'), 'helm_version': Value('null'), 'java_version': Value('null'), 'jdk_version': Value('null'), 'llvm_version': Value('null'), 'lua_version': Value('null'), 'luajit_version': Value('null'), 'neovim_version': Value('null'), 'node_version': Value('null'), 'npm_version': Value('null'), 'nvim_version': Value('null'), 'pnpm_version': Value('null'), 'python_image': Value('string'), 'python_version': Value('null'), 'redis_version': Value('null'), 'ruby_version': Value('null'), 'rust_version': Value('null'), 'rustc_version': Value('null'), 'solana_version': Value('null'), 'sqlite_version': Value('null')}, 'install': Value('string'), 'log_parser': Value('string'), 'test_cmd': Value('string')}, 'workdir': Value('string'), 'repo': Value('string'), 'base_commit': Value('string'), 'version': Value('string'), 'test_patch': Value('string'), 'hints_text': Value('string'), 'created_at': Value('timestamp[s]'), 'environment_setup_commit': Value('string'), 'FAIL_TO_PASS': List(Value('string')), 'PASS_TO_PASS': List(Value('string'))}
Traceback: Traceback (most recent call last):
File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1827, in _prepare_split_single
for key, table in generator:
^^^^^^^^^
File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 613, in wrapped
for item in generator(*args, **kwargs):
~~~~~~~~~^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/packaged_modules/json/json.py", line 343, in _generate_tables
self._cast_table(pa_table, json_field_paths=json_field_paths),
~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/packaged_modules/json/json.py", line 132, in _cast_table
pa_table = table_cast(pa_table, self.info.features.arrow_schema)
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2378, in table_cast
return cast_table_to_schema(table, schema)
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2312, in cast_table_to_schema
cast_array_to_feature(
~~~~~~~~~~~~~~~~~~~~~^
table[name] if name in table_column_names else pa.array([None] * len(table), type=schema.field(name).type),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
feature,
^^^^^^^^
)
^
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 1861, in wrapper
return pa.chunked_array([func(chunk, *args, **kwargs) for chunk in array.chunks])
~~~~^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/table.py", line 2158, in cast_array_to_feature
raise TypeError(f"Couldn't cast array of type\n{_short_str(array.type)}\nto\n{_short_str(feature)}")
TypeError: Couldn't cast array of type
struct<dataset: string, instance_id: string, image_url: string, workdir: string, pre_commands: string, repo: string, base_commit: string, version: string, test_patch: string, hints_text: string, created_at: string, environment_setup_commit: string, FAIL_TO_PASS: string, PASS_TO_PASS: string, install_config: struct<base_image_name: string, docker_specs: struct<_variant: null, bazel_version: null, bun_version: null, cargo_version: null, deno_version: null, docker_version: null, erlang_version: null, gcc_version: null, go_version: null, helm_version: null, java_version: null, jdk_version: null, llvm_version: null, lua_version: null, luajit_version: null, neovim_version: null, node_version: null, npm_version: null, nvim_version: null, pnpm_version: null, python_image: string, python_version: null, redis_version: null, ruby_version: null, rust_version: null, rustc_version: null, solana_version: null, sqlite_version: null>, install: string, log_parser: string, test_cmd: string>>
to
{'dataset': Value('string'), 'instance_id': Value('string'), 'image_url': Value('string'), 'install_config': {'base_image_name': Value('string'), 'docker_specs': {'_variant': Value('null'), 'bazel_version': Value('null'), 'bun_version': Value('null'), 'cargo_version': Value('null'), 'deno_version': Value('null'), 'docker_version': Value('null'), 'erlang_version': Value('null'), 'gcc_version': Value('null'), 'go_version': Value('null'), 'helm_version': Value('null'), 'java_version': Value('null'), 'jdk_version': Value('null'), 'llvm_version': Value('null'), 'lua_version': Value('null'), 'luajit_version': Value('null'), 'neovim_version': Value('null'), 'node_version': Value('null'), 'npm_version': Value('null'), 'nvim_version': Value('null'), 'pnpm_version': Value('null'), 'python_image': Value('string'), 'python_version': Value('null'), 'redis_version': Value('null'), 'ruby_version': Value('null'), 'rust_version': Value('null'), 'rustc_version': Value('null'), 'solana_version': Value('null'), 'sqlite_version': Value('null')}, 'install': Value('string'), 'log_parser': Value('string'), 'test_cmd': Value('string')}, 'workdir': Value('string'), 'repo': Value('string'), 'base_commit': Value('string'), 'version': Value('string'), 'test_patch': Value('string'), 'hints_text': Value('string'), 'created_at': Value('timestamp[s]'), 'environment_setup_commit': Value('string'), 'FAIL_TO_PASS': List(Value('string')), 'PASS_TO_PASS': List(Value('string'))}
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 1369, in compute_config_parquet_and_info_response
parquet_operations, partial, estimated_dataset_info = stream_convert_to_parquet(
~~~~~~~~~~~~~~~~~~~~~~~~~^
builder, max_dataset_size_bytes=max_dataset_size_bytes
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/src/services/worker/src/worker/job_runners/config/parquet_and_info.py", line 948, in stream_convert_to_parquet
builder._prepare_split(split_generator=splits_generators[split], file_format="parquet")
~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1694, in _prepare_split
for job_id, done, content in self._prepare_split_single(
~~~~~~~~~~~~~~~~~~~~~~~~~~^
gen_kwargs=gen_kwargs, job_id=job_id, **_prepare_split_args
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
):
^
File "/usr/local/lib/python3.14/site-packages/datasets/builder.py", line 1879, in _prepare_split_single
raise DatasetGenerationError("An error occurred while generating the dataset") from e
datasets.exceptions.DatasetGenerationError: An error occurred while generating the datasetNeed help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.
problem_statement string | patch string | metadata dict |
|---|---|---|
Why not BaseDRClassifier?
**Is your feature request related to a problem? Please describe.**
When using a binary classification model with an outcome learner, I want the predict() method to output probabilities—just like the classifier in other S/T/X learners does!
**Describe the solution you'd like**
Create BaseDRCla... | diff --git a/.gitignore b/.gitignore
index c95c840..2d446e8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -20,4 +20,8 @@ _build/
*.prof
.venv/
.python-version
-uv.lock
\ No newline at end of file
+uv.lock
+
+# Claude Code artifacts
+CLAUDE.md
+.claude/
\ No newline at end of file
diff --git a/causalml/inference/meta/_... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "uber__causalml-844",
"image_url": "docker.io/swerebenchv2/uber-causalml:844-5f5c4fb",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_version": null,
"c... |
[] notation for IPv6 with X-Forwarded-For
After upgrading to Waitress 1.2.0 and letting it handle `X-Forwarded-For` headers, the WSGI environment `REMOTE_ADDR` is populated with IPv6 using the `[]` notation, for instance `'[2a02::1]'`.
While the WSGI specification doesn't say anything about `REMOTE_ADDR`, it is a bi... | diff --git a/waitress/task.py b/waitress/task.py
index ec4dd7b..8e14b4f 100644
--- a/waitress/task.py
+++ b/waitress/task.py
@@ -535,9 +535,13 @@ class WSGITask(Task):
forward_hop = forward_hop.strip()
forward_hop = undquote(forward_hop)
- # Make sure that all IPv6 add... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "pylons__waitress-232",
"image_url": "docker.io/swerebenchv2/pylons-waitress:232-25c862c",
"install_config": {
"base_image_name": "python_base_37",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_version": null,
... |
Paginator has stopped working for me in moto 5
I have some code that uses pagination: https://github.com/lsst/resources/blob/main/python/lsst/resources/s3.py#L472
```python
s3_paginator = self.client.get_paginator("list_objects_v2")
for page in s3_paginator.paginate(Bucket=self.netloc, Prefix=prefix, Delimiter="/"... | diff --git a/.gitignore b/.gitignore
index e34bcfd32..956ec003f 100644
--- a/.gitignore
+++ b/.gitignore
@@ -39,3 +39,4 @@ other_langs/tests_dotnet/ExampleTestProject/obj
other_langs/tests_ruby/Gemfile.lock
other_langs/terraform/*/.terraform*
other_langs/terraform/*/terraform*
+other_langs/terraform/awslambda/lambda... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "getmoto__moto-7283",
"image_url": "docker.io/swerebenchv2/getmoto-moto:7283-351b45c",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_version": null,
"c... |
enh: Add `backend` argument to `lazy`
Similar to https://github.com/narwhals-dev/narwhals/issues/1888
I think `lazy` could have a `backend: ModuleType | Implementation | LazyBackend` argument, so all of the following could be supported:
```python
df: nw.DataFrame
df.lazy('duckdb')
df.lazy(duckdb)
df.lazy(nw.Implementa... | diff --git a/narwhals/_duckdb/group_by.py b/narwhals/_duckdb/group_by.py
index f005ea0e..ed0cbb77 100644
--- a/narwhals/_duckdb/group_by.py
+++ b/narwhals/_duckdb/group_by.py
@@ -49,7 +49,5 @@ class DuckDBGroupBy:
)
return self._compliant_frame._from_native_frame(
- self._compliant_fr... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "narwhals-dev__narwhals-1914",
"image_url": "docker.io/swerebenchv2/narwhals-dev-narwhals:1914-d48b8a3",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_versio... |
Apply custom error processor for generic HTTP errors even `json_errors` is `False`
Currently, if the `json_errors` is `False` when creating the app instance, the error processor registered with `app.error_processor` will not be applied on generic HTTP errors. I think it's better to change this behavior to match the beh... | diff --git a/CHANGES.md b/CHANGES.md
index 58fbf33..2d45694 100644
--- a/CHANGES.md
+++ b/CHANGES.md
@@ -24,6 +24,8 @@ Released: --
be included in the returned data.
- Allow to use `json_or_form` location and fields (`DelimitedList` and `DelimitedTuple`)
from webargs ([issue #254][issue_254]).
+- When creating... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "greyli__apiflask-260",
"image_url": "docker.io/swerebenchv2/greyli-apiflask:260-a714e2f",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_version": null,
... |
TypeError - decode() argument 'encoding' must be str, not None
It seems slack just had a blip and returned some kind of error responses that did not feature the charset header. This broke in the SDK with:
```
TypeError - decode() argument 'encoding' must be str, not None
```
On this line:
https://github.com/... | diff --git a/slack/web/base_client.py b/slack/web/base_client.py
index 9f38dca..26778e6 100644
--- a/slack/web/base_client.py
+++ b/slack/web/base_client.py
@@ -475,7 +475,7 @@ class BaseClient:
resp = urlopen( # skipcq: BAN-B310
req, context=self.ssl, timeout=self.timeout... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "slackapi__python-slackclient-833",
"image_url": "docker.io/swerebenchv2/slackapi-python-slackclient:833-f3053d6",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"... |
What's wrong with this Jinja template when using {% elif %}
I have the following **Jinja** template:
```jinja
{% if new_data_set_created is defined %}
{% if new_data_set_created == True %}
The new image data set <strong>{{ form_data["data_set_name"] }}</strong> has been created.
{% set form_d... | diff --git a/CHANGES.rst b/CHANGES.rst
index 2b817985..b6a5a1af 100644
--- a/CHANGES.rst
+++ b/CHANGES.rst
@@ -45,6 +45,9 @@ Unreleased
filter. :issue:`1624`
- Using ``set`` for multiple assignment (``a, b = 1, 2``) does not fail when the
target is a namespace attribute. :issue:`1413`
+- Using ``set`` in... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "pallets__jinja-1665",
"image_url": "docker.io/swerebenchv2/pallets-jinja:1665-fbc3a69",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_version": null,
... |
Support for SQLAlchemy dataclass
SQLAlchemy 2.0 introduced PEP 681 support to its integration with dataclasses, but unfortunately this is implemented through a generic type `Mapped[T]` that at the moment is not correctly understood.
```python
from typing import Optional
from serde import serde, from_dict
from s... | diff --git a/README.md b/README.md
index eae5c3d..f4ac99b 100644
--- a/README.md
+++ b/README.md
@@ -77,6 +77,7 @@ Foo(i=10, s='foo', f=100.0, b=True)
- [`ipaddress`](https://docs.python.org/3/library/ipaddress.html)
- PyPI library
- [`numpy`](https://github.com/numpy/numpy) types
+ - [`SQ... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "yukinarit__pyserde-518",
"image_url": "docker.io/swerebenchv2/yukinarit-pyserde:518-99c79df",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_version": null,
... |
file.analysis and file.get_analysis cannot access BehavioralTimeSeries
## 1) Bug
Cannot access analysis (write works fine).
### Steps to Reproduce
```
from pynwb import NWBFile, NWBHDF5IO, TimeSeries
from pynwb.behavior import BehavioralTimeSeries
import numpy as np
import datetime
filename = "./debug.nwb... | diff --git a/src/pynwb/file.py b/src/pynwb/file.py
index 5511439e..3fdca7b1 100644
--- a/src/pynwb/file.py
+++ b/src/pynwb/file.py
@@ -239,6 +239,8 @@ class NWBFile(MultiContainerInterface):
{'name': 'lab', 'type': str, 'doc': 'lab where experiment was performed', 'default': None},
{'name': 'a... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "neurodatawithoutborders__pynwb-846",
"image_url": "docker.io/swerebenchv2/neurodatawithoutborders-pynwb:846-b5939d5",
"install_config": {
"base_image_name": "python_base_37",
"docker_specs": {
"_variant": null,
"bazel_version": null,
... |
Add option to supress optimization warning message
### Summary
The warning introduced by #1431 can be annoying in some context (for example code analysis that needs runtime evaluation, like [slotscheck](https://slotscheck.readthedocs.io/en/latest/)).
I assume there may be some other use cases for wanting to disab... | diff --git a/changes/1459.feature.md b/changes/1459.feature.md
new file mode 100644
index 00000000..1bc2dffe
--- /dev/null
+++ b/changes/1459.feature.md
@@ -0,0 +1,1 @@
+Add ability to suppress optimization warnings through `suppress_optimization_warning=True` to the `GatewayBot` or `RESTBot` constructors.
diff --git a... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "hikari-py__hikari-1459",
"image_url": "docker.io/swerebenchv2/hikari-py-hikari:1459-3b6dfaa",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_version": null,
... |
Mismatch: `OptSolver` versus `set_results_format`
## Summary
The `set_results_format` function checks against `_valid_results_formats`, while the attribute in `OptSolver` is called `_valid_result_formats`. Not sure if singular/plural is better since I assume it could be both _results_ as well as (a) _result_, but th... | diff --git a/pyomo/opt/base/solvers.py b/pyomo/opt/base/solvers.py
index c06981656..4ffef7e7c 100644
--- a/pyomo/opt/base/solvers.py
+++ b/pyomo/opt/base/solvers.py
@@ -470,8 +470,8 @@ class OptSolver(object):
Set the current results format (if it's valid for the current
problem format).
"""
... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "pyomo__pyomo-3337",
"image_url": "docker.io/swerebenchv2/pyomo-pyomo:3337-b480497",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_version": null,
"car... |
Implement valid_datetime metadata key
### Is your feature request related to a problem? Please describe.
In GRIB data there is no single valid datetime key available, but this piece of information has to be constructed from multiple keys, e.g. from `validityDate` and `validityTime`. At the moment, valid datetime is... | diff --git a/earthkit/data/core/fieldlist.py b/earthkit/data/core/fieldlist.py
index f51945a..e1140d3 100644
--- a/earthkit/data/core/fieldlist.py
+++ b/earthkit/data/core/fieldlist.py
@@ -287,7 +287,7 @@ class Field(Base):
Return types for ``keys``. A single value is accepted and applied to all the ``keys... | {
"dataset": "nebius/SWE-rebench-V2",
"instance_id": "ecmwf__earthkit-data-163",
"image_url": "docker.io/swerebenchv2/ecmwf-earthkit-data:163-e485efe",
"install_config": {
"base_image_name": "python_base_310",
"docker_specs": {
"_variant": null,
"bazel_version": null,
"bun_version": nu... |
train.jsonl: the 2,484 software-engineering tasks used for the P-step (RL) in Self-HPO.
| Source | Tasks |
|---|---|
| SWE-rebench (V1) | 1,099 |
| SWE-rebench-V2 | 801 |
| Scale-SWE | 584 |
Each line has problem_statement, patch and metadata (instance id, dataset, docker image, test spec).
📄 Paper: https://arxiv.org/abs/2610.22791
💻 Code: https://github.com/MSR-Orchard/Self-HPO
@article{wei2026selfhpo,
title = {Self-Evolving Coding Agents via Harness-Policy Optimization},
author = {Wei, Zhepei and Yao, Wenlin and Peng, Baolin and Wang, Danqing and Wu, Qianhui and Cheng, Hao and Meng, Yu and Gao, Jianfeng},
journal = {arXiv preprint arXiv:2610.22791},
year = {2026},
url = {https://arxiv.org/abs/2610.22791}
}