After a massive backlog issue sprint, the foundational {knitr} gains terrific updates to supercharge SQL code chunks. The R Project moves to an open source platform for asynchronous communication, and a key technique for bringing the user's perspective on error messages when you test your R package. Episode Links This week's curator: Batool Almarzouq - @batoolmm.bsky.social (Bluesky) & @batool664 (X/Twitter) The knitr SQL Engine Grows Up Zulip Chat for the R Project Snapshotting error messages Entire issue available at rweekly.org/2026-W40 Supplement Resources A Four-Day {knitr} Issue/PR Backlog Sprint https://yihui.org/en/2026/09/knitr-backlog Zulip R-Project signup https://r-project.zulipchat.com A Practical Introduction To Reproducible R with Nix & {rix} https://b-rodrigues.github.io/r_pharma_26/#/title-slide Supporting the show Use the contact page at https://serve.podhome.fm/custompage/r-weekly-highlights/contact to send us your feedback R-Weekly Highlights on the Podcastindex.org - You can send a boost into the show directly in the Podcast Index. First, top-up with Alby, and then head over to the R-Weekly Highlights podcast entry on the index. A new way to think about value: https://value4value.info Get in touch with us on social media Eric Nantz: @rpodcast@podcastindex.social (Mastodon), @rpodcast.bsky.social (BlueSky) and @theRcast (X/Twitter) Mike Thomas: @mike_thomas@fosstodon.org (Mastodon), @mike-thomas.bsky.social (BlueSky), and @mike_ketchbrook (X/Twitter) Music credits powered by OCRemix Brinstar Bonsai Garden - Super Metroid - Red Tailed Fox - https://ocremix.org/remix/OCR01473 Dark World Jazz - The Legend of Zelda: A Link to the Past - Gux - https://ocremix.org/remix/OCR00156
Audio and video play straight from the show's own hosting. PodSubs stores and serves no media.
Transcript
From the show. Tap a time to play from there.
Hello, friends. We are back of episode 243 of the Our Weekly Highlights podcast. If you are new to the show, this is the weekly ish podcast where we talk about the excellent highlights and other great resources that have been shared in this week's issue of rweekly, which you can find at rweekly.org. My name is Eric Nance, and I'm delighted that you joined us from wherever you are around the world. Well, this is gonna be another one of those unfortunate cases where your, your host here is unfortunately solo.
Mike's unable to make it today, and hopefully, that won't be too big of a set of problems, I hope. I got so many problems. I I don't even know where to begin here. Oh, no. No. No, Moe. I would not say that. Let's be optimistic here. But, yeah, I think the way to be optimistic is we got an awesome issue to talk about here. Some great highlights across the board, which I think you'll really enjoy. And before we get into the meat of this, I just wanna do both a kind of quick plug as well as just what I feel like is
one of my open source achievements that have been unlocked, so to speak. If you've been listening to this show for, you know, a good while now, you know that over time I have become more fascinated by a certain technology that has revolutionized how I achieve reproducibility across multiple levels, and that is the NICS package manager. And now my home infrastructure, the NICS OS operating system, all based on Linux, but it has changed how I configure both my data science projects as well as my actual infrastructure.
Well, a huge reason why I got fascinated by that is the esteemed Bruno Rodriguez who authored the RICS package over a year and a half ago or so. And that was the bridge I needed to see what all these awesome things that were being talked about on the Linux podcast I've listened to such as at Jupiter Broadcasting with Chris Fisher and the rest of the JB crew starting to use Nick's and their infrastructure, but then Bruno took that connection of the world, so to speak, between what I was learning on the tech side
and what I could see as possible on the R side with RICS to give you that bootstrapped environment off of the confines of R itself to get you where you needed to be. Well, I'm happy to say that Bruno, just a couple days ago led an extremely well done workshop at the recent Our Pharma workshop series that happened this week, And I was lucky enough to be a, I guess you could call a glorified TA for this.
And, I've been wanting to do something like that with Bruno for a really, really long time, and it was really great to kind of team up on a lot of the ideas and get my take on things, especially as somebody who's been using this in some highly, production workflows and some of my DevOps adventures. And I was able to share an example Shiny app that was bootstrapped with Nick's based on what it used to be with an RM project. Anyway, the workshop was fantastic. I will put a link to Bruno's slides in the episode show notes.
The recording should be out hopefully within a month ish, two months. I don't know. Yours truly is one of the two editors on it, so it's on my shoulders along with someone else, Jared Wolfwalk, a good friend of mine in the Our Pharma team. We're gonna try and knock those out in due order, but anyway, Bruno, if you are listening, thank you again. That was... Okay. I don't know if you could see it in my virtual, you know, setup there. I was so excited to be a part of it, and I can't wait to play with Nicks even more. Anyway, on to the main event here of our weekly itself
And this issue for week 40 of twenty twenty six has been curated by Batol Almarzakh, and as always, she had tremendous help from our fellow R Weekly team members and contributors like all of you around the world with your poll requests and other wonderful suggestions. And we lead off with what has been literal foundational in terms of innovation and what the R language itself,
many of its ecosystem that has to do with reproducibility, is built on one package driving literally all of it. That package is, of course, Knitter. Knitter has been around for many years now and it is the foundations on which R Markdown were based on and now more recently Quarto, along with many other things in the ecosystem that help you achieve that reproducibility, mingling your code with your pros of your report,
presentation, HTML page, you name it. Is there to help you anytime you need to run R in that pipeline. Knitter itself is because of how important it's been in these ecosystems has had no shortage of, you know, just like any, you know, huge open source project, issues and feature requests and everything along the way. And it can be difficult to triage all that. Well,
the author of Knitter himself, the esteemed Ewacia, has actually taken a lot of time in the recent weeks to look at that backlog on the GitHub issue tracker for Knitter, and within a four day sprint has knocked out a really substantial chunk of them. And we're going to talk about one of the things that has now been resolved in this backlog sprint in our first highlight here, which is having to do with using SQL
in your knitter code chunks. And before I get too deep into it, we will have a link to the comprehensive post that Ewei had written about this whole backlog, addressing of these various issues in in the show notes if you want to look at the genesis of how all this came to be. But right off the bat in that upper post, wanna call out that Ewei, I think, is very practical about where we're at in 2026,
And he did leverage a little help from a LLM AI agent to help with some of this, but it's still... He is driving this. So I think this is going to be the wave of the future for many maintainers in this space. Get help where you need to get help, but in the end, you are authoring those updates. So with that, let's get into the enhancements based through a SQL inside your knitter code chunks. So it's not like SQL support has never been there before. Knitter has had support for SQL
in its code chunks for quite some time, where it basically stands upon the shoulders of DBI to help execute the various SQL statements that are in the chunk, and with DBI going to the relevant database engine, wherever that's SQLite, Postgres, you name it, it's probably there. But they util... They had a bit of a utilitarian approach to how the code chunks were were, were used and the options inside of it.
Well, there's a set of new options that I think are are very highly requested and are now available in your code chunk with SQL code. One of those is called SQL dot interlaced, and the reason this is important is that oftentimes these code chunks may have more than one actual SQL statement where the statement is, you know, delimited at the end by a semicolon. A lot of programming languages will do that.
But then in the previous versions of knitter, when you would run that chunk and then you would see it echoing out the output of the chunk, both kind of what was run as well as the associated output, if you had a multi line, you know, SQL code chunk, it would actually truncate to only show that first line and maybe some additional characters, but you wouldn't see that full trace of that code chunk being executed. Well, with the SQL dot interlaced option, which you can set as true or false,
if it's set as true, then in essence it dynamically splits that code chunk into separate chunks on the fly, each with that one statement, so that in the end when you run that and you actually see the output in your compiled report or HTML or whatever have you, you'll see all of those statements being reported on if you flag, you know, verbatim for your output being true. You'll see that in action instead of being truncated one by one. So that's a great quality of life enhancement right there.
Another one is that if you want more control over how the result of that query is processed, you've got a new option available to you called sql.result.fun. You're gonna have fun with this, because you can send a function as the argument to this where you can perform some post processing kind of operation, maybe you want to do some additional dplyr like transformations, and you can,
basically say and do that, and execute that I should say, while it's still the query itself is in what's called a lazy or non collected state, so that you don't have to actually collect the result first before you run that processing function. It will do all this in memory. I admit, I do want to play with this because I didn't think something like this was possible, but that is really powerful. So the blog post that has an example of this is where you can
say, run a query or select certain things from the, flights table, for example, and you can easily do that. So that's another interesting option. Lastly, if you put in a code, SQL code that's not really doing any actual collection or querying. It's really meant for changing things. Maybe you're transforming a variable. Maybe you're getting rid of a variable.
Well, in the past, everything that was being executed by the code chunk in SQL was being sent via DBI, the DB execute function in DBI to actually run that. Sometimes that doesn't play as nicely for these, like, you know, operations or statements that will actually change the fundamentals of the data in that database. So with this approach, there is now respect for the for the code chunk
to be dynamic and being able to run DBI DB get query instead of this so that you don't have to necessarily run the execute one even in situations where you didn't necessarily want to use db execute for those operations. And then to conclude the post, he always says that now if you have via your specific engine you're targeting some additional arguments that you want to pass on to that chunk
that are outside of the typical invocation, you now have a code chunk option called SQL dot args, and within that, you feed in a list with key value pairs of these additional arguments, such as in the example here, an argument of immediate equal true, and in that way it's going to run this more quickly, I believe. I'm not familiar with that, what that actual option does, but now if you need more customization,
you can absolutely do that in terms of these additional arguments. And going back to what Ewei said in the overall post introducing all these updates, I think there is a very important detail that I do want to bring awareness of. And this isn't so much about him, although he's using himself as an example of this, but this happens to a lot of individual maintainers out there. So, one thing that has happened
in his time recently is that he is no longer getting funding from Posit themselves on maintaining the R Markdown ecosystem. Unfortunately, that time has run out. And Ewei, again, thanks to his well deserved visibility in the world of R and the world of data science in general, he does have a handful of sponsors to help out with various things.
It's not like Yiwei is, you know, asking and begging for additional sponsors. He is content with lowered expectations on this, in his words. However, there may be other maintainers of some very important open source software that don't have the type of community connections that Eway has with respect to the R community. And and he I, feels bad for them because they may not be able to
get as much reach out there for getting funding for their individual projects. And there could be a lot of things standing on the shoulders of these open source maintainers, and yet they are maybe doing this as a hobby, maybe they don't even have a current job and they're trying to find ways to get funding. Be on the lookout for those kind of maintainers. And I think it's important,
Mike and I have said this many times on the show, this is not free labor, folks. There's a cost to them. It may not be cost in terms of money or like dollars unless they're like hosting things. It's a cost of time. It's a cost of having to learn certain things that maybe are outside their day job. I think this is still a very real issue and I hope that, you know, with Vihue's, you
know, calling attention to this, I think it's important to remind people from time to time that yes, we do have AI help in a lot of newer creations of things per se, but there's still a human at the back of all this, that's orchestrating all this, and I think it's very important we don't lose sight of that. So anyway, I really give you credit for being transparent and being humble like you always are, but I hope that with your amazing work in the knitter space,
in your recent adventures, with your Light Down inspired set of packages, which are very minimal dependencies to do R Markdown like things without a lot of the added dependencies of R Markdown. It's a really intriguing time to be involved in this space, and I hope the community, like me, very much appreciates your efforts on this.
And up next in our highlights today, let's harp on the community aspect for this next one because we're talking about how the community in particular around R itself can be, you know, heavily involved in both the development and the future direction of the project and keeping the conversation going, so to speak. And this blog post is talking about a a big change to some of the infrastructure for giving that more real time communication
aspect for developers and users around R itself. And this post comes to us on the official R blog, it's always great to say that, and it is co authored by Ella Kaye as well as Heather Turner, both research software engineers that have been heavily involved in the R project for years and years now. They are both software research engineers at the University of Birmingham over in The UK, And up to this point,
the R project, in particular the contributors around R, have been interacting with each other with a Slack, community since November 2020, and that has served them well. It is based on the free tier of Slack, so you get some nice features. But as I've heard others, very, close to me in the world of podcasting say, a lot of times when we rely on proprietary
products and services, it's inevitable that we'll either hit the limit or things will be taken away from us. And unfortunately with Slack, while I have great respect for the project, and I think I'm not too far from the backyard where Slack was actually developed, but that's another story, there are some limitations to projects like R or any other community for that matter, such as posts older than 90 are not being visible anymore.
So if you're collaborating on a long term project and you want to think back to what, say, if Michael and I were on a Slack and I wanted to think back to what he said last year, man, that's kind of trouble. Heck, I'll be fully transparent. Our week will use a Slack and there are messages that even I forgot I said, and I would like a reminder of it, but it went past that ninety day window. That definitely has me thinking. And so what the R group has done, the R contributors have done now, is they are in the process of migrating to a new framework
called Zulip. Zulip before this post, I was not aware of it, but it is actually a fully open source product which can have some hosting, which I'll get to in a little bit, but it is designed for asynchronous conversations with a framework that will look very familiar to any user of Slack or even more recently Discord. I see a lot of similarities on this.
But with it being open source, you have the ability to deploy this on your infrastructure or use their hosting, but you get everything in one place and it has a lot of additional things that shore up the shortcomings of Slack in respect to what the R contributors are looking for. And first, before I get into that, there are a lot of open source projects or communities using Zulip already,
mainly Python themselves, Julia and Rust, Bioconductor, and Num Focus. Well, if that isn't a who's who of either languages or highly influential groups in data science, I don't know what is. So, what Zoohoo has to offer, in addition to what Slack can provide, are very important features such as the Idea Topics, which are a great way to organize both the synchronous and asynchronous
resources or conversations. You can move messages around. Maybe it was put in the wrong chat and you want to move it to a different chat. You can do that easily. And, hey, we were just talking about, you know, Knitter recently in the in the first highlight. Has full support for markdown and KaTeX rendering, so you can have your equations in there too off the bat. And unlike in platforms like Slack, where you have to get an add in to do polls, it just comes in with polls right off the bat. That's just a handful of the things that Heather and Ella M. Say have been very helpful to them making the switch.
Now, this is not fully done yet. This is a migration that's currently ongoing. They have already invited members from the R Foundation, the contribution working group, RSMF project, and the R Project Sprint from earlier this year to set up an account on Zulip and give their feedback. And as of September 22, which is about a week or so ago, at the time of this recording, now a sign up page is open to all contributors and anybody else that wants to support R.
So, and this is also an important date because now the R contributor Slack will not be open to new signups, so they're closing the door on it. And then later in the month, October 27, that is the planned date as of now to archive all the R contributors Slack channels so that then there's no other communication on there. So the blog post that we have linked to in the show notes does have a sign up page, and Zulip themselves is generously providing
sponsorship of R and giving them a standard cloud plan that they have free of charge, which means that now they get to keep that full chat history unlike what they did on Slack, and being a sponsored project, they're going to be able to make that happen. I'm sure if you want to spin it up on your own infrastructure, you can obviously keep the chat history there too, but then you or a trustee admin would be on the hook for hosting it. So there's always a teeter totter, a benefit trade off, or wherever you host something yourself or you
pay a company to do it, but hey, it's the same company that's building this product, so I think that makes a ton of sense. So they've got some acknowledgments at the end here. This work to get to this point has been supported by the Research Software Maintenance Fund, And also, they're grateful to Josh Triplett from the Rust community and Maria Doyle from Bioconductor giving them a lot of advice on the transition to this platform.
I admit, this one kind of hit home for me because on top of R Weekly itself being based in Slack, a very prominent community that I often plug every time chance I get to it, the data science learning community is also based in Slack. So I'm going to be taking a big look at Zulip and see if it can meet the needs maybe for our weekly or even just other things I have in my mind. But it's great to see the R project moving to an open source, you know, product
to help with a very important open source project. And rounding out our highlights today. It's always great when things work as expected in the world of R, in the world of software development in general. That's a happy paradise that, unfortunately, is not the real world.
Things go wrong, things can go horribly wrong, but it's how you communicate this and how you get to the bottom of it that can really make or break what that experience looks like. You don't want to find yourself in a situation where something kind of broke and then your users think after reading the message something like this. What a load of garbage. You don't want that. Yes, it's not great news sometimes when the errors happen, but the way we communicate it and what we can do with this information is a foundational
pillar of a optimal user experience. And our last highlight today, we're talking about when these errors happen, what can we do to actually archive this and dive into the details behind it in a way that's robust from both the development side and the user side. So this blog post is titled Snapshotting Air Messages and has been offered by Etienne Bakker. I don't know if I said that right. My pronunciation is never great.
He is a research software engineer, yet another research software engineer, this time at the University College London over in The UK. And yes, he opens with a blog post, saying that, you know, as a developer of a package or of a software, we have an idea of where, how it works, what are the main features, what are the main ways of using it, But, hey, even with sometimes the best docs, your users may try some and it doesn't quite work as expected.
And again, we want to know, as want, as a developer, to make that experience of what just happened, understanding why the error occurred and how to fix it as seamless as possible for our users out there. So there's a great example that he acknowledges he's been starting to use Rust since a few years ago, and that when you have an error in Rust, it can give you, in this case of example of a mismatched types error,
a lot of good information where you can see where it went wrong and the different ways it's represented. So you can see the blog post or the full details, but there are certain things in that output that are shown, such as what kind of error is it? Not just, oh, something broke, but in this case the error says mismatched types. It also shows in the code that you wrote for this, Rust script what lines, row number, column number of the line had the actual error.
You can also see what was supposed to return and what you actually got, and that shows where the mismatch is between an option and a found like a Boolean instead. So, and sometimes you'll get the actual way to fix the error, like the actual code snippet that would fix that. So, right off the bat, that's a good use case of why it's not just good enough to say,
Whoops, error occurred in function XYZ. Why did it occur? And hopefully, how to fix it. Well, as you're building your function, you can leverage the way of inspecting what these error messages look like, and we're going to be leveraging Test That for a lot of this, and the setup of this is that he's running a simple function that does some internal computation, and then with that, it's another function that takes a number times its log of that divided by the exponent of that number,
and then being able to simply, you know, output that out. So test that if you're not familiar that it has a lot of expectations that you put in your test script so that you check if some is literally working as expected. And and one of those is the expect error where, let's say, you feed in, instead of a number to that function, you feed in something odd, you know, and that could be a column name. And then you see, oh yeah, there is an error if you put that expectations,
but the user sees something completely different. When they run your function, they see an error saying math. Factor, log, not meaningful for factors. What the heck does that mean? Well, it's treating the the string as a factor and it called, you know, the wrong the wrong order of things. So back to the developer side, okay, that's a problem, that's not very informative.
What can we do to help here? And then one thing you can do is in your expect error call to test that, you can do what's called a regex, regular expression search, for the type of syntax you want to see in that error message. And you would see if you have like a regex of saying cannot pass a column of type factor into this function, oh, now you can see in your test stat run,
oh, you didn't get that right message. So that means you go back to your function and you figure out how do you actually write a more informative message. We'll get to that in a little bit. Now, you may want to capture what that actual output was, the error, or even if things work well, that's where snapshotting comes in. And that's where instead of doing the expect error, you can do an expect snapshot. And you run this function, you can say error equal true,
and then this will actually snapshot what the user actually sees when they run the function. Now, they will not, you can't just run that code verbatim. This is all run as part of TestThat, such as in certain wrappers, such as DevTools test or TestThat test file. Those are where you can actually save these and you can see what this looks like. And you may have a lot in your test suite and you may be wondering,
well if I save all these snapshots of error output, are we going to take a performance hit? Not necessarily. It's about a few seconds on his machine to run these for a set of 500 snapshots. Checking them takes about seven seconds, and then checking the expect errors took about three seconds, so not a huge amount. Not a huge amount of difference. A few seconds, I think having a snapshot feature,
would be helpful here. Now you may be wondering, well, I got a huge test suite that doesn't use snapshots. What do I do to actually migrate over? Well, there is a package to help you do just that, and it is called FLIR, f l I r. Hopefully, I said that right. And he is the author of FLIR, and that is helping you rewrite code patterns in your code, and this is a perfectly suitable task to rewrite
some of these expect errors and replace it with expect snapshot error equal true and not have to really tweak anything else. So you can run FLIR add new rule to this. You first have to set it up first, and then once you set up the rule, which is expect snapshot error that it comes with, and then you can write, like a YAML type syntax to show what to expect or what to do to fix,
run FLIR on your directory of code, in this case the tests, and then you can remove that extra folder that you had as part of this process, and then you'll have everything ready to go with snapshots. So that is pretty neat. So the snapshot functionality, maybe you don't use it now, but to be able to capture that and use it in downstream processing, I think is really important as a developer to really see firsthand what the user sees when they run that function.
Again, thinking of the user experience. When you write your package, not just something broke, but a clear logical reason why it broke and hopefully with a snippet to help fix it. We all can dream, right? But you can start somewhere, and snapshotting, I think is a great technique to do that. What else is great folks is reading the rest of our weekly. So it's another fantastic issue that Batoola's put together for us here. And as I skim through the different sections, we always break it down by insights,
tutorials, package updates. There's a lot of great content, and in fact, the rest of those improvements that eWay has done in that big sprint, they're here in this issue as well, all the way from better tables with the cable function and much more. I've seen a lot of great graphs or pictures here of graphs with some good visual tutorials here, and yeah, a whole lot more. And as always, R Weekly itself,
we are a community project. We have no sponsors. The show definitely does not have sponsors, although maybe that'll change down the road depending on how things go. But nonetheless, we depend on you and the community. It's again a key message. I've tried to relay at the end of each episode, as well as my recent PosiConf talk, but your support is more important than ever. Keeping the project going with that new resource that you've built or you've authored or you sound someone else and you want to share that with the rest of the world,
we are a poll request away. At our issue template draft, I should say, we have a poll request template where if you get your GitHub account set up, send us a poll request and you will be off to the races to put in that link, all marked down all the time. And also, we'd love for you to join our curator team. We are a humble bunch of eight passionate curators of the R ecosystem, passionate about R, passionate about data science,
and you would fit right in if you share that same excitement. And just every time I see an issue, I see like five or so things that I want to either dive deep into when I get a spare moment or say, Hey, I need to use this for a new project. It's all there folks. At rweekly.org you can find complete details on the process to join our team. And also we'd love to hear from you on the social media outlets out there. Unfortunately, again, Mike couldn't be here today.
You'll see his handles linked in the show notes. Yes. You can find me. I am on blue sky. I am at rpodcast@bsky.social. I am also on Mastodon at rpodcast@podcastindex.social, and I'm on LinkedIn. Search my name and you will find me there. And again, just a quick plug once again, the Our Pharma Conference. If you're in life sciences, the virtual event is happening in a few weeks and we just completed a huge set of workshops.
Amazing content. I can't wait for you all to see the recordings of that. Nothing beats a live experience, I'll be honest, but seeing the recordings, it's some really amazing stuff out there. Really, it may be the best workshop series we have in the art community, full stop, no matter life sciences or not. That's my hot take anyway. Okay, with that, let's close-up shop here on episode two forty three. Thank you so much for joining me today. I know it was a solo effort. Hopefully, it wasn't too crazy, but I feel like we had a fun show. Oh, yeah. Okay. Thanks, Earthworm Jim. Okay. Let's close-up shop here. Thank you so much for joining us and we will see you have another episode of our weekly highlights
Our takes on the increasing removal of friction in good and not-so-good ways thanks to AI, a visual tour of hot air balloon accident data, and a case study of novel image recognition with the rplatipus package. Episode...
The flow of both data and analytical jobs just got smoother with mizu, opening the door for multiple agent harnesses in Positron, and an optimal statistical model tailored to complex experimental designs with a friendly...
What happens when that online data set isn't so easy to download anymore? We learn of two packages to ease the pain of obtaining these files and then some. Plus a visit to the visualization corner with a handy way to...
The celebration of rOpenSci's 15-year anniversary continues with the community sharing their perspectives, and a fun Shiny app that could be quite useful during celebrations on a weekend or the holidays. If you ever...
We learn about the variety of ways you can contribute back to the core of R, a roundup of the excellent choices available for package and environment reproducibility, and an amazing collection of Shiny applications and...