roapi
roapi copied to clipboard
basic example fails on osx
when toying around with the basic example from the main README document I observe HTTP URI resolution problems:
roapi-http --version
roapi-http 0.5.3
roapi-http --table "uk_cities=https://raw.githubusercontent.com/roapi/roapi/main/test_data/uk_cities_with_headers.csv"
Error: failed to lookup address information: nodename nor servname provided, or not known
# strangely - this fails with the same error when running locally:
wget https://raw.githubusercontent.com/roapi/roapi/main/test_data/uk_cities_with_headers.csv
roapi-http --table "uk_cities=uk_cities_with_headers.csv"
Error: failed to lookup address information: nodename nor servname provided, or not known
when running natively on a Catalina OsX.
However, when executed inside your docker container - it works just fine.
looks like it might have something to do with your local dns? Are you able to load https://raw.githubusercontent.com/roapi/roapi/main/test_data/uk_cities_with_headers.csv in your browser? What do you get from running nslookup raw.githubusercontent.com?
Yes that works fine (loading https://raw.githubusercontent.com/roapi/roapi/main/test_data/uk_cities_with_headers.csv in the browser - and also via wget (as outlined above) even when manually downloading like:
wget https://raw.githubusercontent.com/roapi/roapi/main/test_data/uk_cities_with_headers.csv
and then later:
roapi-http --table "uk_cities=uk_cities_with_headers.csv"
Error: failed to lookup address information: nodename nor servname provided, or not known
I still get the error
here the output for the DNS query:
nslookup raw.githubusercontent.com
Server: 172.16.39.254
Address: 172.16.39.254#53
Non-authoritative answer:
Name: raw.githubusercontent.com
Address: 185.199.108.133
Name: raw.githubusercontent.com
Address: 185.199.110.133
Name: raw.githubusercontent.com
Address: 185.199.111.133
Name: raw.githubusercontent.com
Address: 185.199.109.13
Could you give the workaround in https://github.com/instructure/canvas-data-loader/issues/3#issuecomment-352920399 a try to see if we can isolate the issue to local dns resolution?
Strangely, adding the following entry to the /etc/hosts file:
14 172.16.39.254 raw.githubusercontent.com
does not solve the problem (in fact when enabled also prevents wget of downloading the CSV file).
But I also do not fully understand why it should/would help: as written above the problem also occurs when manually executing wget, downloading the CSV so it no longer resides on github but is local. But:
roapi-http --table "uk_cities=uk_cities_with_headers.csv"
Error: failed to lookup address information: nodename nor servname provided, or not known
it would still fail nonetheless.
Hi @geoHeil. Have you tried this more recently? Wondering if this has been resolved for you or if this remains an open issue for you. I'm trying to clean up and prioritize open issues here. Thanks.
CLI always fails on osx (for me) but if you feed roapi the configuration file then it usually works fine. Furthermore, also due to the database issues I would recommend most to use roapi in the docker container
Okay, thanks for feedback. I am inclined to close this issue for now given that you do indeed have a workaround and this cannot be reproduced. We can reopen if this emerges as an issue for more people Sound good to you, @geoHeil ? Thanks again!
ok