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

"Solver loading..." endless #1

Open
TinoJ opened this issue Dec 25, 2023 · 7 comments
Open

"Solver loading..." endless #1

TinoJ opened this issue Dec 25, 2023 · 7 comments

Comments

@TinoJ
Copy link

TinoJ commented Dec 25, 2023

Hi Dan,
I just found your code. When I upload it to my Apache web server, the browser shows a loading status for the 'Solve' button as 'Solver loading'. On your demo website, however, it just shows 'Solve'. Locally on my computer, I experience the same behavior, also with Apache. I suspect there might be something else I need to configure. Is it ensured that the website automatically detects Python or via the loaded scripts, or do I need to set something up?
I'm just curious to get it up and running.
Merry Christmas, Tino. 😊

@dangarfield
Copy link
Owner

Strange, does the public link work in your browser? Eg https://dangarfield.github.io/sokoban-solver/

My gut instinct is that your apache server is not configured to respond with the correct mime format for wasm. There is no config in this code relating to the hosting, and github.io as well as https://www.npmjs.com/package/serve works well. Apache does tend to be a bit more difficult to configure in general.

Give me a few days and I'll have a look with apache, but try with a little more 'modern' static web server for the time being

@dangarfield
Copy link
Owner

Paste your browser console log too please

@TinoJ
Copy link
Author

TinoJ commented Dec 25, 2023

Your demo server is accessible for me. I tried to configure the level, where I am stuck, but the "Solve" on your demo website does not end. Maybe the calculation is too complex? Your pre-configured examples work.

I did add the line "AddType application/wasm .wasm" to the apache config. That didn't help (yet).

(I am not a developer ;-) ;-) ;-))

Console Errors:
The Components object should no longer be used. It will be removed soon. [sokoban-solver] (http://localhost/sokoban-solver/)
Uncaught (in promise) TypeError: SpeechRecognition is not a constructor
bindClicks http://localhost/sokoban-solver/main.js:113
init http://localhost/sokoban-solver/main.js:442
main.js:113:23

The console log in ugly text format is attached.
console-export-2023-12-25_21-8-20.txt
Nice screenshot:
2023-12-25_21-13-10_

BTW, I am trying to solve this: :-)
image

@dangarfield
Copy link
Owner

Thanks, I'll look in a few days

@dangarfield
Copy link
Owner

Apologies for the delay.
I just looked at this and noticed two things:

  1. This is very difficult to solve. I don't think that it's impossible, but it's taking my computer a LOT of iterations 1,000,000 and counting. I'll leave it to see how far it gets
  2. I don't have any timeout or error mechanism. I've just committed some code to improve the error mechanism.

@TinoJ
Copy link
Author

TinoJ commented Jan 29, 2024

Thank you very much, I just updated the sources and are running the program. Where can I see the iterations?

@dangarfield
Copy link
Owner

I added some debugging my the development version, it isn't available in the public one. I'll add this at some point in the next week or so. I might re-engineer the whole lot

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

No branches or pull requests

2 participants