# Code works when run as a file, but not from REPL

**URL:** <https://discourse.julialang.org/t/code-works-when-run-as-a-file-but-not-from-repl/22208>\
**Category:** General Usage\
**Created:** [March 22, 2019, 4:30pm UTC](https://discourse.julialang.org/t/code-works-when-run-as-a-file-but-not-from-repl/22208 "2019-03-22T16:30:13Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![kristoffer.carlsson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kristoffer.carlsson/32/22_2.png) [@kristoffer.carlsson](https://discourse.julialang.org/u/kristoffer.carlsson)\
**Post date:** [March 22, 2019, 5:31pm UTC](https://discourse.julialang.org/t/code-works-when-run-as-a-file-but-not-from-repl/22208/4 "2019-03-22T17:31:23Z")

</div>

Sounds a bit like [Initialization of R fails on julia 1.1](https://discourse.julialang.org/t/initialization-of-r-fails-on-julia-1-1/19735/1)

---

_[View the full topic](https://discourse.julialang.org/t/code-works-when-run-as-a-file-but-not-from-repl/22208)._
