Welcome to the fiftieth issue of Racket News.
Hello everyone! Hard to believe we have now hit 50 issues. Thanks to everyone who have been supporting of this project, and sending messages saying how much they enjoy it. It makes my day.
We have a new amazing Racket release - v8.1, learn about it in this issue and start using it. On to the next 50 - I hope you stay with us.
Grab a cappuccino and enjoy!
Table of Contents
- What’s New?
- Racket Around the Web
- New Releases
- Call to Racket!
- DrRacket Quickscript of the day
- Project in the Spotlight
- Featured Racket Paper
- Upcoming Meetups
- Racket v8.1 has been released. Among the highlights you’ll find several improvements in Racket CS: cross compilation, android support and a handful of optimizations.
- Take a look at a video by Luis Quintanilla from Microsoft on Building Web Services in Racket. It’s from February but somehow I missed it when it came out.
Racket around the web
Do you blog about Racket? Let me know!
- Racket v8.1 by John Clements.
If you know of library releases or maybe your own libraries and you want them to be featured, please let me know.
rbulkresizer(pkg/src) is a graphical bulk picture resize tool, by Maciej Barć.
drracket-red(pkg/src) is a VSCode Red Theme for DrRacket, by
ionic(pkg/src) is a library providing another way to structure computations, by Siddhartha Kasivajhula.
raco-cross(pkg/src) is a raco command to drive cross compilation, by Matthew Flatt.
syndicate-classic(pkg/src) is the classical version (previous version of
#lang syndicate) of syndicate - a language for interactive programs, by Tony Garnock-Jones and Sam Caldwell.
rktfetch(pkg/src) is an info fetch tool (like neofetch) but written in Racket, by Maciej Barć and Ashley.
graphite(pkg/src) is a ggplot2-inspired data visualization library, by Hazel Levine.
Call to Racket!
Want to contribute to Racket? Don’t know where to start? Each RN issue I choose an easy issue to fix to get you started contributing to Racket. Come, give it a go.
Nobody has yet tackled last issue’s
racket/pict bug #29, so I will reinforce the Call to Racket again with the same issue. If you are interested in fixing this but need some guidance, feel free to comment on the issue page. Will you be our next Champion?
DrRacket Quickscript of the day
Quickscript (featured project of issue 38) provides an easy way to extend DrRacket with small Racket scripts to automate some actions in the editor, while avoiding the need to restart DrRacket. In this new section, contributed by Stephen De Gabrielle, we will be highlighting some of the most interesting scripts out there. Do you have a favourite script? Share it with us!
This weeks quickscript is a classic from the
In addition to keybindings, quickscripts can also add new custom menu’s to DrRacket. This script is a demo of that functionality.
#lang racket/base (require racket/gui/base racket/class quickscript) (script-help-string "(Example) Shows how to dynamically add a menu to DrRacket.") (define-script add-menu #:label "Add menu" #:menu-path ("E&xamples") (λ (str #:frame fr) (define menu-bar (send fr get-menu-bar)) (define menu (new menu% [parent menu-bar] [label "M&y Menu"])) (new menu-item% [parent menu] [label "&Remove me"] [callback (λ _ (send menu delete))]) (define count 0) (new menu-item% [parent menu] [label "&Count me"] [callback (λ _ (set! count (add1 count)) (message-box "Count" (string-append "Count: " (number->string count))) )]) #f))
Installation: you can paste this into a new script - but check out the
quickscript-extra collection for more goodies.
In DrRacket, in
File|Package manager|Source, enter
Or, on the command line, type:
raco pkg install quickscript-extra.
If DrRacket is already running, click on
Scripts|Manage scripts|Compile scripts and reload menu.
Project in the Spotlight
This week’s project in the spotlight is Bookcover by Joel Dueck.
From the website:
Creating a cover for a printed book can be one of the most tedious parts of self-publishing. Printing services have requirements for the cover’s dimensions. You need to calculate the width of the book’s spine based on page count and paper type, add space for bleed, and so forth. If you change anything about the inside of your book, you need to run your calculations all over again. As an alternative to designing your book’s cover with a program like InDesign or Photoshop, you can instead implement it as a Racket program that dynamically calculates everything for you and generates the cover in PDF form each time it is run.
Featured Racket Paper
This issue’s featured paper is Chaperones and Impersonators: Run-time Support for Reasonable Interposition, by T. Stephen Strickland, Sam Tobin-Hochstadt, Robert Bruce Findler, and Matthew Flatt.
Chaperones and impersonators provide run-time support for interposing on primitive operations such as function calls, array access and update, and structure field access and update. Unlike most interposition support, chaperones and impersonators are restricted so that they constrain the behavior of the interposing code to reasonable interposition, which in practice preserves the abstraction mechanisms and reasoning that programmers and compiler analyses rely on. Chaperones and impersonators are particularly useful for implementing contracts, and our implementation in Racket allows us to improve both the expressiveness and the performance of Racket’s contract system. Specifically, contracts on mutable data can be enforced without changing the API to that data; contracts on large data structures can be checked lazily on only the accessed parts of the structure; contracts on objects and classes can be implemented with lower overhead; and contract wrappers can preserve object equality where appropriate. With this extension, gradual typing systems, such as Typed Racket, that rely on contracts for interoperation with untyped code can now pass mutable values safely between typed and untyped modules.
Do you know of any upcoming meetups I can advertise? Let me know.
Racket Users Video Meetup (Saturday, May 29) https://www.timeanddate.com/worldclock/converter.html?iso=20210529T200000&p1=136&p2=204&p3=179&p4=224
London, United Kingdom Sat, 29 May 2021 at 21:00 BST Prague, Czechia Sat, 29 May 2021 at 22:00 CEST New York, USA Sat, 29 May 2021 at 16:00 EDT San Francisco, USA Sat, 29 May 2021 at 13:00 PDT Corresponding UTC Sat, 29 May 2021 at 20:00
- Again Racket Users Video Meetup (Saturday, June 5), same times and location as above.
Many thanks to my sponsors:
- Jesse Alama. Jesse is a Racketeer, mathematician, and writer based in Main, Germany. He is the organizer of RacketFest, and writer of various Racket books and libraries.
- John Clements. John is a researcher and professor at Cal Poly, a member of the core Racket, and Racket release manager.
- Sam Tobin-Hochstadt. Sam is a researcher and associate professor at Indiana University, a member of the core Racket team, and the brains behind Typed Racket and Pycket.
- Stephen De Gabrielle. Stephen is a product manager at epro. He is a long time Racket community contributor, moderating
r/racket, editing the Racket wiki, running many community competitions and events, among many other things.
- and my private sponsors, who shall remain anonymous.
If you wish to sponsor me and my work on Racket and Racket News - feel free to visit my GitHub Sponsors webpage. All sponsorship levels are welcome.
- Stephen De Gabrielle
for their contributions to this issue.
The next issue is planned for publication during week 23, specifically June, 7. Contributions welcome - deadline for next issue: Sunday, June 6, 2021.
I have also tried to survey the most relevant things that happened in Racket lang recently. If you have done something awesome, wrote a blog post or seen something that I missed - my apologies. Let me know so I can rectify it in the next issue.