Path resolution

Tier 2 · Executable - Silver core structural

The code finds its input and output files on any machine without edits: paths are relative to the package’s root folder, there are no hard-coded absolute paths or machine-specific working directories, and files sit in the folders the code expects.

Rating

TipMet

The code uses relative paths, the files sit in the folders the code expects, and the code successfully finds its input and output files on any machine without requiring any edits.

Supported by: #55, #39, #51, #117 relative paths, #93 ‘code contains relative file paths’, #26/#67 here(), #23 consistent working directory.

WarningPartially met

The code contains hardcoded local paths that cause execution errors, but these paths refer to existing folders/files, so they can be corrected manually or automatically; or the code uses relative paths but some files sit in a different folder than the code expects.

Supported by: Fixable hard-coded paths: #99 ‘minor and quickly resolvable changes such as adjustments to file paths’, #104 path redirection without penalty, #138 fixing paths not a failure, #134, #105, #131, #74, #15.

ImportantNot met

The code contains hardcoded paths that refer to folders/files that do not exist in the replication package. (If the files themselves are missing, this is scored under code/data deposit, not again here.)

Supported by: #25 missing files -> IOError, #112 files not in the execution directory, #125 references to an obsolete subfolder.

NoteNot applicable

Never.

Prerequisites

Check order: 2

Builds on

Prerequisite for

In the corpus

Sources Injunctive Descriptive Tacit Automatable Manual check Automation unclear LLM sources
30 36.7% 0% 63.3% 50% 16.7% 33.3% 4

Text evidence (30 quotes)

#1 An introduction to docker for reproducible research · tacit

“Docker allows a user to link any directory (such as the working directory for a particular script or project) to the running Docker container.” (p. 5)


#11 Sciunits: reusable research objects · tacit

“redirecting all system call paths to paths within the special root path of the sandbox container. By redirecting all file requests into the container, the AV execution method fools the application program into believing that it is executing on the original audit-time machine with original file paths.” (Sec. III)


#15 Coding be eR: assessing and improving the reproducibility of R-based research with containR · injunctive

“using setwd with very specific paths eliminates the possibility of the command executing properly on someone else’s computer because different computers almost always have different directory names” (p.17)


#23 Creating and sharing reproducible research code the workflowr way · injunctive

It automatically sets the working directory in a consistent manner… This prevents one of the most common failures to reproduce in R—not setting the working directory before running the R script, resulting in incorrectly resolved relative file paths.” (p. 5).


#25 Toward computational reproducibility: a doctoral student’s story of passing the baton · tacit

“some files were missing or located in a different folder which caused IOError messages.” (p.689)


#26 Facilitating reproducible project management and manuscript development in team science: the projects R package · tacit

“default settings encourage use of the here package to make file paths generalizable; thus, code can successfully access data and other files within the projects folder, no matter where it is located” (p.7)


#30 Advancing computational reproducibility in the dataverse data repository platform · injunctive

“Dockerfiles could be susceptible to some of the practices that cause irreproducibility, like the use of absolute (fixed) file paths, which is why Dataverse will encourage its users to use best practices when depositing these files” (p.3, Section 3.2)


#39 How to make a pie: reproducible research for empirical economics and econometrics · injunctive

“A first easy-to-implement habit is to use relative paths in programs when calling a function, another program, or a data set” (p. 1149); also invokes “Never type anything that you can obtain from a saved result” (Drukker’s dictum) (p. 1149)


#45 Toward reusable science with readable code and reproducibility · tacit

“One of the best reproducibility practices is to test research code in a clean environment before publishing it or sharing it online. Doing that helps the researcher (or code depositor) identify common errors such as fixed file paths, missing dependencies, and missing files.” (p. 5)


#51 A reproducible data analysis workflow with R Markdown, Git, Make, and Docker · injunctive

“it is recommended that all files reside within one folder… and all paths are relative to that folder because absolute paths are specific to a given computer” (p.19)


#55 Computational reproducibility: a practical framework for data curators · injunctive

“scripts should use relative paths” (p.7)


#67 Tools and recommendations for reproducible teaching · tacit

“Sharing code with file paths that could work on anyone’s computer without making changes to the code is possible” (p. 254); “The here() function… essentially sets the file path to the root of the project directory no matter where the code is being run from” (p. 254)


#74 Reproducibility as a service · injunctive

“the path to load the data is hardcoded to a specific user’s machine, which is all but guaranteed to fail on a different device” (p. 1547)


#79 A review of containerization for interactive and reproducible analysis · tacit

“directory structures across machines may not be identical and, for example, data, code, or other files may not reside where the analysis is expecting. Fixing such problems often entails a significant investment of time and energy” (p.2)


#86 What makes computational communication science (ir)reproducible? · tacit

“the use of hardcoded absolute paths and other assumptions about the availability and structure of certain directories and files” is described as an issue encountered during execution. (p. 13)


#91 CORE-bench: fostering the credibility of published research through a computational reproducibility agent benchmark · tacit

“Use absolute paths instead of environmental variables in execute_shell() command” (p. 8, Table 4)


#93 Unintended code errors and computational reproducibility · injunctive

“Code contains relative file paths” (Appendix A, CODE, p.8)


#95 Computational reproducibility in finance: evidence from 1,000 tests · tacit

Guideline R6 mentions “whether one needs to change the path” only as something to document, not as a “no hardcoded paths” rule (p. 3589)


#99 Introducing reproducible research standards at the world bank · tacit

“Six percent required expected minor and quickly resolvable changes such as adjustments to file paths” (p.5)


#104 Reproduce to validate: a comprehensive study on the reproducibility of economics research · tacit

Rating-1 (best) description explicitly tolerates “negligible changes … e.g., path redirection” without penalty (Table 2, p.969)


#105 Promoting reproducibility and replicability in political science · tacit

“fixing file paths and libraries” — SSRP improvement step (p.6)


#107 Teaching constructive replications in the behavioral and social sciences using quantitative data · tacit

“We observed that students invest considerable effort in changing file paths or directories, installing packages, moving forward or backward in software or package version history, and identifying and debugging errors.” (p. 120)


#112 REPRO-bench: can agentic AI systems assess the reproducibility of social science research? · tacit

“Type 4 failures occur when agents fail to locate files due to incorrect directory placement… BGLM_Data.dta and DuvEq-12-24-50.txt are not in the code execution directory” (p.23624)


#117 Computational reproducibility of R code supplements on OSF · injunctive

“Second, scripts should use relative paths (e.g.,”./data/data.csv”) instead of hardcoded absolute paths, and input data should be included or linked via persistent references.” (p. 4)


#119 “Works on my machine”: a case study of replicability challenges inComputational humanities research · injunctive

“hardware differences and hard-coded paths may further impede replicability” (p.146)


#125 A report on “corruption and Co-optation in autocracy: evidence from Russia” · tacit

“we had to remove references in the clean_data.R script to a subfolder that may be the legacy of an obsolete file directory” (p.5)


#131 Guide for Accelerating Computational Reproducibility in the Social Sciences · tacit

Environment set up: Modify the code to include correct paths to files, specific versions of software, and instructions to install missing packages or libraries.


#134 PaperRepro: automated computational reproducibility assessment for social science papers · injunctive

“Reproduction scripts often hard-code local file paths, which causes execution to fail… The system must rewrite the path to point to the correct local location.” (§2, Scenario 2, p.2)


#136 Artisan: agentic artifact evaluation · tacit

“If provided scripts are non-functional (e.g., an obsolete Dockerfile), s may fix them, so the table can still be reproduced.” (p. 3).


#138 Reproducibility and robustness of economics and political science research · tacit

“Fixing paths, missing packages and software requirements were not considered failures of computational reproducibility. In those instances, we fixed paths and added missing packages and software requirements.” (p.152)