<div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small;color:#000000">Hi Stefano,</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small;color:#000000"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small;color:#000000">this is the problem I saw too. My guess is that it is a simple encoding bug somewhere. But I do not have the time right now to investigate, unfortunately.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small;color:#000000"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small;color:#000000">- Bert -</div><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Feb 27, 2020 at 2:25 PM stefano federici <<a href="mailto:s_federici@yahoo.com">s_federici@yahoo.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>                Dear Bert,<br>I realized that I didn't check really everything. Indeed, I can open in ScratchJS projects that I created with Scratch 1.4, but I cannot reopen projects modified in ScratchJS, neither in ScratchJS nor in Scratch 1.4. I get the following error message in both cases:<br><br>Could not read project; file may be damaged<br>(key not found)<br><br>Is this a known problem? Is there a way to overcome this limitation?<br><br>Thanks in advance<br><br>Cheers<br>Stefano<br><br><br>Stefano Federici<br>-------------------------------------------------<br>Università degli Studi di Cagliari<br>Facoltà di Studi Umanistici<br>Dipartimento di Pedagogia, Psicologia e Filosofia<br>Via Is Mirrionis 1, 09123 Cagliari, Italia<br>-------------------------------------------------<br>Tel: +39 349 818 1955 Fax: +39 070 675 7113<br><br>            </div>            <div style="margin:10px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">                        <div style="font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:13px;color:rgb(38,40,42)">                                <div>                    Il lunedì 10 febbraio 2020, 00:29:58 CET, Bert Freudenberg <<a href="mailto:bert@freudenbergs.de" target="_blank">bert@freudenbergs.de</a>> ha scritto:                </div>                <div><br></div>                <div><br></div>                <div><div id="gmail-m_-5227118012385929148yiv7142339213"><div><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)">Hi Stefano,</span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)"><br clear="none"></span></div><div><span style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;font-size:small">it is possible to export your project to your </span>hard disk:</div><div><br clear="none"></div><div>1. run ScratchJS via <a rel="nofollow" shape="rect" href="https://squeak.js.org/scratch/#fullscreen" target="_blank">https://squeak.js.org/scratch/#fullscreen</a></div><div>2. Inside Scratch, click "Save" as you normally would, give it a name. I just did that and named mine "test".</div><div>3. go to <a rel="nofollow" shape="rect" href="https://squeak.js.org/run/" target="_blank">https://squeak.js.org/run/</a> and scroll down inside the file box: </div><div><div><img src="cid:1708926c074cb971f162" alt="image.png" width="562" height="230"><br clear="none"></div></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)">4. click the "/Scratch/Scratch Projects/<a rel="nofollow" shape="rect" href="http://test.sb" target="_blank">test.sb</a>" link to download the project file.</span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)"><br clear="none"></span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)"><br clear="none"></span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)">To import an older project you simply drag-and-drop it into ScratchJS. Or drop it into the "run" page and then use Scratch's file dialog - you just need to navigate up to the right folder (Click "Computer" then "SqueakJS"):</span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)"><br clear="none"></span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><div><img src="cid:1708926c074cb971f163" alt="image.png" width="562" height="293"><br clear="none"></div></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)"><br clear="none"></span></div><div><span style="color:rgb(34,34,34);font-family:Arial,Helvetica,sans-serif;font-size:small">When I just tested this it said the file was corrupted, not sure if that is a general </span>problem or not. </div><div>Someone should investigate - to get to the Morphic desktop, shift-click the loop in the R of the SCRATCH logo:</div><div><br clear="none"></div><div><div><img src="cid:1708926c074cb971f161" alt="image.png" width="562" height="224"><br clear="none"></div></div><div><br clear="none"></div><div>Feel free to file bug reports / feature requests at <a rel="nofollow" shape="rect" href="https://github.com/bertfreudenberg/SqueakJS/issues/" target="_blank">https://github.com/bertfreudenberg/SqueakJS/issues/</a></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)"><br clear="none"></span></div><div>It would be relatively simple to make a proper stand-alone app out of this by packaging it via Electron, and using the actual file system instead of the in-browser file system. I just do not have the time for that currently.</div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)"><br clear="none"></span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)">Cheers!</span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)"><br clear="none"></span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)">- Bert -</span></div><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)"><br clear="none"></span></div><div id="gmail-m_-5227118012385929148yiv7142339213yqt42062"><div style="font-family:arial,helvetica,sans-serif;font-size:small;color:rgb(0,0,0)"><span style="font-family:Arial,Helvetica,sans-serif;color:rgb(34,34,34)">On Sun, Feb 9, 2020 at  7:32 AM David T. Lewis <<a rel="nofollow" shape="rect" href="mailto:lewis@mail.msen.com" target="_blank">lewis@mail.msen.com</a>> wrote:</span><br clear="none"></div></div></div><div id="gmail-m_-5227118012385929148yiv7142339213yqt25484"><div><blockquote style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Stefano,<br clear="none"><br clear="none">I think that your understanding is correct. SqueakJS stores files<br clear="none">in an internal database, so the Scratch files that you saved do not<br clear="none">appear directly on your PC.<br clear="none"><br clear="none">I do not know if it possible to copy those files to the file system<br clear="none">on your PC, but hopefully someone on the squeak-dev mailing list will<br clear="none">have an answer.<br clear="none"><br clear="none">Thanks for asking,<br clear="none">Dave<br clear="none"><br clear="none"><br clear="none">On Sun, Feb 09, 2020 at 09:51:25AM +0000, stefano federici wrote:<br clear="none">>  <br clear="none">>  >> you want to understand where the Scratch files are stored on your PC.<br clear="none">> > Correct. So that I can easily open my old Scratch projects and I can send projects that I develop in ScratchJS to other people<br clear="none">> <br clear="none">> UPDATE: I created and saved a project in the "SqueakJS" folder (the one shown in ScratchJS) and I made a full search in my PC. The file was not found. So, I guess projects are just saved in an internal SqueakJS DB? If it is so, this makes unfortunately ScratchJS useless for my purposes. And I have no sufficient javascript/smalltalk knowledge to try myself to change this behaviour (that I guess would possible in principle, as a lot of JS apps allow to save file locally).<br clear="none">> <br clear="none">> Cheers<br clear="none">> Stefano<br clear="none">> <br clear="none">> > I am also CC'ing the squeak-dev mailing list where some of the real Scratch and SqueakJS experts reside.<br clear="none">> <br clear="none">> Thanks a lot Dave<br clear="none">> <br clear="none">> > I think that you are asking about running Scratch on Bert Freudenberg's SqueakJS, which is a modern Squeak virtual machine implemented entirely in JavaScript for HML5<br clear="none">> <br clear="none">> Correct<br clear="none">> <br clear="none">> > If I understand your question correctly, you are asking about how to run Scratch on SqueakJS locally on your PC<br clear="none">> <br clear="none">> Yes. I partially solved the problem by downloading page <a rel="nofollow" shape="rect" href="https://squeak.js.org/run/" target="_blank">https://squeak.js.org/run/</a> and by dragging my Scratch.image file into the page. ScratchJS runs apparently fine. I also partially solved the problem of running local files, by dragging the Scratch projects on the Scratch app running in SqueakJS<br clear="none">> <br clear="none">> > you want to understand where the Scratch files are stored on your PC.<br clear="none">> <br clear="none">> Correct. So that I can easily open my old Scratch projects and I can send projects that I develop in ScratchJS to other people<br clear="none">> <br clear="none">> Thanks for your help<br clear="none">> <br clear="none">> Stefano Federici<br clear="none">> -------------------------------------------------<br clear="none">> Universit?? degli Studi di Cagliari<br clear="none">> Facolt?? di Studi Umanistici<br clear="none">> Dipartimento di Pedagogia, Psicologia e Filosofia<br clear="none">> Via Is Mirrionis 1, 09123 Cagliari, Italia<br clear="none">> -------------------------------------------------<br clear="none">> Tel: +39 349 818 1955 Fax: +39 070 675 7113<br clear="none">> <br clear="none">> Il domenica 9 febbraio 2020, 04:05:38 CET, David T. Lewis <<a rel="nofollow" shape="rect" href="mailto:lewis@mail.msen.com" target="_blank">lewis@mail.msen.com</a>> ha scritto:<br clear="none">> <br clear="none">> <br clear="none">> <br clear="none">> Hi Stefano,<br clear="none">> <br clear="none">> I am changing the subject line to "SqueakJS for Scratch" because google<br clear="none">> sends me somewhere else for "ScratchJS".<br clear="none">> <br clear="none">> I think that you are asking about running Scratch on Bert Freudenberg's<br clear="none">> SqueakJS, which is a modern Squeak virtual machine implemented entirely<br clear="none">> in JavaScript for HML5, rather than the traditional compiled virtual<br clear="none">> machines that run on operating systems such as Linux and Windows.<br clear="none">> <br clear="none">> If I understand your question correctly, you are asking about how to<br clear="none">> run Scratch on SqueakJS locally on your PC, and you want to understand<br clear="none">> where the Scratch files are stored on your PC.<br clear="none">> <br clear="none">> I do not have good answers to your questions but I am sure that others<br clear="none">> on this list can help. I am also CC'ing the squeak-dev mailing list<br clear="none">> where some of the real Scratch and SqueakJS experts reside.<br clear="none">> <br clear="none">> Here are some useful links for SqueakJS information:<br clear="none">> <br clear="none">> ?? <a rel="nofollow" shape="rect" href="https://squeak.js.org/" target="_blank">https://squeak.js.org/</a><br clear="none">> ?? <a rel="nofollow" shape="rect" href="http://try.squeak.org/" target="_blank">http://try.squeak.org/</a><br clear="none">> ?? <a rel="nofollow" shape="rect" href="https://github.com/bertfreudenberg/SqueakJS" target="_blank">https://github.com/bertfreudenberg/SqueakJS</a><br clear="none">> <br clear="none">> And for Scratch:<br clear="none">> <br clear="none">> ?? <a rel="nofollow" shape="rect" href="https://www.raspberrypi.org/blog/a-new-version-of-scratch-for-raspberry-pi-now-with-added-gpio/" target="_blank">https://www.raspberrypi.org/blog/a-new-version-of-scratch-for-raspberry-pi-now-with-added-gpio/</a><br clear="none">> ?? <a rel="nofollow" shape="rect" href="https://www.raspberrypi.org/blog/test-tims-nuscratch-beta/" target="_blank">https://www.raspberrypi.org/blog/test-tims-nuscratch-beta/</a><br clear="none">> ?? <a rel="nofollow" shape="rect" href="https://github.com/raspberrypi/scratch" target="_blank">https://github.com/raspberrypi/scratch</a><br clear="none">> <br clear="none">> Dave<br clear="none">> <br clear="none">> <br clear="none">> On Sun, Feb 09, 2020 at 01:01:57AM +0000, stefano federici wrote:<br clear="none">> >??<br clear="none">> >?? I managed running ScratchJS locally by saving the page <a rel="nofollow" shape="rect" href="https://squeak.js.org/run/" target="_blank">https://squeak.js.org/run/</a> to my PC and the dragging my Scratch.image into the page.<br clear="none">> ><br clear="none">> > What I don't know is where the SqueakJS file system is stored. When I open the File>Open dialog I can see the SqueakJS and ScratchProjects folders. Where are they stored in my PC?<br clear="none">> ><br clear="none">> > Thanks in advance<br clear="none">> ><br clear="none">> > Stefano Federici<br clear="none">> > -------------------------------------------------<br clear="none">> > Universit?? degli Studi di Cagliari<br clear="none">> > Facolt?? di Studi Umanistici<br clear="none">> > Dipartimento di Pedagogia, Psicologia e Filosofia<br clear="none">> > Via Is Mirrionis 1, 09123 Cagliari, Italia<br clear="none">> > -------------------------------------------------<br clear="none">> > Tel: +39 349 818 1955 Fax: +39 070 675 7113<br clear="none">> ><br clear="none">> >?? ?? ?? Il venerd?? 7 febbraio 2020, 21:39:50 CET, stefano federici <<a rel="nofollow" shape="rect" href="mailto:s_federici@yahoo.com" target="_blank">s_federici@yahoo.com</a>> ha scritto:??<br clear="none">> >??<br clear="none">> >?? Dear All,<br clear="none">> > I have two questions about ScratchJS (that I think is an awesome project):<br clear="none">> > - is it possible to run ScratchJS locally? I tried to run index.html in the SqueakJS-master\scratch folder, but I just got a black square in the upper left corner<br clear="none">> > - can I open local projects in ScratchJS?<br clear="none">> ><br clear="none">> > Thanks in advance for your help<br clear="none">> ><br clear="none">> > Regards<br clear="none">> > Stefano Federici<br clear="none">> > -------------------------------------------------<br clear="none">> > Universit?? degli Studi di Cagliari<br clear="none">> > Facolt?? di Studi Umanistici<br clear="none">> <br clear="none">> > Dipartimento di Pedagogia, Psicologia e Filosofia<br clear="none">> > Via Is Mirrionis 1, 09123 Cagliari, Italia<br clear="none">> > -------------------------------------------------<br clear="none">> > Tel: +39 349 818 1955 Fax: +39 070 675 7113??  <br clear="none"><br clear="none"></blockquote></div></div></div></div></div></div></div></div></div>            </div>                </div></blockquote></div></div>