Comments (14)
Hi @ClaudioZandonella,
thanks for your fast response! I tried it today on my private computer (both are windows machines) with the latest RStudie and R Version and there it worked perfectly fine. So it seems that it is somehow related to that. Sorry that I did not try this before I asked here!
from trackdown.
Hi, really excited about this package but just wanted to add that I'm having this problem too. This is the header I have in my .rmd
document. I'm using Mac OS (Big Sur). Adding "[[document-header]] at the top of the Google Doc doesn't seem to help either.
title: "Untitled"
author: "Wei Yang Tham"
date: "8/24/2021"
output: html_document
from trackdown.
Hi @weiyangtham!
Thank you very much for your help!
The problem was caused by character vectors considered as factors in dataframe. Shame on me that I did not consider the stringsAsFactors
issue for R versions before 4.0.0π
Now I fixed the problem by specifying stringsAsFactors = FALSE
Now changes are available on GitHub with the new version of trackdown 1.0.1
@weiyangtham and @dfranquesa could you please try the new version of the package and confirm if the problem is now solved?
You can install the GitHub version of the package with
# install.packages("remotes")
remotes::install_github("claudiozandonella/trackdown",
build_vignettes = TRUE)
Thank you so much for your help debugging this issueβ€οΈ
from trackdown.
Works for me now! Thanks for the fix!
from trackdown.
You are right! uauuu! it works now, thanks!
from trackdown.
Hi @mamuerie,
We are really happy that you find trackdown
useful for your work.
Unfortunately, the bug you have reported is really strange.
Do you mind sharing the header and the first few lines of your .Rmd
document? This will allows us to evaluate what caused the problem.
And also, which operative system do you use? Different character encoding between OS sometimes triggers some problems.
For a quick solution to the problem:
- When downloading the file from google drive with the
download_file()
function, iftrackdown
fails to retrieve the[[document-header]]
tag, the code is automatically restored at the first line of the document. Was the code not restored at the first line in your case? The following message is printed in the console:
Warning message:
Failed retrieving [[document-header]] placeholder, code added at first line
- Alternatively (a little bit raw π
), you could simply add "[[document-header]]" in the document on google drive, on a new line right after the instructions. This should be enough for
trackdown
to correctly retrieve the tag when downloading.
from trackdown.
Hi @weiyangtham,
We are really happy to know that you are excited about the package! And thank you for reporting this issue...unfortunately, I can not reproduce the issue and it is really strange to understand why this happens.
Do you find the same issue on different documents as well?
To find out where is the problem, could you please follow these instructions?
I have created a small report that will execute all the steps done by trackdown
to find and substitute the header code. This will help us to understand at which point the issue emerges. Could you please compile the report and share the results?
I attach a zip folder with the Debugging-issue-17.Rmd
file. Could you:
- download and unzip the file
- move it in the same folder as your Rmd document that presents the issue
- open
Debugging-issue-17.Rmd
- at line 24 you have to indicate the name of your Rmd document (with extension)
- compile
Debugging-issue-17.Rmd
If everything goes smoothly in the output you can find several checks to evaluate where the problem is. If you upload the output I can try to fix the issue.
Note that I have truncated the output of several chunks in order to print only relevant information and not your entire document, feel free to adjust if required.
from trackdown.
Done! Let me know if you need anything else
document-to-upload.txt
from trackdown.
Hi @weiyangtham,
Could you please upload the html output you obtain when compiling Debugging-issue-17.Rmd
, so I will be able to understand at which step the error occurs.
Note that to upload a html file in GitHub you have to zip the file
Thanks for your help!
from trackdown.
Hi @dfranquesa,
The problem you referred to in issue #20 is caused by the same problem discussed here. For unknown reasons the [[document-header]]
tag is missing and 1
is placed instead. This is really strange also because when downloading, instead of restoring the header code, again another 1
is placed.
Unfortunately, I can not reproduce this error on my computer. Could you please help us to understand the reason behind this error?
To find out where is the problem, please follow these instructions. I have created a short report that will execute all the steps done by trackdown to find and substitute the header code. This will help us to understand at which point the issue emerges. Could you please compile the report and share the resulting output (an HTML file)?
I attach a zip folder with the Debugging-issue-17.Rmd
file. Could you:
- download and unzip the file
- move it in the same folder as your Rmd document that presents the issue
- open
Debugging-issue-17.Rmd
- at line 23 you have to indicate the name of your Rmd document (with extension)
- compile Debugging-issue-17.Rmd
If everything goes smoothly in the output you will find several checks to evaluate where the problem is. If you upload the output (the HTML file) I can try to fix the issue.
Note that I have truncated the output of several chunks in order to print only relevant information and not your entire document, feel free to adjust if required.
Thanks for your help!
from trackdown.
Hi @ClaudioZandonella , here's the html file!
Debugging-issue-17.html.zip
from trackdown.
@ClaudioZandonella I can not say the same as @weiyangtham
Still not works for me.
I've update to Version: 1.0.1, 2021-08-28 15:04:24
Please find attached a zip file with all the info I think you are asking for debugging.
I'm using Ubuntu, I've add also the session_info.html.
Thanks!
David
Debugging-issue-17-DFG.zip
from trackdown.
Hi @dfranquesa,
thanks for your help!
Looking at your session_info.html
I see
## V trackdown * 1.0.0 2021-08-28 [1] Github (claudiozandonella/trackdown@9445154)
with
## V ββ Loaded and on-disk version mismatch.
Probably you installed the new version of the package but tho old one was still loaded. Maybe restarting the rstudio session will solve the issue. You need the version 1.0.1
to be loaded.
To be sure that the new version is loaded you can run the following commands
name_your_file <- "bug_trackdown_header.Rmd" # path to your file
original_text <- readLines(name_your_file)
info_patterns <- trackdown:::get_extension_patterns("rmd")
head_info <- trackdown:::extract_header(original_text, info_patterns)
str(head_info)
the result should be
'data.frame': 1 obs. of 4 variables:
$ starts : int 1
$ ends : int 6
$ header_text: chr "---\ntitle: \"Analysis Script\"\nauthor: \"David Franquesa, Mireia Roura, Leandro Navarro\"\ndate: \"`r format("| __truncated__
$ name_tag : chr "[[document-header]]"
If header_text
and name_tag
are type chr
the new version is working. Instead, if they are still type factor
, the old version is working.
Again, thanks for your help!
Claudio
from trackdown.
Thank you all for your help!
Anyone who finds the same issue, please, install the package version v.1.0.1 from GitHub with
# install.packages("remotes")
remotes::install_github("claudiozandonella/trackdown",
build_vignettes = TRUE)
from trackdown.
Related Issues (20)
- Clarify scopes needed for the app in the vignette HOT 2
- Add alternative text to vignette images? HOT 1
- Feature request: Open the document that was just created/updated HOT 1
- Feature request: Upsert operation? HOT 2
- Feature request: Use version "tagging" on Google Docs HOT 1
- add R-universe installation instructions to README?
- Add/improve diagram to README
- use Markdown roxygen2 HOT 6
- use lifecycle to mark experimental arguments? HOT 1
- OAuth App Config. new msg from google HOT 4
- Small typo: donwloaded instead of downloaded HOT 1
- Warning: The `app` argument of `drive_auth_configure()` is deprecated as of googledrive 2.1.0. HOT 2
- Authentication Issues HOT 9
- Automate setup of access HOT 1
- Test roundtrip HOT 2
- Installation from Github Fails HOT 10
- Tracker V1.5.0 with GoogleDrive 2.0.0 refuses .qmd files HOT 4
- rename the default branch to "main"? HOT 2
- [BUG] trackdown wrongly highlights text in between inline chunks that have a `$` in them
- feature request
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from trackdown.