I'm developing a decentralised videogame using Unity. To connect Unity to Metamask I'm using a library called Web3GL.
When I try to connect my account to Metamask this message pops-up
I've been experiencing this problem for a long time now and I really don't know what to do about this! The fun part is that when I try to build and run directly from Unity it works but when I embed the game inside my webpage I receive this pop up.
Does anyone know how to help me?
The error points me to library code that I've never touched so I don't think I've created the problem.
This is a problem caused by encoding issues. You're probably using Brotli encoding in your WebGL builds (Build -> Player Settings -> Publishing Settings -> Compression Format). And it's known that somehow in local servers without HTTPS, this error may persist. (I'll investigate more and edit my answer including the reason in the future, hopefully). In order to get rid of the issue you may disable Brotli encoding or turn on Decompression Fallback in Publishing Settings.
Related
I'm trying to run my Flutter Web app on Local Area Network (intranet) in my work. But there is no internet access. And I have this issue “ Failed to load resource: net :: ERR_INTERNET_DISCONNECTED “. I think, problem is with canvaskit.js because my app try to download from internet. Do you have some idea how to fix it?
This is a common mistake when you use Flutter web within an Intranet that has no Internet access. I will try to explain it in detail.
In Flutter Web you can choose between two web renderers (more info here). The default one is CanvasKit, but there is also the HTML renderer.
The problem with CanvasKit web renderer is that when you start the application for the first time, it goes to unpkg.com and downloads two files: canvaskit.js and canvskit.wasm. Once downloaded, the browser caches them and Flutter doesn't need to download them again in the future.
But, if the app can't download these files, the application fails to start. Which is the problem that #TomášTorok mentions.
What are the solutions? There are two possibilities:
1 - Force your app to use the HTML web renderer, as it doesn't need to download anything over the Internet. This web renderer has some limitations that CanvasKit doesn't have, and vice versa (in this article they explain everything in detail)
To use the HTML in debug:
flutter run -d chrome --web-renderer html
OR if you want to build your app:
flutter build web --web-renderer html
2 - Download manually the canvaskit.js and canvaskit.wasm files from unpkg.com (example link), add them inside your project (inside /web folder), and force Flutter web to grab the local files and not download anything from the Internet.
It's a bit more work, but it's not complex either. You have the instructions in this link.
If I understood correctly;
There is nothing to do with flutter version or flutter channel. The error message is clearly explaining that internet is disconnected. The universal truth is you need a minimum speed internet to debug or release your flutter code development. Try to check the internet connection.
Reply back if this answer is helpful to you, also share how did you solved the issue.
I would like to access a special hardware (a penta scanner, for the wisest ;) ) from a web page.
The aim is to retrieve the information from the scanner and compute it on server side.
The problem here, is that I have to summon functions from a DLL that has to be on the client side. I have two leads for that:
Develop a COM DLL and use ActiveX
Try to get through a homemade extension for a web browser in order to communicate with the local DLLs.
I've tried the first option, and I got stuck and I've posted another thread about it. Anyway, even if it works, there are too many constraints about it (as to use IE or the fact that even Microsoft is not fond of this feature and banned it from edge).
The second method is something that I found on another forum but, I do not understand how I can interact with a browser extension (whatever the browser).
So what I am asking is:
Is it possible to use a web browser extension as a medium to a local DLL and if so, would you be so kind as to give a hint about how to do ar anything that might look like a start about how to do it (even just some key words to use on google, since mine didn't get anything)....
Thanks.
Based on my understanding, the motive to develop an Extensions is to enhance the feature and functionality for particular web browser.
You cannot control any hardware devices like printer or scanner with it.
So if your goal is to control the scanner from your web page with the help of any kind of extension than I think you cannot do this with Extension.
Here's a weird one.
I'm developing a Django/Bootstrap 3 web application, and recently I've started receiving this error in the JavaScript console:
Failed to register/update a ServiceWorker for scope ‘http://localhost:8000/’: Load failed with status 404 for script ‘http://localhost:8000/service-worker.js’
The funny thing is that I'm not actually attempting to use anything called ServiceWorker or service-worker.js and never have. I don't know what it's supposed to do. I do develop many other websites on localhost:8000 though, so I'm guessing it's some kind of left-overs from a different project.
The error does NOT show up when I try browsing in private mode, further implying that this is some kind of browser memory.
Still, I've reloaded with Ctrl-Shift-R and Shift-F5, and cleared all cookies for localhost. I've searched both my own code, as well as the entire Python environment for the strings service-worker.js and ServiceWorker but found nothing.
I'd really appreciate help with two things:
Learn what can cause this sort of thing.
Get rid of the error itself.
I'm using Firefox 64, Django 2.0.10 (with Django Debug Toolbar 1.9.1) with Bootstrap 3.3.7 on Ubuntu 18.04.
(Not even sure how to tag this thing, because I don't know what I'm dealing with.)
Type about:debugging#workers in Firefox bar. Find Service Worker for localhost and click unregister. It should helps if it is really leftover.
What it is?
Here, you can read about Service Workers, it has nothing to do with django or bootstrap. As far as I know, Bootstrap doesn't have service workers.
Are there any built-in methods in Electron / Node.js allowing to transfer a file over local network to another device?
I want to be able to send files locally from one computer to another (through an Electron app), but I also want it to be able to send files to smartphones.
How do I do it? Is it possible to just create a temp local server and download the file from another device by opening the URL (e.g. 192.168.0.x:x/file.txt)?
I tried using https://www.npmjs.com/package/quick-transfer which does exactly that, but for some reason opening the link on another device doesn't do anything.
As painful as it is for me to suggest... I'd recommend WebRTC for this, for these reasons:
It will make a local connection, when possible.
It will work over the internet as well, if required.
You can work around any firewall difficulties with TURN.
You will have compatibility with browsers.
You won't be opening up some server to a file that anyone on the network can get... transmission occurs over a secured connection. (This doesn't mean you can ignore other security aspects in your application however!)
Sample code: https://webrtc.github.io/samples/src/content/datachannel/filetransfer/
Commentary: It's amusing to me that in 2018, we still haven't solved the problem of sending a file from point A to point B. Network Neighborhood in Windows was the golden age, and now it's all screwed up with this newfangled cloud crap. :-) Obligatory: https://xkcd.com/949/
I'm facing an issue with chrome 28.
I build an application that use the webcam to take picture.
I had no problem with it, but since I upgrade to chrome 28, my application is not working anymore (I'm getting an error with the getUserMedia function).
Here is the message : {"constraintName":"","message":"","name":"PERMISSION_DENIED"}.
If I try to run the app code on a simple html and httpserver, I got no problem with it.
And when using the APP I'm not asked anymore if I allow the usage of the webcam.
I've tried to turn on some chrome flags for webrtc but nothing change.
Does anybody has/had this issue ?
Thanks !
You may have accidentally denied access to the webcam in the past. If your site is being served via HTTPS, that setting will be saved. This page has a description of that error and a screenshot that shows what the settings should look like.
Once you have tried all the above:
Make sure that there is no other program or browser tab accessing the camera.
If you are on Android, open a camera App to make sure that the it's not stuck (it happens to me all the time with Cyanogen).
What the browser is reporting is that a media source is missing (might be permissions, config or harware). More info here: http://webrtchacks.com/getusermedia/
Once you have made sure that the site is not blocked in Privacy content settings, Goto chrome://flags/#enable-permissions-bubbles in Chrome and ENable these . Now the notification will appear asking for permission to access the web cam , just click allow .