fixed parsing
Browse files6 unmodified lines789101112131411 unmodified lines262728293031323334353637383940416 unmodified linesimport osimport tempfiledescription = "This Space will profile a dataset file that you drag and drop and push the profile report to your Hugging Face account. πThe value in dataset name field you'll enter will be used in the namespace of the Space that will be pushed to your profile, so you can use it to version the reports too! ππ» Feel free to open a discussion in case you have any feature requests. Dataset name you'll enter will be used for repository name so make sure it doesn't exist and it doesn't contain spaces."title = "Dataset Profiler πͺβ¨"token = gr.Textbox(label = "Your Hugging Face Token")username = gr.Textbox(label = "Your Hugging Face User Name")11 unmodified linesprofile.to_file("./index.html")upload_file(path_or_fileobj ="./index.html", path_in_repo = "index.html", repo_id =f"{username}/{dataset_name}", repo_type = "space", token=token)readme = f"---title: {dataset_name}emoji: β¨colorFrom: greencolorTo: redsdk: staticpinned: falsetags:- dataset-report---"with open("README.md", "w+") as f:f.write(readme)upload_file(path_or_fileobj ="./README.md", path_in_repo = "README.md", repo_id =f"{username}/{dataset_name}", repo_type = "space", token=token)6 unmodified lines7891011121311 unmodified lines252627282930316 unmodified linesimport osimport tempfiledescription = "This Space will profile a dataset file that you drag and drop and push the profile report to your Hugging Face account. π The value in dataset name field you'll enter will be used in the namespace of the Space that will be pushed to your profile, so you can use it to version the reports too! ππ» Feel free to open a discussion in case you have any feature requests. Dataset name you'll enter will be used for repository name so make sure it doesn't exist and it doesn't contain spaces."title = "Dataset Profiler πͺβ¨"token = gr.Textbox(label = "Your Hugging Face Token")username = gr.Textbox(label = "Your Hugging Face User Name")11 unmodified linesprofile.to_file("./index.html")upload_file(path_or_fileobj ="./index.html", path_in_repo = "index.html", repo_id =f"{username}/{dataset_name}", repo_type = "space", token=token)readme = f"---\ntitle: {dataset_name}\nemoji: β¨\ncolorFrom: green\ncolorTo: red\nsdk: static\npinned: false\ntags:\n- dataset-report\n---"with open("README.md", "w+") as f:f.write(readme)upload_file(path_or_fileobj ="./README.md", path_in_repo = "README.md", repo_id =f"{username}/{dataset_name}", repo_type = "space", token=token)
app.py+2-12