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

OWM-script broken on Luci-master based builds #507

Closed
torte71 opened this issue Dec 31, 2017 · 13 comments
Closed

OWM-script broken on Luci-master based builds #507

torte71 opened this issue Dec 31, 2017 · 13 comments

Comments

@torte71
Copy link
Member

torte71 commented Dec 31, 2017

https://buildbot.berlin.freifunk.net/buildbot/unstable/ar71xx-generic/578/VERSION.txt
Firmware: git branch "SAm0815_experimental", revision f6104a8

Even though location settings are correctly entered in the wizard page (and made sure, the lat/lon values are not mixed up to meet some berlin friends in the arabian sea), the device doesn't get listed on https://openwifimap.net/
The device is running for over a day, so I think that should be enough time for an update?

@SvenRoederer
Copy link
Contributor

What is the output when you run "owm.lua" from the command-line?

@torte71
Copy link
Member Author

torte71 commented Dec 31, 2017 via email

@SvenRoederer
Copy link
Contributor

seems like the LUCI-Api has changed again (see freifunk-berlin/firmware-packages#109 for something similar).
The current error causes the owm-script to fail to run and so there will be no upload to the server.

error comes from https://github.com/freifunk-berlin/firmware-packages/blob/master/utils/luci-app-owm/files/owm.lua#L74, which is very likely causes by
https://github.com/freifunk-berlin/firmware-packages/blob/master/utils/luci-app-owm/luasrc/owm.lua#L447 and following

@SvenRoederer SvenRoederer changed the title LEDE build: Devices not listed on openwifimap OWM-script broken on "experimental" builds Jan 21, 2018
@SvenRoederer
Copy link
Contributor

SvenRoederer commented Mar 6, 2018

sys.net.arptable() call in https://github.com/freifunk-berlin/firmware-packages/blob/master/utils/luci-app-owm/luasrc/owm.lua#L447 has changed.
Changing the line to

local arptable = {}

makes the code run, but without the values.

@SvenRoederer SvenRoederer changed the title OWM-script broken on "experimental" builds OWM-script broken on Luci-master based builds Mar 16, 2018
@ikreb7
Copy link

ikreb7 commented Jun 3, 2018

Hello @SvenRoederer ,

I have the same problem. Where do I exactly find this file at my router, please? Will this be fixed in a newer version soon?

@SvenRoederer
Copy link
Contributor

@SvenRoederer
Copy link
Contributor

Btw. do we really need the anonymized MAC-adresses in the public OWM-data?
What's their purpose?

@booo
Copy link
Member

booo commented Aug 21, 2018

Some functions where dropped in the luci code base with this commit this openwrt/luci@366707a.

luci.sys.net.arptable() - replaced by luci.ip.neighbors()

Maybe it's enough to replace the function call?

booo added a commit to freifunk-berlin/firmware-packages that referenced this issue Aug 21, 2018
With a commit in the luci code base the function luci.sys.net.arptable
was replaced by luci.ip.neighbors:

openwrt/luci@366707a

The missing function definition caused the owm.lua program to fail.

Fixes freifunk-berlin/firmware#507
@booo
Copy link
Member

booo commented Aug 23, 2018

I merged a commit that should fix the problem.

We still have to update the feed for the berlin packages in the firmware.

SvenRoederer pushed a commit to freifunk-berlin/firmware-packages that referenced this issue Aug 23, 2018
With a commit in the luci code base the function luci.sys.net.arptable
was replaced by luci.ip.neighbors:

openwrt/luci@366707a

The missing function definition caused the owm.lua program to fail.

Fixes freifunk-berlin/firmware#507
@SvenRoederer
Copy link
Contributor

still fails for me with

/usr/bin/lua: /usr/lib/lua/luci/owm.lua:447: attempt to index global 'luci' (a nil value)
stack traceback:
/usr/lib/lua/luci/owm.lua:447: in function 'get'
/usr/sbin/owm.lua:74: in main chunk
[C]: ?

@SvenRoederer SvenRoederer reopened this Aug 23, 2018
@SvenRoederer
Copy link
Contributor

SvenRoederer commented Aug 23, 2018

/usr/bin/lua: /usr/lib/lua/luci/owm.lua:447: attempt to index global 'luci' (a nil value)

is fixed by freifunk-berlin/firmware-packages@c883485.

the code now fails with

/usr/bin/lua: /usr/lib/lua/luci/owm.lua:452: attempt to index field 'HW address' (a nil value)
stack traceback:
/usr/lib/lua/luci/owm.lua:452: in function 'get'
/usr/sbin/owm.lua:74: in main chunk
[C]: ?

@booo
Copy link
Member

booo commented Aug 24, 2018

Sorry for the inconvenience. Seems like my testing procedure was flawed.

I will prepare a patch for the outstanding problems. We have to change the field names and convert them from userdata to string.

@booo
Copy link
Member

booo commented Sep 15, 2018

As far as I can see we fixed this.

@booo booo closed this as completed Sep 15, 2018
SvenRoederer added a commit that referenced this issue Sep 6, 2019
76a5139 bmx7: update to 7.1.1
ff5100e Merge pull request #507 from aparcar/bmx7-7.1.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants