amzn / oss-dashboard

A dashboard for viewing many GitHub organizations at once.
Apache License 2.0
159 stars 40 forks source link

Move Dir.mkdir for www-direcotry #103

Closed kaakaa closed 7 years ago

kaakaa commented 7 years ago

I encountered the following error.

generate-dashboard
 json-data
  kaakaa /oss-dashboard/generate-dashboard/generate-json-data.rb:116:in `mkdir': No such file or directory @ dir_s_mkdir - html/json-data (Errno::ENOENT)
    from /oss-dashboard/generate-dashboard/generate-json-data.rb:116:in `block in generate_json_data'
    from /oss-dashboard/generate-dashboard/generate-json-data.rb:111:in `each'
    from /oss-dashboard/generate-dashboard/generate-json-data.rb:111:in `generate_json_data'
    from refresh-dashboard.rb:237:in `block in <main>'
    from refresh-dashboard.rb:193:in `each'
    from refresh-dashboard.rb:193:in `<main>'

In about 10 days ago generate_json_data method added in this commit ( Overhaul to the dashboards to a) make charts more pluggable via separ… · amzn/oss-dashboard@8486704)

generate_json_data method needs directory of www_directory. But Dir.mkdir(www_directory) is called after calling generate_json_data method in refresh-dashboard.rb.

So Dir.mkdir(www_directory) should be called before calling generate_json_data.

hyandell commented 7 years ago

Thanks Yusuke; again the bug report and patch is much appreciated :) My apologies for the bug :(