chainladder-python icon indicating copy to clipboard operation
chainladder-python copied to clipboard

Issue on page /tutorials/data-tutorial.html

Open henrydingliu opened this issue 2 years ago • 14 comments

error at the bottom of the page

plt.plot( (model_cl.ultimate_["Paid"]).to_frame().index.astype("string"), (model_cl.ultimate_["Paid"] / model_cl.ultimate_["reportedCount"]).to_frame(), ) plt.xticks(np.arange(0, 10 * 12, 12), np.arange(2008, 2018, 1))

henrydingliu avatar May 24 '22 07:05 henrydingliu

Thanks for flagging this! I'll correct this one.

kennethshsu avatar May 24 '22 11:05 kennethshsu

@jbogaardt do you know why the read the docs page is still showing the error even though the source file is good? How do you rebuild the page? I thought it's automatic?

kennethshsu avatar May 26 '22 14:05 kennethshsu

It is automatic, these are the most recent successful builds: image If you're looking at the stable docs, they are only updated upon a release of chainladder-python. Howeverm the "latest" and "master" versions of the docs should have your updates.

jbogaardt avatar May 26 '22 14:05 jbogaardt

Actually, that notebook doesnt run correctly with master code. It may be from my botched commit (https://github.com/casact/chainladder-python/commit/9d37003a61c5772f5a3609ac4af117c898c114f8).

jbogaardt avatar May 26 '22 14:05 jbogaardt

Are you looking at the commit?

Also, in .__version__ should we get a b or something like 0.8.13b so we know we are in beta? We will then get rid of the b when we make a release?

kennethshsu avatar May 26 '22 20:05 kennethshsu

i just removed those lines, so if it was causing the fails in the tutorial, then they should rebuild correctly.

On __version__, I guess we can add a 'b'. Version 0.8.13 is not available through Pypi, I've always looked at any differences between master and pypi as beta changes for any package I use, but there is nothing wrong with being explicit.

jbogaardt avatar May 26 '22 20:05 jbogaardt

still showing error using the following setup: pandas: 1.4.2 numpy: 1.21.5 chainladder: 0.8.13

The committed notebook shows chainladder 0.8.12. This may have regressed earlier or it could be pandas==1.4.2.

jbogaardt avatar May 26 '22 21:05 jbogaardt

@jbogaardt I think I know what the problem is now...

The master branch on github should always match the released version. Can we make another release of 0.8.13? readthedocs will re-execute the code in the docs folder, and that means currently the tutorials (and all example exhibits) will be rebuilt using the 0.8.12 version of chainladder.

We have at least a few ways to address this:

  1. Release 0.8.13 and see if that fixes it.
  2. Don't rebuild the jupyter notebook in readthedocs. We can change the execute_notebooks parameter inside _config.yml from force to 'off' (with quotes?! documentation). I think this will just published the notebook using the cached values.
  3. Have a branch that tracks the released package, currently it is on 0.8.12, and modify the build command here by checking out the specified branch.

I don't know which one is better, what do you think?

kennethshsu avatar Jun 25 '22 00:06 kennethshsu

Hmm looking at #3 in a bit more detail, I think it actually checkouts the master code, which should be 0.8.13...

kennethshsu avatar Jun 25 '22 00:06 kennethshsu

Readthedocs builds several versions of the docs and they can be accessed by the end user here: image

Stable = latest stable release (version 0.8.12) Master = latest commit on master (version 0.8.13) Latest = latest commit on some other specified branch (which we default to master)

jbogaardt avatar Jun 25 '22 01:06 jbogaardt

Do you see 0.8.12 on stable? I see 0.8.10 instead.

kennethshsu avatar Jun 25 '22 04:06 kennethshsu

You're right. I see what you mean. The stable docs have been failing since 0.8.10 for the same reasons. The commits they rely on are not working, so I'll try to get 0.8.13 released today for a more up-to-date stable docs.

jbogaardt avatar Jun 26 '22 12:06 jbogaardt

I think everything is on 0.8.13 now, but the code is still not compiling correctly. Do you think it makes sense to try changing the _config.yml file?

kennethshsu avatar Jun 29 '22 05:06 kennethshsu

The builds are all passing. I believe any remaining issues are dependency conflicts. I get the same errors on the data-tutorial in my cl_docs environment locally that I shows on the website.

jbogaardt avatar Jun 29 '22 11:06 jbogaardt