-
-
Notifications
You must be signed in to change notification settings - Fork 38
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
serve .port:18966 [
GET "/" [ "This is the homepage" ]
GET "/post" $[id][
send.html ~"This is the post with id: |id|"
]
POST "/getinfo" $[id][
send.json write.json ø #[
i: id
msg: "This is some info"
]
]
]
; run the app and go to localhost:18966 - that was it!
; the app will respond to GET requests to "/" or "/post?id=..."
; and also POST requests to "/getinfo" with an 'id' parameter
The Net\serve method's post feature does not work as expected. When invoked, it raises a segmentation fault with the message: SIGSEGV: Illegal storage access. (Attempt to read from nil?)
To Reproduce
- Prepare a function using Net\serve with the post method as demonstrated in the official documentation.
- Run the function on platforms between versions 0.983 to 0.984.
- Platform: Windows and Linux.
- Post request
request.post "http://localhost:18966/getinfo" #[ id:5 ] - Observe the crash and the error message.
Expected behavior
The post method should execute normally and not crash.
Screenshots
Desktop (please complete the following information):
- OS: Windows, Linux
- Version: 0.983~0.984
Additional context
- Please refer to the Net\serve documentation.
drkameleon
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working