You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bug description
When attempting to use the --export-to-file command in pgloader-cli, a segmentation fault is encountered. This happens on 0.9.4-alpha and not 0.9.3.
How to reproduce Please, if the bug can be reproduceable describe the steps in full details. If possible provide a sample model and/or a SQL dump for test purposes.
Create a directory with a models folder containing plain.dbm, which was made by creating a new empty project and saving it immediately.
<?xml version="1.0" encoding="UTF-8"?>
<!--CAUTION: Do not modify this file unless you know what you are doing. Unexpected results may occur if the code is changed deliberately.-->
<dbmodelpgmodeler-ver="0.9.4-alpha"use-changelog="false"last-position="0,0"last-zoom="1"max-obj-count="4"default-schema="public"default-owner="postgres"layers="Default layer"active-layers="0"layer-name-colors="#000000"layer-rect-colors="#b4b4b4"show-layer-names="false"show-layer-rects="false">
<databasename="new_database"is-template="false"allow-conns="true">
</database>
<schemaname="public"layers="0"fill-color="#e1e1e1"sql-disabled="true">
</schema>
</dbmodel>
2 Run docker run -v $(pwd)/models:/models -it --entrypoint /bin/bash apazga/docker-pgmodeler:0.9.4-alpha.
3. From within the Docker container, run pgmodeler-cli -platform offscreen --export-to-file --input /models/plain.dbm --output plain.sql
The following output is produced:
pgModeler 0.9.4-alpha command line interface.
Starting model export...
Loading input file: /models/plain.dbm
Segmentation fault
Expected behavior
The file should be exported to SQL.
Note that this does not occur in pgmodeler 0.9.3 with a similar empty file:
plain93.dbm
<?xml version="1.0" encoding="UTF-8"?>
<!--CAUTION: Do not modify this file unless you know what you are doing. Unexpected results may occur if the code is changed deliberately.-->
<dbmodelpgmodeler-ver="0.9.3"use-changelog="false"last-position="0,0"last-zoom="1"max-obj-count="4"default-schema="public"default-owner="postgres">
<databasename="new_database"is-template="false"allow-conns="true">
</database>
<schemaname="public"layer="0"fill-color="#e1e1e1"sql-disabled="true">
</schema>
After running docker run -v $(pwd)/models:/models -it --entrypoint /bin/bash apazga/docker-pgmodeler:0.9.3:
Maybe you've stumbled in a bug that I've already fixed in 0.9.4-alpha1 :)
I didn't test using docker but the result is supposed to be the same (since you have it working for 0.9.3 but not for 0.9.4-alpha). Anyway, I was able to run the command on 0.9.4-beta without any crash:
pgModeler command line interface.
Version 0.9.4-beta - 20210913.44c4bfffa Qt 5.15.1
PostgreSQL Database Modeler Project - pgmodeler.io
Copyright 2006-2021 Raphael Araújo e Silva <raphael@pgmodeler.io>
Starting model export...
Loading input file: /home/raphael/dbm_models/plain.dbm
Export to SQL script file: /home/raphael/pgmodeler/build/bin/plain.sql
Generating SQL code for PostgreSQL `13.0'
[31%] Generating SQL code: `new_database' (Banco de Dados)
[100%] SQL file `/home/raphael/pgmodeler/build/bin/plain.sql' successfully written.
Export successfully ended!
Bug description
When attempting to use the
--export-to-file
command inpgloader-cli
, a segmentation fault is encountered. This happens on0.9.4-alpha
and not0.9.3
.How to reproduce
Please, if the bug can be reproduceable describe the steps in full details. If possible provide a sample model and/or a SQL dump for test purposes.
models
folder containingplain.dbm
, which was made by creating a new empty project and saving it immediately.2 Run
docker run -v $(pwd)/models:/models -it --entrypoint /bin/bash apazga/docker-pgmodeler:0.9.4-alpha
.3. From within the Docker container, run
pgmodeler-cli -platform offscreen --export-to-file --input /models/plain.dbm --output plain.sql
The following output is produced:
Expected behavior
The file should be exported to SQL.
Note that this does not occur in
pgmodeler 0.9.3
with a similar empty file:plain93.dbm
After running
docker run -v $(pwd)/models:/models -it --entrypoint /bin/bash apazga/docker-pgmodeler:0.9.3
:Screenshots
If applicable, add screenshots to help explain your problem.
Info about your desktop
Stacktrace / Debug info
No stacktrace was produced.
Additional info
The text was updated successfully, but these errors were encountered: