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

Getting Error while importing csv file in pelias #109

Open
bmyashaswi opened this issue Jul 30, 2024 · 0 comments
Open

Getting Error while importing csv file in pelias #109

bmyashaswi opened this issue Jul 30, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@bmyashaswi
Copy link

bmyashaswi commented Jul 30, 2024

Hi there,
I have problem when import custom csv file I getting error :

Here is the step i followed:
step : 1
git clone https://github.com/pelias/csv-importer
cd csv-importer

step: 2 npm install
step:3 create a pelias.json file added the below code

{
"logger": {
"level": "debug",
"timestamp": false
},
"esclient": {
"apiVersion": "7.5",
"hosts": [
{
"protocol": "http",
"host": "localhost",
"port": 9200
}
]
},
"api": {
"targets": {
"csv": ["name"]
}
},
"elasticsearch": {
"settings": {
"index": {
"refresh_interval": "10s",
"number_of_replicas": "0",
"number_of_shards": "1"
}
}
},
"imports": {
"whosonfirst": {
"datapath": "csv-importer/wof/data/whosonfirst-data-admin-in-latest.db",
"importPostalcodes": true
},
"csv": {
"datapath": "./data",
"files": ["/example.csv"]
}
}
}

my csv containes like this;

id,name,latitude,longitude,address,city,state,postcode
1,Example Place,37.7749,-122.4194,123 Example St,San Francisco,CA,94103
2,Another Place,34.0522,-118.2437,456 Another Ave,Los Angeles,CA,90001

step :4 I given permission for .csv file
step :5 ./bin/start

After this i am getting error like this:

tech@tech-HP-280-Pro-G6-Microtower-PC:/media/tech/New Volume/pelias/csv-importer$ ./bin/start
info: [csv-importer] Importing 1 files.
info: [csv-importer] Creating read stream for: data/example.csv
debug: [wof-admin-lookup] [postalCityMap] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/ASM.tsv
debug: [wof-admin-lookup] [postalCityMap] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/GUM.tsv
debug: [wof-admin-lookup] [postalCityMap] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/MNP.tsv
debug: [wof-admin-lookup] [postalCityMap] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/PRI.tsv
debug: [wof-admin-lookup] [postalCityMap] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/USA.tsv
debug: [wof-admin-lookup] [postalCityMap] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/USA.override.tsv
debug: [wof-admin-lookup] [postalCityMap] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/VIR.tsv
debug: [wof-admin-lookup] [postalCityMap] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/NLD.tsv
debug: [wof-admin-lookup] [useEndonyms] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/aliases/country-endonyms.psv
debug: [wof-admin-lookup] [useEndonyms] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/aliases/region-endonyms.psv
debug: [wof-admin-lookup] [useEndonyms] loaded /media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/data/aliases/locality-megacity-endonyms.psv
info: [csv-importer] Total time taken: 3.954s

/media/tech/New Volume/pelias/csv-importer/node_modules/pelias-wof-admin-lookup/src/localPipResolver.js:19
throw err;
^
unable to locate sqlite folder
(Use node --trace-uncaught ... to show where the exception was thrown)

Node.js v20.15.1
tech@tech-HP-280-Pro-G6-Microtower-PC:/media/tech/New Volume/pelias/csv-importer$

@bmyashaswi bmyashaswi added the bug Something isn't working label Jul 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant