Skip to content

Attempting to create a new R Package project in a directory containing a special character results in an 'Error Creating Project' failure. #6784

Open

Description

@R-Hannibal

System details

RStudio Edition : Desktop
RStudio Version : Version 1.3.952-1
OS Version      : Windows 10
R Version       : 3.6.3

Prerequisite

  • Create a new folder in your RStudio working directory which contains a special character in it's name (Example: C:\Users\Mario\Documents\©).

Steps to reproduce the problem

  1. Open RStudio and select File > New Project... > New Directory > R Package.
  2. Fill in the 'Package name:' field and then select the 'Browse..' button next to 'Create project as subdirectory of:'.
  3. Browse to the newly created folder containing a special character name and select Open > Create Project.

Describe the problem in detail

The project is not created and an error message stating 'Failed to create package .Rproj file' is presented to the user. Screenshot below:

NewProjectFail

Describe the behavior you expected

The new project is successfully created in the selected directory.

Notes

Note 1: Not sure if this is a side-effect of this issue or a bug of it's own, but after the issue occurs, a new folder is created in the working directory. Example:

  • I created a folder titled '®' and chose that as my target for the new package project. After the error occurred, there is a new folder titled '®' in the same directory as the '®' folder I originally created.

Note 2: This issue could relate to other issues we've seen involving special characters in the working directory: 2194, 6701, 3166, 4469, and 5560.

Activity

  1. added this to the v1.4 milestone on Apr 30, 2020
  2. kevinushey commented on Apr 30, 2020

    @kevinushey
    Collaborator

    Likely caused because of a missing Encoding() <- "UTF-8" call in this function:

    .rs.addJsonRpcHandler("package_skeleton", function(packageName,

  3. modified the milestones: v1.4, Later on Jul 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions