Skip to content

[0.66] react-native-fs does not properly link even though it seems to have windows #8836

@dannyvv

Description

@dannyvv

Problem Description

I'm trying to add react-native-fs to my app and it fails with:

yarn run v1.22.10
$ react-native run-windows
 × Auto-linking...
Error: Autolinking: Found a Windows solution for react-native-fs but no React Native for Windows native module projects. (60ms)
 × Autolinking failed. Found a Windows solution for react-native-fs but no React Native for Windows native module projects
Re-run the command with --logging for more information
Your session id was 2f42fdba9056fa42b126c6d51c8dca85
error Command failed with exit code 305.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Steps To Reproduce

  1. Follow instructions to create new rnw app
  2. yarn add react-native-fs
  3. yarn windows

Expected Results

my app to build and use the fs library

CLI version

6.1.0

Environment

info Fetching system and libraries information...
System:
    OS: Windows 10 10.0.22000
    CPU: (16) x64 Intel(R) Core(TM) i9-9900 CPU @ 3.10GHz
    Memory: 51.26 GB / 63.84 GB
  Binaries:
    Node: 12.19.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.10 - ~\AppData\Roaming\npm\yarn.CMD
    npm: 6.14.8 - C:\Program Files\nodejs\npm.CMD
    Watchman: Not Found
  SDKs:
    Android SDK: Not Found
    Windows SDK:
      AllowDevelopmentWithoutDevLicense: Enabled
      AllowAllTrustedApps: Enabled
      Versions: 10.0.18362.0, 10.0.19041.0
  IDEs:
    Android Studio: Version  4.1.0.0 AI-201.8743.12.41.7042882
    Visual Studio: 16.11.31702.278 (Visual Studio Enterprise 2019)
  Languages:
    Java: 16.0.2
  npmPackages:
    @react-native-community/cli: Not Found
    react: Not Found
    react-native: Not Found
    react-native-windows: Not Found
  npmGlobalPackages:
    *react-native*: Not Found

Target Platform Version

No response

Target Device(s)

No response

Visual Studio Version

Visual Studio 2019

Build Configuration

Debug

Snack, code example, screenshot, or link to a repository

 i Verbose: ON
⠋ Auto-linking...
Parsing project...
Found Windows app project, config:
{
  folder: 'd:\\src\\hack2\\packages\\TrackMyWork',
  sourceDir: 'windows',
  solutionFile: 'trackmywork.sln',
  project: {
    projectFile: 'trackmywork\\trackmywork.vcxproj',
    projectName: 'trackmywork',
    projectLang: 'cpp',
    projectGuid: '{42106539-d294-47ef-b3d0-48f6a27e4a20}'
  },
  experimentalFeatures: {
    UseHermes: 'false',
    UseWinUI3: 'false',
    UseExperimentalNuget: 'false'
  }
}
Parsing dependencies...
react-native-fs has Windows implementation, config:
{
  folder: 'd:\\src\\hack2\\node_modules\\react-native-fs',
  projects: [],
  solutionFile: 'RNFS.sln',
  nugetPackages: [],
  sourceDir: 'windows'
}
 × Auto-linking...
Error: Autolinking: Found a Windows solution for react-native-fs but no React Native for Windows native module projects. (69ms)
 × Autolinking failed. Found a Windows solution for react-native-fs but no React Native for Windows native module projects

Metadata

Metadata

Assignees

No one assigned

    Labels

    Area: AutolinkingExternalIssue tracked in this repo but change will need to happen in another repobug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions