Code Monkey home page Code Monkey logo

Comments (6)

shoyer avatar shoyer commented on June 24, 2024

I think we could potentially fix this behavior on the xarray side, but ISO-8601 is pretty clear that all years should have four digits. So I still think this would be a win. Certainly 0001-01-01 is much clearer than 01-01-01.

from cftime.

spencerkclark avatar spencerkclark commented on June 24, 2024

Just checking in on this issue after a while -- so is the consensus that we should address this issue within netcdftime? If so, I can try to put together a PR.

from cftime.

jswhit avatar jswhit commented on June 24, 2024

I think the fundamental problem is that no one has stepped to maintain a separate netcdftime project. Seems like there is still some work to do before I can disconnect it from netcdf4-python.

from cftime.

dopplershift avatar dopplershift commented on June 24, 2024

I'm happy to help step up on the infrastructure side (well, in a couple weeks probably), but I'm a little uncomfortable with stepping up fully since I don't have much technical knowledge in the space netcdftime is operating. So I'm happy to cut releases and stuff, but I'm not in possession of answers when it comes to solutions to problems.

from cftime.

spencerkclark avatar spencerkclark commented on June 24, 2024

It occurs to me now that a possibly less disruptive solution than altering the current string representation of netcdftime datetimes would be to simply add an isoformat method, which we could use in xarray, analogous to datetime.datetime.isoformat or pd.Timestamp.isoformat. Would that be preferred over modifying __str__?

from cftime.

shoyer avatar shoyer commented on June 24, 2024

I don't think changing the repr/string format would be disruptive. I expect most users would agree that 0001-01-01 is clearer than 1-01-01.

That said, I have no objections to adding an isoformat() method, too.

from cftime.

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.