# MailboxError: transport failed when doing wandb.init() in azure ml

**URL:** <https://community.wandb.ai/t/mailboxerror-transport-failed-when-doing-wandb-init-in-azure-ml/4636>\
**Category:** W&B Help\
**Created:** [June 27, 2023, 5:04pm UTC](https://community.wandb.ai/t/mailboxerror-transport-failed-when-doing-wandb-init-in-azure-ml/4636 "2023-06-27T17:04:32Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![rahat](https://avatars.discourse-cdn.com/v4/letter/r/67e7ee/32.png) [@rahat](https://community.wandb.ai/u/rahat)\
**Post date:** [June 27, 2023, 5:04pm UTC](https://community.wandb.ai/t/mailboxerror-transport-failed-when-doing-wandb-init-in-azure-ml/4636/1 "2023-06-27T17:04:32Z")

</div>

code:

```auto
wandb.login()
wandb.init(project="NREGA_ASSET_CLASSIFER",
           name="delete"
           )

```

following is the error:

```auto
type or paste code here

```

Thread HandlerThread:  
Traceback (most recent call last):  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/internal/internal\_util.py”, line 49, in run  
self.\_run()  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/internal/internal\_util.py”, line 100, in \_run  
self.\_process(record)  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/internal/internal.py”, line 279, in \_process  
self.\_hm.handle(record)  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/internal/handler.py”, line 136, in handle  
handler(record)  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/internal/handler.py”, line 146, in handle\_request  
handler(record)  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/internal/handler.py”, line 708, in handle\_request\_run\_start  
self.\_tb\_watcher = tb\_watcher.TBWatcher(  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/internal/tb\_watcher.py”, line 126, in **init**  
wandb.tensorboard.reset\_state()  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/lib/lazyloader.py”, line 58, in **getattr**  
module = self.\_load()  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/lib/lazyloader.py”, line 33, in \_load  
module = importlib.import\_module(self. **name** )  
File “/anaconda/envs/azureml\_py38/lib/python3.8/importlib/ **init**.py”, line 127, in import\_module  
return \_bootstrap.\_gcd\_import(name[level:], package, level)  
File “”, line 1014, in \_gcd\_import  
File “”, line 991, in \_find\_and\_load  
File “”, line 975, in \_find\_and\_load\_unlocked  
File “”, line 671, in \_load\_unlocked  
File “”, line 783, in exec\_module  
File “”, line 219, in \_call\_with\_frames\_removed  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/integration/tensorboard/ **init**.py”, line 3, in   
from .log import \_log, log, reset\_state, tf\_summary\_to\_dict # noqa: F401  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/integration/tensorboard/log.py”, line 35, in   
Summary = pb.Summary if pb else None  
File “/anaconda/envs/azureml\_py38/lib/python3.8/importlib/util.py”, line 245, in **getattribute**  
self. **spec**.loader.exec\_module(self)  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/tensorboard/compat/proto/summary\_pb2.py”, line 17, in   
from tensorboard.compat.proto import tensor\_pb2 as tensorboard\_dot\_compat\_dot\_proto\_dot\_tensor\_\_pb2  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/tensorboard/compat/proto/tensor\_pb2.py”, line 16, in   
from tensorboard.compat.proto import resource\_handle\_pb2 as tensorboard\_dot\_compat\_dot\_proto\_dot\_resource\_\_handle\_\_pb2  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/tensorboard/compat/proto/resource\_handle\_pb2.py”, line 16, in   
from tensorboard.compat.proto import tensor\_shape\_pb2 as tensorboard\_dot\_compat\_dot\_proto\_dot\_tensor\_\_shape\_\_pb2  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/tensorboard/compat/proto/tensor\_shape\_pb2.py”, line 36, in   
\_descriptor.FieldDescriptor(  
File “/anaconda/envs/azureml\_py38/lib/python3.8/site-packages/google/protobuf/descriptor.py”, line 561, in **new**  
\_message.Message.\_CheckCalledFromGeneratedFile()  
TypeError: Descriptors cannot not be created directly.  
If this call came from a \_pb2.py file, your generated code is out of date and must be regenerated with protoc \>= 3.19.0.  
If you cannot immediately regenerate your protos, some other possible workarounds are:

1. Downgrade the protobuf package to 3.20.x or lower.
2. Set PROTOCOL\_BUFFERS\_PYTHON\_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).

## More information: [Changes announced May 6, 2022 | Protocol Buffers Documentation](https://developers.google.com/protocol-buffers/docs/news/2022-05-06#python-updates) wandb: ERROR Internal wandb error: file data was not synced Problem at: /tmp/ipykernel\_25101/184177164.py 1

MailboxError Traceback (most recent call last)  
Cell In[10], line 1  
----\> 1 wandb.init(project=“NREGA\_ASSET\_CLASSIFER”,  
2 name=“delete”  
3 )

File /anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/wandb\_init.py:1171, in init(job\_type, dir, config, project, entity, reinit, tags, group, name, notes, magic, config\_exclude\_keys, config\_include\_keys, anonymous, mode, allow\_val\_change, resume, force, tensorboard, sync\_tensorboard, monitor\_gym, save\_code, id, settings)  
1169 if logger is not None:  
1170 logger.exception(str(e))  
 → 1171 raise e  
1172 except KeyboardInterrupt as e:  
1173 assert logger

File /anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/wandb\_init.py:1152, in init(job\_type, dir, config, project, entity, reinit, tags, group, name, notes, magic, config\_exclude\_keys, config\_include\_keys, anonymous, mode, allow\_val\_change, resume, force, tensorboard, sync\_tensorboard, monitor\_gym, save\_code, id, settings)  
1150 except\_exit = wi.settings.\_except\_exit  
1151 try:  
 → 1152 run = wi.init()  
1153 except\_exit = wi.settings.\_except\_exit  
1154 except (KeyboardInterrupt, Exception) as e:

File /anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/wandb\_init.py:798, in \_WandbInit.init(self)  
796 run\_start\_handle = backend.interface.deliver\_run\_start(run.\_run\_obj)  
797 # TODO: add progress to let user know we are doing something  
 → 798 run\_start\_result = run\_start\_handle.wait(timeout=30)  
799 if run\_start\_result is None:  
800 run\_start\_handle.abandon()

File /anaconda/envs/azureml\_py38/lib/python3.8/site-packages/wandb/sdk/lib/mailbox.py:281, in MailboxHandle.wait(self, timeout, on\_probe, on\_progress, release, cancel)  
279 if self.\_keepalive and self.\_interface:  
280 if self.\_interface.\_transport\_keepalive\_failed():  
 → 281 raise MailboxError(“transport failed”)  
283 found, abandoned = self.\_slot.\_get\_and\_clear(timeout=wait\_timeout)  
284 if found:  
285 # Always update progress to 100% when done

MailboxError: transport failed

---

<div class="post-metadata">

**Author:** ![luis\_bergua](https://avatars.discourse-cdn.com/v4/letter/l/dbc845/32.png) [@luis\_bergua](https://community.wandb.ai/u/luis_bergua)\
**Post date:** [June 29, 2023, 10:14am UTC](https://community.wandb.ai/t/mailboxerror-transport-failed-when-doing-wandb-init-in-azure-ml/4636/2 "2023-06-29T10:14:52Z")

</div>

Hi @rahat, thanks for reporting this! Could you please send `debug.log` and `debug-internal.log` for the affected run? These files are under your local folder `wandb/run-<date>_<time>-<run-id>/logs` in the same directory where you’re running your code.

This might be happening because a lack of permissions, could you please test is setting the following environment variable would fix the issue?

`os.environ["WANDB_DIR"] `  
`os.environ["WANDB_CONFIG_DIR"] `  
`os.environ["WANDB_CACHE_DIR"] `  
`os.environ["WANDB_DATA_DIR"]`

---

<div class="post-metadata">

**Author:** ![luis\_bergua](https://avatars.discourse-cdn.com/v4/letter/l/dbc845/32.png) [@luis\_bergua](https://community.wandb.ai/u/luis_bergua)\
**Post date:** [July 4, 2023, 2:30pm UTC](https://community.wandb.ai/t/mailboxerror-transport-failed-when-doing-wandb-init-in-azure-ml/4636/3 "2023-07-04T14:30:27Z")

</div>

Hi Rahat,

We wanted to follow up with you regarding your support request as we have not heard back from you. Please let us know if we can be of further assistance or if your issue has been resolved.

Best,

Weights & Biases

---

<div class="post-metadata">

**Author:** ![luis\_bergua](https://avatars.discourse-cdn.com/v4/letter/l/dbc845/32.png) [@luis\_bergua](https://community.wandb.ai/u/luis_bergua)\
**Post date:** [July 6, 2023, 4:01pm UTC](https://community.wandb.ai/t/mailboxerror-transport-failed-when-doing-wandb-init-in-azure-ml/4636/4 "2023-07-06T16:01:12Z")

</div>

Hi Rahat, since we have not heard back from you we are going to close this request. If you would like to re-open the conversation, please let us know!

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex020/uploads/wandb/original/1X/366b649231631dbab896843020da0056074ac79d.png) [@system](https://community.wandb.ai/u/system)\
**Post date:** [September 4, 2023, 4:01pm UTC](https://community.wandb.ai/t/mailboxerror-transport-failed-when-doing-wandb-init-in-azure-ml/4636/5 "2023-09-04T16:01:59Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
