@lonvia commented on this pull request.


> +        context.import_data = None
+        cmdline.extend(('-r', 'opl', '-'))
+    else:
+        assert context.import_file is not None, "No input data given."
+        cmdline.append(str(context.import_file))
+        context.import_file = None
+        data_stdin = None
+
+    proc = Popen(cmdline, cwd=str(context.workdir),
+                 stdin=PIPE, stdout=PIPE, stderr=PIPE)
+
+    outdata = proc.communicate(input=data_stdin)
+    context.osm2pgsql_cmdline = ' '.join(cmdline)
+    context.osm2pgsql_outdata = [d.decode('utf-8').replace('\\n', '\n') for d 
in outdata]
+    context.osm2pgsql_returncode = proc.returncode
+    context.osm2pgsql_params = {'-d': context.user_args.test_db}

This resets all parameters. This is admittedly also a deviation from the 
current behaviour. If you want to call the execution step again, you need to 
redo all steps that influence the osm2pgsql command line. We had exactly one 
test where this was an issue an it was doing the same update twice. So reuse 
looks to be a rare case and I'd rather err on the side of having to spell 
things out. 

-- 
Reply to this email directly or view it on GitHub:
https://github.com/osm2pgsql-dev/osm2pgsql/pull/2436#discussion_r2584745294
You are receiving this because you are subscribed to this thread.

Message ID: <osm2pgsql-dev/osm2pgsql/pull/2436/review/[email protected]>
_______________________________________________
Tile-serving mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/tile-serving

Reply via email to