GithubHelp home page GithubHelp logo

Comments (42)

James-76 avatar James-76 commented on August 17, 2024 23

Thanks @roe-dl

People can also work around this by updating header.html.tmpl to download the v10.3.3 of the code, rather than latest.

        <script type='text/javascript' src='//code.highcharts.com/stock/10.3.3/highstock.js'></script>
        <script type='text/javascript' src='//code.highcharts.com/10.3.3/highcharts-more.js'></script>
        <script type='text/javascript' src='//code.highcharts.com/10.3.3/modules/exporting.js'></script>
        <script type='text/javascript' src='//code.highcharts.com/10.3.3/modules/solid-gauge.js'></script>

James

from weewx-belchertown.

ArendPWS avatar ArendPWS commented on August 17, 2024 10

This fix worked for me:

Edit belchertown.js.tmpl

Find this line at the end of the file:

var chart = new Highcharts.chart(options);

Change chart in Highcharts.chart to uppercase like this:

var chart = new Highcharts.Chart(options);

Save and wait for WeeWX (cheetah) to generate a new set of files

Charts have a bit of a different look (especially fontsizes) in this new version of Highcharts, so perhaps that will require some tweaking.

from weewx-belchertown.

roe-dl avatar roe-dl commented on August 17, 2024 4

Why did I download the files of the old version and stored them to my web server? (Besides not knowing the paths @James-76 offered)

  • It was some kind of a shock to me to see the web site without graphs today in the morning. What if I had no time to care about that situation? So the conclusion was: Never rely on other people's servers.
  • I live in Europe. There is the GDPR around. That suggests to store the files on the own server, too. That's why I refered to discussion #810

from weewx-belchertown.

seanford avatar seanford commented on August 17, 2024 2

This fix worked for me:

Edit belchertown.js.tmpl

Find this line at the end of the file:

var chart = new Highcharts.chart(options);

Change chart in Highcharts.chart to uppercase like this:

var chart = new Highcharts.Chart(options);

Save and wait for WeeWX (cheetah) to generate a new set of files

Charts have a bit of a different look (especially fontsizes) in this new version of Highcharts, so perhaps that will require some tweaking.

This fix worked for me:

Edit belchertown.js.tmpl

Find this line at the end of the file:

var chart = new Highcharts.chart(options);

Change chart in Highcharts.chart to uppercase like this:

var chart = new Highcharts.Chart(options);

Save and wait for WeeWX (cheetah) to generate a new set of files

Charts have a bit of a different look (especially fontsizes) in this new version of Highcharts, so perhaps that will require some tweaking.

For those preferring to stick with Highchart v11 and use @ArendPWS fix, tryy this to get the font size to be closer to what it was:

In belchertown.js.tmpl, look for the following:

Highcharts.setOptions({ global: { //useUTC: false timezoneOffset: $highcharts_timezoneoffset }, lang: { months: moment.months(), shortMonths: moment.monthsShort(), weekdays: moment.weekdays(), shortWeekdays: moment.weekdaysShort(), decimalPoint: "$highcharts_decimal", thousandsSep: "$highcharts_thousands" } });

and change it to:

Highcharts.setOptions({ global: { //useUTC: false timezoneOffset: $highcharts_timezoneoffset }, lang: { months: moment.months(), shortMonths: moment.monthsShort(), weekdays: moment.weekdays(), shortWeekdays: moment.weekdaysShort(), decimalPoint: "$highcharts_decimal", thousandsSep: "$highcharts_thousands" }, chart: { style: { fontSize: '0.9em' } } });

That gets it pretty close.

from weewx-belchertown.

James-76 avatar James-76 commented on August 17, 2024 1

@kacnje, that is entirely up to you and if Highcharts decides it is a bug or a feature change with v11.0.0

Historically, Highcharts seems to work on a one or two month release cycle so don't expect a new code release in the next 48 hours unless something has been classed as a catastrophic issue.

from weewx-belchertown.

roe-dl avatar roe-dl commented on August 17, 2024 1

Personally I'd favor having Belchertown include all the pieces locally so you never need to rely on any upstream servers after the skin is installed.

I updated the ZIP file with all the external resources at https://www.woellsdorf-wetter.de/lib.zip It includes the Highcharts files now.

from weewx-belchertown.

bdruth avatar bdruth commented on August 17, 2024 1

Pushed a PR with one option that fixes this. Not as good as fixing-forward to v11, but it's a simple thing that gets everything working until someone has the bandwidth to look at v11 (and the font changes) in earnest.

from weewx-belchertown.

James-76 avatar James-76 commented on August 17, 2024 1

Whilst there are sensible arguments, it is also more effort currently for @poblabs, who has less time to spend on this currently as previously noted.

At the moment every Highcharts release since 2015 is online (both on the CDN and GitHub) so the risk of it disappearing is slim.

If somebody wants to package it up and upload it as a pull request then Pat may consider it, but at least the one implemented does work.

James

from weewx-belchertown.

poblabs avatar poblabs commented on August 17, 2024

Does it make sense to specify the specific 10.3.3 version?

from weewx-belchertown.

ddperso avatar ddperso commented on August 17, 2024

No of course, it's a workaround.
Pat, your graphs on your site are OK, do you use Highcharts 11.0?

from weewx-belchertown.

fvirgola80 avatar fvirgola80 commented on August 17, 2024

I used @James-76's solution
the solution of
@ArendPWS that's great but the Highcharts update makes the chart titles bold and the toltip lowercase under the diffs

solution @James-76

James-76

solution @ArendPWS

ArendPWS

from weewx-belchertown.

101jallen avatar 101jallen commented on August 17, 2024

I used @James-76's solution since that makes sense to use the older version of Highcharts as a workaround for now. Seems to be functioning as it used to.

I will add you all are awesome for opening this thread, I would never have found a solution to this. Thank you!

from weewx-belchertown.

kacnje avatar kacnje commented on August 17, 2024

I'm in the same boat. I noticed the problem this morning and searched for what was going on.
Can we just wait for the author's solution (and be without graphs in the meantime)? I'm asking because I don't have an easy access to my server (well it takes some time).

from weewx-belchertown.

James-76 avatar James-76 commented on August 17, 2024

Pat, your graphs on your site are OK, do you use Highcharts 11.0?

@ddperso, Pat has implemented my suggested quick fix/work around on his website - view-source:https://belchertownweather.com//

from weewx-belchertown.

poblabs avatar poblabs commented on August 17, 2024

Pat, your graphs on your site are OK, do you use Highcharts 11.0?

@ddperso, Pat has implemented my suggested quick fix/work around on his website - view-source:https://belchertownweather.com//

You're good. Yes I reverted back because I don't have the time currently to mess around with the new font size issues.

from weewx-belchertown.

pannetron avatar pannetron commented on August 17, 2024

Using @James-76's workaround, all good now on my end.

from weewx-belchertown.

vinceskahan avatar vinceskahan commented on August 17, 2024

@James-76's workaround definitely works, but I see the font differences. I went with a slightly modified variant of @roe-dl's initial workaround since personally I like having all the pieces locally and not need to rely on any upstream servers whenever possible.

Personally I'd favor having Belchertown include all the pieces locally so you never need to rely on any upstream servers after the skin is installed. I know there are plusses/minuses of that approach of course for security vs. supportability so it's a tough decision.

from weewx-belchertown.

gldickens3 avatar gldickens3 commented on August 17, 2024

@James-76's workaround worked for me!

from weewx-belchertown.

msman0 avatar msman0 commented on August 17, 2024

@roe-dl Thank you very much, it works also at my site.

from weewx-belchertown.

mrneutron42 avatar mrneutron42 commented on August 17, 2024

Also used @James-76 workaround. Thanks!

from weewx-belchertown.

schematt avatar schematt commented on August 17, 2024

@James-76 Thanks!

from weewx-belchertown.

ddperso avatar ddperso commented on August 17, 2024

from weewx-belchertown.

Geni0815 avatar Geni0815 commented on August 17, 2024

@roe-dl Vielen Dank, habe es auch lieber lokal .👍

from weewx-belchertown.

roe-dl avatar roe-dl commented on August 17, 2024

@ddperso Yes, you have to replace those URL, too.

        <script type='text/javascript' src="$relative_url/lib/js/jquery.min.js"></script>
        <script type='text/javascript' src="$relative_url/lib/js/moment-with-locales.min.js"></script>
        <script type='text/javascript' src="$relative_url/lib/js/moment-timezone-with-data.min.js"></script>

jquery-ui.min.js is not required at all.

I just updated the instructions.

from weewx-belchertown.

freetom-git avatar freetom-git commented on August 17, 2024

I used @James-76's solution since that makes sense to use the older version of Highcharts as a workaround for now. Seems to be functioning as it used to.

I will add you all are awesome for opening this thread, I would never have found a solution to this. Thank you!

Totally agree with @101jallen

Thanks @James-76 for the solution it's working as it used to

from weewx-belchertown.

RonV42 avatar RonV42 commented on August 17, 2024

Thanks @James-76 for the fix. I did a reboot of my weewx and first thing I thought was when I migrated to proxmox for WeeWx I messed up something in the file transfer.

from weewx-belchertown.

tomdotorg avatar tomdotorg commented on August 17, 2024

also implemented @James-76 patch (thank you!!). I think the Highcharts version should be a config item or pinned to a specific Highcharts version. Ideally, it would be stored and packaged as part of the Belchertown distro, but I'd settle for not being subject to arbitrary breaking changes.

from weewx-belchertown.

ddperso avatar ddperso commented on August 17, 2024

from weewx-belchertown.

roe-dl avatar roe-dl commented on August 17, 2024

It should work that way. Where is your lib directory situated? Could you show your skin.conf?

from weewx-belchertown.

ddperso avatar ddperso commented on August 17, 2024

from weewx-belchertown.

roe-dl avatar roe-dl commented on August 17, 2024

Is that one line or two lines at copy_once?

from weewx-belchertown.

ddperso avatar ddperso commented on August 17, 2024

from weewx-belchertown.

ddperso avatar ddperso commented on August 17, 2024

from weewx-belchertown.

roe-dl avatar roe-dl commented on August 17, 2024

Another thought. copy_once means it is copied only once after the start of WeeWX. If you want it copied without re-starting WeeWX you have to add it to the copy_always line.

from weewx-belchertown.

roe-dl avatar roe-dl commented on August 17, 2024

Ah, ok. If you have a copy_once line in weewx.conf the copy_once line in skin.conf is not used.

from weewx-belchertown.

ddperso avatar ddperso commented on August 17, 2024

from weewx-belchertown.

earlthesquirrel avatar earlthesquirrel commented on August 17, 2024

Please let us know when there is a new release with this "updated" to whatever you settle on @poblabs. I ended up chasing my tail a bit on this when the graphs disappeared... I ended up upgrading weewx and Belchertown skin to the latest versions (so not a total waste). Then got caught on the empty forecast file (btw, turning off forecast and then turning it on after one wee_reports seems to fix that as well -- the empty file fix doesn't seem to work anymore... at least not for me...)

from weewx-belchertown.

poblabs avatar poblabs commented on August 17, 2024

@bdruth thanks for the PR. I have release 1.3.1 to pin highcharts to version 10

https://github.com/poblabs/weewx-belchertown/releases/tag/weewx-belchertown-1.3.1

from weewx-belchertown.

ddperso avatar ddperso commented on August 17, 2024

from weewx-belchertown.

mrneutron42 avatar mrneutron42 commented on August 17, 2024

@James-76
Why does only one of those lines have /stock/ in them?
Should they all reference /stock/ ?

        <script type='text/javascript' src='//code.highcharts.com/stock/10.3.3/highstock.js'></script>
        <script type='text/javascript' src='//code.highcharts.com/10.3.3/highcharts-more.js'></script>
        <script type='text/javascript' src='//code.highcharts.com/10.3.3/modules/exporting.js'></script>
        <script type='text/javascript' src='//code.highcharts.com/10.3.3/modules/solid-gauge.js'></script>

from weewx-belchertown.

poblabs avatar poblabs commented on August 17, 2024

No, stock is reference to HighStock which is an "add-on" for HighCharts

from weewx-belchertown.

mrneutron42 avatar mrneutron42 commented on August 17, 2024

I note that the same code is available at:
https://code.highcharts.com/10.3.3/highcharts-more.js
https://code.highcharts.com/10.3.3/modules/exporting.js
https://code.highcharts.com/10.3.3//modules/solid-gauge.js
as well as
https://code.highcharts.com/stock/10.3.3/highcharts-more.js
https://code.highcharts.com/stock/10.3.3/modules/exporting.js
https://code.highcharts.com/stock/10.3.3//modules/solid-gauge.js

from weewx-belchertown.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.