Skip to content

Conversation

iiPythonx
Copy link
Contributor

Description

I couldn't find any existing issues about it, but this is very simple patch regardless.
This PR fixes the listen() function using the same local options variable twice despite them being two seperate objects (see the diff for an example).

Additionally, FFI.cast only takes 2 arguments, however socketify was giving it 3. That has also been fixed.
From my testing, this PR works perfectly, otherwise socketify hard crashes with FFI throwing an error for the additional argument.

The code I used to produce these issues in the first place:

app.listen({
    "port": 8080,
    "host": "0.0.0.0"
}, lambda config: print("Running.")) 

Sorry if this goes against contribution guidelines, it's just way too simple of a fix to create an issue for in my opinion. It's also a very reproducible problem, I'm surprised I can't find anything about it in Github Issues.

@cirospaciari cirospaciari merged commit df212ef into cirospaciari:main Jul 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants