Code Monkey home page Code Monkey logo

wescheme's People

Contributors

abigsmall avatar abosamoor avatar awstlaur avatar bhickey avatar blelem avatar danking avatar dankocoj4 avatar dyoo avatar gauravmm avatar jakemwood avatar jpolitz avatar kotharitrisha avatar magicjarvis avatar melloc avatar schanzer avatar sorawee avatar wzimrin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

wescheme's Issues

big-bang allows repeated clauses

October 16, 2023
WeScheme.org

Expected: following code gives an error because of the repeated to-draw clause.

Actual: no error, runs as if the only clause were the second one.

(define c (circle 10 "solid" "blue"))
(define b (square 10 "solid" "orange"))

(define (draw-1 img) 
  (overlay img (empty-scene 200 100)))
(define (draw-2 img) 
  (overlay (above img b) 
           (empty-scene 200 100)))
(define (th x)
  (beside x c))
(big-bang c
          (to-draw draw-1)
          (to-draw draw-2)
          (on-tick th 0.5))

Picker not working when 3rd party cookies disabled

Jul-28-2021 19-26-40

I'm getting the behavior in this GIF when I try to insert images. Interestingly, this is the same behavior I get on CPO if I turn off the scopes for drive.photos and drive.photos.readonly (this is what prompted me to try!)

On my first clickthrough I got a permissions screen that looked like it was requesting the drive.file permission (the one for just files opened or created by the app).

Any thoughts?

Missing files (support.js and a few pngs)

Howdy!
I've just installed weScheme locally on my machine. I cloned wescheme2012 master branch, ran 'build-console-and-editor.rkt' and got the local server up and running. However, when serving the page http://localhost:8081/openEditor, the files support-min.js, undo.jpg and redo.png are 404. The installation did properly minimize the js files, but apparently war/js/mzscheme-vm/support.js was not cloned in the first place. I suspected some quirks in my installation, but after quickly looking in the repo, I couldn't find the three files in question. Where can I find those files?

After flip, an image is not "trimmed" to its drawn area

Both flip-vertical and flip-horizontal screw up the bounding box handling. Apparently after a flip everything inside the bounding box is considered part of the image, not just the drawn part. Unlike DrRacket and non-flipped WeScheme images.

Sample code (first line for DrRacket only):

(require 2htdp/image)
(define good (triangle 100 "solid" "orange"))
(define bad (flip-horizontal (triangle 100 "solid" "blue")))
(beside good bad)

(beside/align "bottom"
              (frame (rotate 60 good))
              (frame (rotate 60 bad)))

Results from DrRacket 8.9 CS, as expected:
image

Results from WeScheme.org today:
image

The whitespace around the blue triangle ("bad") is expanded, presumably including the space outside of the triangle in the figure.

Equality in put-image depends on order of overlay

These two images are not reported equal, but should be. I think this is because scene equality checks the order of adding things to the scene, and doesn't have a fallback for false.

For example:

  (put-image (circle 50 'solid 'red)
             100 100
             (put-image (rectangle 50 60 'solid 'brown)
                        300 300
                        (rectangle 500 500 'solid 'blue))))

(define si2
  (put-image (rectangle 50 60 'solid 'brown)
                        300 300
             (put-image 
                        (circle 50 'solid 'red)
             100 100
                        (rectangle 500 500 'solid 'blue))))

(define si3
  (put-image (circle 50 'solid 'red)
             100 100
             (put-image (rectangle 50 60 'solid 'brown)
                        300 300
                        (rectangle 500 500 'solid 'blue))))

(equal? si si2)
(equal? si si3)
(equal? si2 si3)

reports


false
true
false

Can't run blocks-test branch locally

I followed the README and believe I have all the required dependencies that were listed, but I can't get the blocks-test branch to run.

From the root directory of the repo, I ran ./build-console-and-editor.rkt, which seemed to work fine. However, when I run ant runserver, I get the following error:

Buildfile: /home/pcardune/programming/bootstrapworld/wescheme/build.xml

copyjars:

BUILD FAILED
/home/pcardune/programming/bootstrapworld/wescheme/build.xml:28: /home/pcardune/programming/bootstrapworld/wescheme/lib/google-oauth-java-client/libs does not exist.

Total time: 0 seconds

I tried running git clean -f -x to remove any build files and start from a clean slate and got:

Buildfile: /home/pcardune/programming/bootstrapworld/wescheme/build.xml

copyjars:
     [copy] Copying 11 files to /home/pcardune/programming/bootstrapworld/wescheme/war/WEB-INF/lib

BUILD FAILED
/home/pcardune/programming/bootstrapworld/wescheme/build.xml:28: /home/pcardune/programming/bootstrapworld/wescheme/lib/google-oauth-java-client/libs does not exist.

Total time: 0 seconds

Which is essentially the same thing. Where am I supposed to get google-oauth-java-client from?

@schanzer this is the issue I was telling you about on the phone.

Remove Python Dependency

It looks like more recent versions of the Closure Compiler are available as a node.js module, which could be called without ever using Python at all! This feels worlds easier than trying to get the old Python2 codebase working on Python3, and it’s always a good thing to get rid of dependencies…especially when they involve loading an entire programming language! Python is used in two places in the build script:
1) To calculate dependencies for the compiler.
2) To calculate dependencies for the closure library.

Both of these should be replaced by the newer and better-maintained JS version of the same script. If you can pull this off, we can remove Python entirely! Don’t forget to edit the README file to reflect this.

Allow WeScheme to handle hyphenated color names

From bootstrapworld/curriculum#1626:

Just noticing that Pyret can take in either "dark-green" or "darkgreen" and WeScheme only accepts "darkgreen". This means that we as authors (me!) sometimes write WeScheme examples that wouldn't actually work. If it would be easy to make WeScheme also accept hyphenated versions of those strings it would make authoring less error prone.

image-width and image-height are buggy

Following two tests fail:

(check-expect (image-width (rectangle 0 10 "solid" "purple"))
              0)

(check-expect (image-height (rectangle 10 0 "solid" "purple"))
              0)

The result is:

check-expect: actual value 1 differs from 0, the expected value.
check-expect: actual value 1 differs from 0, the expected value.

Port to Modern Java

Modify the java (found in src/) so that it works on at least Java 11. If you want to really knock this out of the park, Java 17 would be even better. Given that you’re got plenty of Java experience, my hope is that this one isn’t going to be much trouble either.

EXAMPLE Warnings in big-bang popup

EXAMPLE failures are not sufficiently visible. Need CSS love to make them pop in the REPL, but also some more serious work to have it visible in running bing-bang

Syntax highlighter confused by comments

Using #; results in incorrect highlighting, which causes students to believe something is wrong when it is not.

Examples from using wescheme.org.

  1. (Confusing.) Example with #; - my first line is purpleish (comment color). Actually both lines should be hilighted as commennts.
    image

  2. Block comments have the same highlighting as code. (This might not be fine.)

Use getImagedata for image equality

Back in 2013, I used toDataURL for comparing image tiles. But toDataURL has no guarantees of being lossless, causing the equality function to occasionally produce false negatives.

getImageData is now available, and supported in all browsers. We should switch to that instead, and check to see if tiling is even needed anymore.

Underage users blocked from Google login

Error message from Google indicates that users in a "Google Workspace for Education" (e.g., school org) under 18 are blocked, as well as children under 13.

2021-10-04_17-34

As of 2021-10-04, changed from reported to work on 2021-10-03.

Scandinavian letter support in interaction window

From Tiina:
Missing Scandinavian letter support in interaction window is still an issue (ä, ö). This comes up in every time I'm giving a Racket course for Finnish teachers... (last time last Tuesday…).

Support https access to wescheme.org

Requests that use HTTPS (https://www.wescheme.org) should work.

Technical reason: it aids composability in the long run. Other pages that may embed wescheme.org will not be able to do so at the moment if they themselves are HTTPS, as browsers such as Chrome prohibit a "downgrade" from HTTPS to HTTP. For example, let's say that https://hashcollision.org has a IFRAME that tries to embed wescheme.org. It can't at the moment because wescheme.org doesn't currently support HTTPS.

Clean up login Java and JS code

  • Do we really need to be using window.location for every button?
  • Can we remove the Session constructors that we aren't using?
  • Can we do all the session-setting via AJAX, and minimize page redirects?

Can not run locally

I follow README and try to run wescheme locally but can not succeed.

I check dependencies, seems that all are ok.
I installed it by respect to defined 3 steps in Readme with succeed

Then
$ ant runserver
finished with succeed and google.appengine related exceptions.

But when i request to localhost there is no response browser can not connect to server.

Regex-related Warnings on Build

When running ./build-console-and-editor.rkt on the npm branch, the console prints warnings related to unnecessary escape characters in regex expressions.

For example:

WARNING in .../wescheme/war-src/js/js-runtime/js-numbers.js at 2416, 24: Unnecessary escape: '\.' is equivalent to just '.'
WARNING in.../wescheme/war-src/js/js-runtime/js-numbers.js at 2416, 31: Unnecessary escape: '\.' is equivalent to just '.'
WARNING in .../wescheme/war-src/js/js-runtime/js-numbers.js at 2416, 38: Unnecessary escape: '\.' is equivalent to just '.'
WARNING in .../wescheme/war-src/js/js-runtime/js-numbers.js at 2416, 45: Unnecessary escape: '\.' is equivalent to just '.'

Given my limited experience w/ Regexes, I am having trouble discerning whether or not the escape characters are in fact necessary. To the best of my knowledge, the . character must be escaped but the warning suggests otherwise.

Warnings are produced by the following files:

  • .../wescheme/war-src/js/js-runtime/js-numbers.js
  • .../wescheme/war-src/js/openEditor/tokenizer.js EDIT: Addressed in 3de5b6b (needs testing)
  • ...wescheme/war-src/js/compiler/lex.js EDIT: Addressed in 57087d4

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.