ament / ament/ament_lint

Support clang format file with multiple languages

Abierto
#364 1 comentario 0 reacciones 0 asignados Ver en GitHub
backlog
Lenguaje dominante
Python
Estrellas
50
Forks
129
Merge medio
3 d 10 h
PR fusionados (30 d)
3

Descripción

Right now we have a clang format file with multiple configurations for different languages.
With a call to `clang-format` this is working but not with `ament_clang_format`.

Example:

```
Language: Cpp
BasedOnStyle: Google
---
Language: Proto
BasedOnStyle: Google
```

Error:

```
Traceback (most recent call last):
File "/opt/ros/galactic/bin/ament_clang_format", line 11, in
load_entry_point('ament-clang-format==0.10.6', 'console_scripts', 'ament_clang_format')()
File "/opt/ros/galactic/lib/python3.8/site-packages/ament_clang_format/main.py", line 101, in main
data = yaml.safe_load(content)
File "/usr/lib/python3/dist-packages/yaml/__init__.py", line 162, in safe_load
return load(stream, SafeLoader)
File "/usr/lib/python3/dist-packages/yaml/__init__.py", line 114, in load
return loader.get_single_data()
File "/usr/lib/python3/dist-packages/yaml/constructor.py", line 49, in get_single_data
node = self.get_single_node()
File "/usr/lib/python3/dist-packages/yaml/composer.py", line 41, in get_single_node
raise ComposerError("expected a single document in the stream",
yaml.composer.ComposerError: expected a single document in the stream
in "", line 1, column 1:
Language: Cpp
^
but found another document
in "", line 55, column 1:
---
^

```

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.