# Mapillary\_tools upload errors

**URL:** <https://forum.mapillary.com/t/mapillary-tools-upload-errors/5042>\
**Category:** Command line tools\
**Created:** [June 25, 2021, 10:07pm UTC](https://forum.mapillary.com/t/mapillary-tools-upload-errors/5042 "2021-06-25T22:07:46Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![MikeN](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.mapillary.com/miken/32/68212_2.png) [@MikeN](https://forum.mapillary.com/u/MikeN)\
**Post date:** [June 25, 2021, 10:07pm UTC](https://forum.mapillary.com/t/mapillary-tools-upload-errors/5042/1 "2021-06-25T22:07:46Z")

</div>

When I try to upload, I get network errors frequently. In fact it takes several times to upload 300 images. Sample run - I have a Wireshark trace also; it tries to reconnect but it’s as though the web host was down:

Mapillary tools 0.7.1

Uploading 305 images with valid mapillary tags (Skipping 0)  
Compressing: 100%|████████████████████████████████████████████████████████████████████| 305/305 [00:16\<00:00, 18.33it/s]  
Uploading: 68%|████████████████████████████████████▌ | 155189248/229526817 [02:52\<04:20, 285591.65it/s]  
Traceback (most recent call last):  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/connection.py”, line 158, in \_new\_conn  
conn = connection.create\_connection(  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/util/connection.py”, line 80, in create\_connection  
raise err  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/util/connection.py”, line 70, in create\_connection  
sock.connect(sa)  
OSError: [Errno 101] Network is unreachable

During handling of the above exception, another exception occurred:

Traceback (most recent call last):  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/connectionpool.py”, line 597, in urlopen  
httplib\_response = self.\_make\_request(conn, method, url,  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/connectionpool.py”, line 343, in \_make\_request  
self.\_validate\_conn(conn)  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/connectionpool.py”, line 839, in \_validate\_conn  
conn.connect()  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/connection.py”, line 301, in connect  
conn = self.\_new\_conn()  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/connection.py”, line 167, in \_new\_conn  
raise NewConnectionError(  
urllib3.exceptions.NewConnectionError: \<urllib3.connection.VerifiedHTTPSConnection object at 0x7f939d058250\>: Failed to establish a new connection: [Errno 101] Network is unreachable

During handling of the above exception, another exception occurred:

Traceback (most recent call last):  
File “/home/allusers/.local/lib/python3.8/site-packages/requests/adapters.py”, line 439, in send  
resp = conn.urlopen(  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/connectionpool.py”, line 637, in urlopen  
retries = retries.increment(method, url, error=e, \_pool=self,  
File “/home/allusers/.local/lib/python3.8/site-packages/urllib3/util/retry.py”, line 399, in increment  
raise MaxRetryError(\_pool, url, error or ResponseError(cause))  
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host=‘[rupload.facebook.com](http://rupload.facebook.com)’, port=443): Max retries exceeded with url: /mapillary\_public\_uploads/mly\_tools\_50c65e9e6208960117ea95e8107774c5 (Caused by NewConnectionError(‘\<urllib3.connection.VerifiedHTTPSConnection object at 0x7f939d058250\>: Failed to establish a new connection: [Errno 101] Network is unreachable’))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):  
File “/home/allusers/.local/bin/mapillary\_tools”, line 8, in   
sys.exit(main())  
File “/home/allusers/.local/lib/python3.8/site-packages/mapillary\_tools/ **main**.py”, line 93, in main  
command.run(args)  
File “/home/allusers/.local/lib/python3.8/site-packages/mapillary\_tools/commands/upload.py”, line 112, in run  
upload(  
File “/home/allusers/.local/lib/python3.8/site-packages/mapillary\_tools/upload.py”, line 141, in upload  
uploader.upload\_sequence\_v4(  
File “/home/allusers/.local/lib/python3.8/site-packages/mapillary\_tools/uploader.py”, line 443, in upload\_sequence\_v4  
upload\_resp = service.upload(  
File “/home/allusers/.local/lib/python3.8/site-packages/mapillary\_tools/upload\_api\_v4.py”, line 60, in upload  
resp = requests.post(  
File “/home/allusers/.local/lib/python3.8/site-packages/requests/api.py”, line 116, in post  
return request(‘post’, url, data=data, json=json, \*\*kwargs)  
File “/home/allusers/.local/lib/python3.8/site-packages/requests/api.py”, line 60, in request  
return session.request(method=method, url=url, \*\*kwargs)  
File “/home/allusers/.local/lib/python3.8/site-packages/requests/sessions.py”, line 524, in request  
resp = self.send(prep, \*\*send\_kwargs)  
File “/home/allusers/.local/lib/python3.8/site-packages/requests/sessions.py”, line 637, in send  
r = adapter.send(request, \*\*kwargs)  
File “/home/allusers/.local/lib/python3.8/site-packages/requests/adapters.py”, line 516, in send  
raise ConnectionError(e, request=request)  
requests.exceptions.ConnectionError: HTTPSConnectionPool(host=‘[rupload.facebook.com](http://rupload.facebook.com)’, port=443): Max retries exceeded with url: /mapillary\_public\_uploads/mly\_tools\_50c65e9e6208960117ea95e8107774c5 (Caused by NewConnectionError(‘\<urllib3.connection.VerifiedHTTPSConnection object at 0x7f939d058250\>: Failed to establish a new connection: [Errno 101] Network is unreachable’))

---

<div class="post-metadata">

**Author:** ![MikeN](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.mapillary.com/miken/32/68212_2.png) [@MikeN](https://forum.mapillary.com/u/MikeN)\
**Post date:** [June 28, 2021, 3:44pm UTC](https://forum.mapillary.com/t/mapillary-tools-upload-errors/5042/2 "2021-06-28T15:44:31Z")

</div>

Disregard - still a problem but moved to a better location as a Github issue.

[https://github.com/mapillary/mapillary\_tools/issues/419](https://github.com/mapillary/mapillary_tools/issues/419)

---

<div class="post-metadata">

**Author:** ![JesseAKARaccoon](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.mapillary.com/jesseakaraccoon/32/70707_2.png) [@JesseAKARaccoon](https://forum.mapillary.com/u/JesseAKARaccoon)\
**Post date:** [June 29, 2021, 10:57pm UTC](https://forum.mapillary.com/t/mapillary-tools-upload-errors/5042/3 "2021-06-29T22:57:47Z")

</div>

I experienced a similar problem. It went away when I updated using  
`python3 -m pip install --upgrade git+https://github.com/mapillary/mapillary_tools`

---

<div class="post-metadata">

**Author:** ![MikeN](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.mapillary.com/miken/32/68212_2.png) [@MikeN](https://forum.mapillary.com/u/MikeN)\
**Post date:** [June 30, 2021, 2:21pm UTC](https://forum.mapillary.com/t/mapillary-tools-upload-errors/5042/4 "2021-06-30T14:21:45Z")

</div>

Thanks - the latest code on Github works and allows it to complete the uploads.

It’s a curious network problem; I wonder if a load balancer is dropping streams to regulate traffic? Even though it succeeds it can take 20 minutes to upload a minute’s worth of dashcam video because of timeouts and retries.

---

<div class="post-metadata">

**Author:** ![rubencarbonero](https://avatars.discourse-cdn.com/v4/letter/r/b3f665/32.png) [@rubencarbonero](https://forum.mapillary.com/u/rubencarbonero)\
**Post date:** [July 7, 2021, 8:29pm UTC](https://forum.mapillary.com/t/mapillary-tools-upload-errors/5042/5 "2021-07-07T20:29:22Z")

</div>

[Edit]

The mapillary\_tools binaries are no longer available at tools (dot) mapillary (dot) com.

Binaries for Windows and Mac OS are available here

> **[Releases · mapillary/mapillary\_tools](https://github.com/mapillary/mapillary_tools/releases/)**
>
> Command line tools for processing and uploading Mapillary imagery - mapillary/mapillary\_tools

---

<div class="post-metadata">

**Author:** ![MikeN](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.mapillary.com/miken/32/68212_2.png) [@MikeN](https://forum.mapillary.com/u/MikeN)\
**Post date:** [April 28, 2022, 10:46am UTC](https://forum.mapillary.com/t/mapillary-tools-upload-errors/5042/6 "2022-04-28T10:46:16Z")

</div>

FYI - with my latest upload, there are many upload errors. It recovers and continues but overall progress is slow. Does something in the Mapillary infrastructure need to be reset?

---

<div class="post-metadata">

**Author:** ![bob3bob3](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.mapillary.com/bob3bob3/32/68393_2.png) [@bob3bob3](https://forum.mapillary.com/u/bob3bob3)\
**Post date:** [April 28, 2022, 7:04pm UTC](https://forum.mapillary.com/t/mapillary-tools-upload-errors/5042/7 "2022-04-28T19:04:04Z")

</div>

My upload site doing BlackVue mp4’s is also having problems. Waiting for a 4000 off videos batch to complete before checking for missings via the web GUI.

Uses 0.8.1 Linux via docker.

Example debug

2022-04-25 07:05:52,658 - DEBUG - Sending upload\_end via IPC: {‘total\_sequence\_count’: 1570, ‘sequence\_idx’: 10, ‘entity\_size’: 52298394, ‘import\_path’: ‘to\_upload/20210514BV/20210514\_125339\_NF.mp4’, ‘md5sum’: ‘7ccb511956c124e898f5f56d3870a596’, ‘upload\_start\_time’: 1650870321.714409, ‘upload\_total\_time’: 30.53449058532715, ‘offset’: 52298394, ‘retries’: 0, ‘upload\_last\_restart\_time’: 1650870322.1237226, ‘upload\_first\_offset’: 0, ‘chunk\_size’: 0, ‘upload\_end\_time’: 1650870352.6582131}  
**2022-04-25 07:06:02,685 - DEBUG - API Logging for action upload\_failed\_upload: {‘images’: 0, ‘sequences’: 9, ‘size’: 447.5315, ‘uploaded\_size’: 447.5315, ‘speed’: 1.7194, ‘time’: 260.2831}**  
Traceback (most recent call last):  
File “/usr/local/lib/python3.8/dist-packages/urllib3/connection.py”, line 174, in \_new\_conn  
conn = connection.create\_connection(  
File “/usr/local/lib/python3.8/dist-packages/urllib3/util/connection.py”, line 72, in create\_connection  
for res in socket.getaddrinfo(host, port, family, socket.SOCK\_STREAM):  
File “/usr/lib/python3.8/socket.py”, line 918, in getaddrinfo  
for res in \_socket.getaddrinfo(host, port, family, type, proto, flags):  
socket.gaierror: [Errno -2] Name or service not known
