Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

qgis container not working out of the box? #52

Open
Robinlovelace opened this issue Aug 14, 2024 · 3 comments
Open

qgis container not working out of the box? #52

Robinlovelace opened this issue Aug 14, 2024 · 3 comments

Comments

@Robinlovelace
Copy link
Contributor

I've tried a session starting with our qgis container and get an error:

docker run -it ghcr.io/geocompx/docker:qgis /bin/bash
R
library(qgisprocess)

>>> PROBLEM encountered: couldn't build and save package cache! 

Any ideas @jannes-m ?

PS C:\Users\georl_admin\github\nptscot> docker run -it ghcr.io/geocompx/docker:qgis /bin/bash
Unable to find image 'ghcr.io/geocompx/docker:qgis' locally
qgis: Pulling from geocompx/docker
e311a697a403: Pulling fs layer
926f2d6ac23b: Pulling fs layer
f85e4c4a147f: Pulling fs layer
961a38eedb06: Pulling fs layer
9c1cd9f12f56: Waiting                                                                                                   33ea3844e60e: Waiting                                                                                                   f48a64097edb: Waiting
c1950ac6f0a7: Waiting
e16a99d08fab: Waiting                                                                                                   17f2f9344dea: Waiting                                                                                                   4d87aa41db2c: Waiting                                                                                                   22270397e270: Waiting                                                                                                   0b536e7d93f5: Pull complete
d1f515638bdc: Pull complete                                                                                             30e84c00a654: Pull complete
7ea03b0dabd7: Pull complete                                                                                             c4e6ae8c57f2: Pull complete
e6d7b0cedb30: Pull complete
b70814f01360: Pull complete
0c66adfcfbfd: Pull complete                                                                                             8da0ffa79364: Pull complete
e4ce9a391b17: Pull complete
a5b1049ad8b9: Pull complete
23c772569714: Pull complete                                                                                             7263fc5234f6: Pull complete
0765648ea1e0: Pull complete                                                                                             85d0466e54fd: Pull complete
caa1d3bf8920: Pull complete
95dfd028ee08: Pull complete
6614e611b87d: Pull complete
4e4b6b8e68ec: Pull complete
57611ebb3ea8: Pull complete
9e7b4fc17415: Pull complete
fa232696a74e: Pull complete
8f50b93b0730: Pull complete
6c62b14d42f5: Pull complete
5e1d47bbd067: Pull complete
c3c453181d49: Pull complete
9f866ee83c7e: Pull complete
c0c0ef0831f1: Pull complete
ae4d1b67ebe4: Pull complete
Digest: sha256:744b011b60b086fd5d487eaeaeab8b21d477ebda960e619f9e38ad6aca827fda
Status: Downloaded newer image for ghcr.io/geocompx/docker:qgis
root@6845cd09c1ee:/#
root@6845cd09c1ee:/#
root@6845cd09c1ee:/# R

R version 4.4.0 (2024-04-24) -- "Puppy Cup"
Copyright (C) 2024 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> qgisprocess::Attempting to load the package cache ... No cache found.
Will try to reconfigure qgisprocess and build new cache ...

Standard error message from 'qgis_process':
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'



Standard error message from 'qgis_process':
QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'



ATTENTION: the QGIS algorithms could not be queried. You will loose some functionality.
You may want to (re)run `qgis_configure()`; see its documentation.
Error message was:

Error: parse error: premature EOF
                                       {   "gdal_version": "3.8.5",
                     (right here) ------^



qgisprocess::qgis_run                         qgisprocess::qgis_enable_plugins
qgisprocess::qgis_result_stderr               qgisprocess::qgis_get_description
qgisprocess::qgis_as_raster                   qgisprocess::qgis_has_provider
qgisprocess::qgis_detect_paths                qgisprocess::qgis_detect_macos
qgisprocess::qgis_search_algorithms           qgisprocess::qgis_run_algorithm_p
qgisprocess::has_qgis                         qgisprocess::qgis_outputs
qgisprocess::qgis_providers                   qgisprocess::qgis_use_json_input
qgisprocess::qgis_get_argument_specs          qgisprocess::qgis_has_algorithm
qgisprocess::qgis_detect_windows_paths        qgisprocess::qgis_result_args
qgisprocess::qgis_disable_plugins             qgisprocess::qgis_algorithms
qgisprocess::qgis_path                        qgisprocess::qgis_as_terra
qgisprocess::qgis_run_algorithm               qgisprocess::qgis_tmp_vector
qgisprocess::qgis_tmp_folder                  qgisprocess::qgis_function
qgisprocess::qgis_description                 qgisprocess::qgis_detect_macos_paths
qgisprocess::qgis_result_clean                qgisprocess::qgis_extract_output
qgisprocess::qgis_arguments                   qgisprocess::qgis_list_input
qgisprocess::qgis_extract_output_by_class     qgisprocess::qgis_dict_input
qgisprocess::qgis_plugins                     qgisprocess::qgis_pipe
qgisprocess::qgis_using_json_output           qgisprocess::qgis_get_output_specs
qgisprocess::as_qgis_argument                 qgisprocess::qgis_detect_windows
qgisprocess::qgis_extract_output_by_name      qgisprocess::qgis_clean_tmp
qgisprocess::qgis_tmp_raster                  qgisprocess::qgis_tmp_file
qgisprocess::qgis_using_json_input            qgisprocess::qgis_result_single
qgisprocess::qgis_result_stdout               qgisprocess::qgis_use_json_output
qgisprocess::qgis_clean_argument              qgisprocess::qgis_output
qgisprocess::qgis_clean_result                qgisprocess::qgis_tmp_base
qgisprocess::qgis_show_help                   qgisprocess::qgis_extract_output_by_position
qgisprocess::qgis_configure                   qgisprocess::qgis_unconfigure
qgisprocess::qgis_version                     qgisprocess::qgis_result_status
qgisprocess::qgis_has_plugin                  qgisprocess::qgis_as_brick
qgisprocess::qgis_tmp_clean
> qgisprocess::qgis_algorithms()
NULL
> qgisprocess::qgis_algorithms
qgisprocess::qgis_algorithms
> qgisprocess::qgis_plugins
qgisprocess::qgis_plugins
> qgisprocess::qgis_plugins()
# A tibble: 3 x 2
  name                    enabled
  <chr>                   <lgl>
1 grassprovider           FALSE
2 processing              TRUE
3 processing_saga_nextgen FALSE
> qgisprocess::qgis_search_algorithms("clean")
Error: result does not inherit from class data.frame
> library(qgisprocess)

>>> PROBLEM encountered: couldn't build and save package cache! <<<
The 'qgis_process' command-line utility was either not found or
did not fulfil the needs to build the package cache.
Please run `qgis_configure()` to fix this and rebuild the cache.
See its documentation if you need to preset the path of qgis_process.
If the problem persists, make sure that you correctly installed QGIS
for your operating system using the instructions at
<https://download.qgis.org>.
> qgisprocess::qgis_search_algorithms("clean")
Error: result does not inherit from class data.frame
>
@jannes-m
Copy link
Contributor

Yeah, I have seen this before. You can run the qgis_process command on the CLI and you will see that there is some output (remember to set one env variable before running it, I don't recall its name from the top of my head) , some uninformative and irrelevant error messages, that makes qgisprocess stop when parsing that output.

@jannes-m
Copy link
Contributor

I will report this back to Floris and then we'll see if and how we can adjust qgis_configure() accordingly. Currently, we are on our way to Croatia but I will find some time in the coming days in the evening to explore this issue further.

@Robinlovelace
Copy link
Contributor Author

Thanks and enjoy the holidays Jannes!

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

No branches or pull requests

2 participants