-
Notifications
You must be signed in to change notification settings - Fork 4
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
Debugging connection to mapknitter-exporter #7
Comments
cc @icarito 😄 |
Wow got |
|
😄 https://export.mapknitter.org/ works now! Ok, but it's failing... |
i took out the |
Hmm, Cloud Build isn't seeing the latest commit...
|
Hmm. I tried bumping the gemspec version to |
I tried republishing a |
Hmm.
|
Oh, i get it! We have to peg the commit here:
|
Done in 5e21fbb |
That worked! Debugging next step. |
Well, the GET param is working: https://export.mapknitter.org/export?url=https://mapknitter.org/maps/ceres--2/warpables.json |
aha! |
OK, i took this pretty far. I now see this error: https://export.mapknitter.org/export?url=https://mapknitter.org/maps/ceres--2/warpables.json
On this line: require "mapknitterExporter"
require "json"
require "open-uri"
data = JSON.parse(open("https://mapknitter.org/maps/ceres--2/warpables.json").read)
class Export
attr_accessor :status, :tms, :geotiff, :zip, :jpg, :user_id, :size, :width, :height, :cm_per_pixel
def save
true
end
end
export = Export.new
MapKnitterExporter.run_export(1,1,export,1,'.',data,'') |
I removed the But i worry that the |
Aha! NaN involved dividing by zero! I added a check for zero. |
It's running |
i also had to increase the memory to 1gb. Depending on how this goes, we may need to increase it more, esp. for large exports. |
Next we'll be able to try (from publiclab/mapknitter#364) this one with a lot of images: https://mapknitter.org/maps/irish-uk-border-mapping/warpables.json |
ok - |
Closing this as it seems to be running!!! |
Just noting here that i've been making tweaks to
main.rb
to get this running, and we are almost there! We will also have to refactor therun_export
method once we adopt the finalexport.json
format, but are OK for now.We could do an interim which checks the first image and uses data from there, AND/OR averages scales from all images, as a fallback. The needed fields are:
id, user_id/map_id, scale
and optionallygoogle_api_key
I've been publishing new versions in Google Cloud Run once Cloud Build sees new commits on
main
branch of this repo, and testing.Also, just noting, i'm going to try to set up a custom domain at
export.mapknitter.org
!The text was updated successfully, but these errors were encountered: