TheThingsArchive / ttn

The Things Network Stack V2
https://www.thethingsnetwork.org
MIT License
461 stars 277 forks source link

ttnctl gateway coordinates height are formatted incorrectly #698

Closed crouchingbadger closed 6 years ago

crouchingbadger commented 6 years ago

This is a bug report for ttnctl.

What do you want to do? list gateways

What steps did you take? ./ttnctl-linux-386 gateways list

What went wrong or what is missing? the output for coordinates was not as expected. It appears the height value is not formatted correctly.

Do you have Screenshots? bward@ops:~$ ./ttnctl-linux-386 gateways list

    ID                      Activated       Frequency Plan  Coordinates

1 eui-008000000000xxxx false EU_863_870 (53.403680, -2.982405, %!f(int=10)) 2 eui-008000000000xxxx false EU_863_870 (51.741694, -1.264208, %!f(int=5)) 3 eui-008000000000xxxx false EU_863_870 (51.742362, -1.257518, %!f(int=8))

What kind of OS/Browser/Gateway are you using? Which version? linux, github latest version of ttnctl bward@ops:~$ ./ttnctl-linux-386 version INFO Got build information Branch=master BuildDate=2018-01-03T14:29:22Z Commit=8477a84c83a4c4e3e33749d62c03c8b4b4d21924 Version=v2.9.1-dev INFO This is an up-to-date ttnctl build

What are the IDs and EUIs of your Device/Gateway? (if applicable) N/A What do your configuration files look like? N/A

What do your log files look like? N/A

Can you fix this yourself and submit a pull request? Sorry, I wouldn't have the foggiest idea where to start.

htdvisser commented 6 years ago

Probably as simple as changing a %f to %d in ttnctl/cmd/gateways_list.go. Pull requests welcome.