aws-samples / amazon-comprehend-semi-structured-documents-annotation-tools

Other
24 stars 15 forks source link

Missing "." in relative folder path, S3 files not loading #1

Closed ujnm closed 3 years ago

ujnm commented 3 years ago

The code is not opening the files from s3 as the path is" open(f'./{local_ui_template_directory_name}/index.html', encoding='utf-8')" and should have two dots, so "open(f'../{local_ui_template_directory_name}/index.html', encoding='utf-8')" in 351st line in comprehend-ssie-annotation-tool-cli.py

dnlen commented 3 years ago

Hi ujnm, there are two parts to resolve this.

  1. Please leave the path as was originally with a single dot: f'./{local_ui_template_directory_name}/index.html'.
  2. When the script is run in the terminal, please make sure you are in the root directory of the package (one directory up from the bin/ directory) Relative pathing is used in the script to locate and upload local package data, so it's important the script is run from the package root directory.
ujnm commented 3 years ago

This solution worked, thank you!