agilescientific / striplog

Lithology and stratigraphic logs for wells or outcrop.
https://code.agilescientific.com/striplog
Apache License 2.0
204 stars 69 forks source link

Hatch type deprecation warning #140

Open MosGeo opened 3 years ago

MosGeo commented 3 years ago

Problem:

When attempting to use custom hatch "p" with the newest version of Matplotlib, you get the following deprecation warning. So, it seems that, soon, the latest version of Matplotlib will not be usable with striplog. MatplotlibDeprecationWarning: hatch must consist of a string of "*+-./OX\ox|" or None, but found the following invalid values "p". Passing invalid values is deprecated since 3.4 and will become an error two minor releases later.

Expectation:

No warning.

Resolution:

This is my first hour using striplog so I can't make recommendations on how to fix this yet.

mtb-za commented 3 years ago

Been taking a look at this, and it looks like more recent versions of matplotlib do not allow for custom hatch patterns. For now at least, the workaround here in striplog does work, but as you point out, this will break at some point. I have raised an issue with the matplotlib folks, so we will see if that gains any traction to have a more supported way to do this.

This is something that is not a striplog problem per se though, until we are able to define custom hatches in a matplotlib approved way.

MosGeo commented 3 years ago

I agree, this is not a strip log issue perse but I thought to raise it up here as it will be a breaking issue in the future. Thanks for raising the issue in Matplotlib repository. It looks like they already replied.