Skip to content

lua: ./9p.lua:138: attempt to get length of local 'from' (a nil value) #2

@metacoma

Description

@metacoma

There are two public 9p fileservers (without any authentication) and hosted by different OS/Platforms

  • tcp!9p.io!564 (9front OS)
  • tcp!registry.demo.metacoma.io!30099 (Inferno OS)
  1. If we connect to tcp!9p.io!564 and call Twalk ./ - everything is fine
  2. If we connect to tcp!9p.io!564 and call Twalk / then get error lua: ./9p.lua:138: attempt to get length of local 'from' (a nil value)
  3. If we connect to tcp!registry.demo!metacoma.io!30099 and call Twalk ./ then get error lua: ./9p.lua:118: file does not exist
  4. If we connect to tcp!registry.demo!metacoma.io!30099 and call Twalk / then get error lua: ./9p.lua:138: attempt to get length of local 'from' (a nil value)
  5. If we connect to tcp!registry.demo.metacoma.io!30099 and call Twalk ../ - everything is fine
  6. If we connect to tcp!9p.io!564 and call Twalk ../ - everything is fine, but the result is different from Twalk ./

How to call properly Twalk against root(/) path of these fileservers in the same way?

Steps to reproduce:

$ git clone -b 9p_walk_bug github.com/metacoma/lua9p
$ cd lua9p
#
# 1 case
#
$ lua ./tcp_testclient.lua 'tcp!9p.io!564' './'                 
Connecting to tcp!9p.io!564
Walking on ./
#
# 2 case
# 
$ lua ./tcp_testclient.lua 'tcp!9p.io!564' '/'
Connecting to tcp!9p.io!564
Walking on /
lua: ./9p.lua:138: attempt to get length of local 'from' (a nil value)
#
# 3 case
# 
$ lua ./tcp_testclient.lua 'tcp!registry.demo.metacoma.io!30099' '/'  
$ Connecting to tcp!registry.demo.metacoma.io!30099
Walking on /
lua: ./9p.lua:118: file does not exist
#
# 4 case
# 
$ lua ./tcp_testclient.lua 'tcp!registry.demo.metacoma.io!30099' './'  
$ Connecting to tcp!registry.demo.metacoma.io!30099
Walking on ./
lua: ./9p.lua:138: attempt to get length of local 'from' (a nil value)
#
# 5 case
# 
$ lua ./tcp_testclient.lua 'tcp!registry.demo.metacoma.io!30099' '../'
Connecting to tcp!registry.demo.metacoma.io!30099
Walking on ../
Ok
#
# 6 case
# 
$ lua ./tcp_testclient.lua 'tcp!9p.io!564' '../'                 
Connecting to tcp!9p.io!564
Walking on ../
Ok

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions