Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
gmaze committed Dec 13, 2023
2 parents fe8d49a + 7b5054d commit a2b4f58
Show file tree
Hide file tree
Showing 6 changed files with 109 additions and 11 deletions.
5 changes: 4 additions & 1 deletion argopy/data_fetchers/argovis_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,10 @@ def to_xarray(self, errors: str = "ignore"):
ds.attrs["DATA_ID"] = "ARGO-BGC"
ds.attrs["DOI"] = "http://doi.org/10.17882/42182"
ds.attrs["Fetched_from"] = self.server
ds.attrs["Fetched_by"] = getpass.getuser()
try:
ds.attrs["Fetched_by"] = getpass.getuser()
except:
ds.attrs["Fetched_by"] = 'anonymous'
ds.attrs["Fetched_date"] = pd.to_datetime("now", utc=True).strftime("%Y/%m/%d")
ds.attrs["Fetched_constraints"] = self.cname()
ds.attrs["Fetched_uri"] = self.uri
Expand Down
5 changes: 4 additions & 1 deletion argopy/data_fetchers/erddap_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,10 @@ def post_process(self, this_ds, add_dm: bool = True, URI: list = None): # noqa:
this_ds.attrs["DATA_ID"] = "ARGO-BGC"
this_ds.attrs["DOI"] = "http://doi.org/10.17882/42182"
this_ds.attrs["Fetched_from"] = self.erddap.server
this_ds.attrs["Fetched_by"] = getpass.getuser()
try:
this_ds.attrs["Fetched_by"] = getpass.getuser()
except:
this_ds.attrs["Fetched_by"] = 'anonymous'
this_ds.attrs["Fetched_date"] = pd.to_datetime("now", utc=True).strftime(
"%Y/%m/%d"
)
Expand Down
10 changes: 8 additions & 2 deletions argopy/data_fetchers/gdacftp_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,10 @@ def _preprocess_multiprof(self, ds):
ds.attrs["DATA_ID"] = "ARGO-BGC"
ds.attrs["DOI"] = "http://doi.org/10.17882/42182"
ds.attrs["Fetched_from"] = self.server
ds.attrs["Fetched_by"] = getpass.getuser()
try:
ds.attrs["Fetched_by"] = getpass.getuser()
except:
ds.attrs["Fetched_by"] = 'anonymous'
ds.attrs["Fetched_date"] = pd.to_datetime("now", utc=True).strftime("%Y/%m/%d")
ds.attrs["Fetched_constraints"] = self.cname()
ds.attrs["Fetched_uri"] = ds.encoding["source"]
Expand Down Expand Up @@ -347,7 +350,10 @@ def to_xarray(self, errors: str = "ignore"):
ds.attrs["DATA_ID"] = "ARGO-BGC"
ds.attrs["DOI"] = "http://doi.org/10.17882/42182"
ds.attrs["Fetched_from"] = self.server
ds.attrs["Fetched_by"] = getpass.getuser()
try:
ds.attrs["Fetched_by"] = getpass.getuser()
except:
ds.attrs["Fetched_by"] = 'anonymous'
ds.attrs["Fetched_date"] = pd.to_datetime("now", utc=True).strftime("%Y/%m/%d")
ds.attrs["Fetched_constraints"] = self.cname()
if len(self.uri) == 1:
Expand Down
85 changes: 85 additions & 0 deletions docs/_static/pygments/lightbulb.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
pre { line-height: 125%; }
td.linenos .normal { color: #3c4354; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: #3c4354; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #3c4354; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #3c4354; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.highlight .hll { background-color: #6e7681 }
.highlight { background: #1d2331; color: #d4d2c8 }
.highlight .c { color: #7e8aa1 } /* Comment */
.highlight .err { color: #f88f7f } /* Error */
.highlight .esc { color: #d4d2c8 } /* Escape */
.highlight .g { color: #d4d2c8 } /* Generic */
.highlight .k { color: #FFAD66 } /* Keyword */
.highlight .l { color: #D5FF80 } /* Literal */
.highlight .n { color: #d4d2c8 } /* Name */
.highlight .o { color: #FFAD66 } /* Operator */
.highlight .x { color: #d4d2c8 } /* Other */
.highlight .p { color: #d4d2c8 } /* Punctuation */
.highlight .ch { color: #f88f7f; font-style: italic } /* Comment.Hashbang */
.highlight .cm { color: #7e8aa1 } /* Comment.Multiline */
.highlight .cp { color: #FFAD66; font-weight: bold } /* Comment.Preproc */
.highlight .cpf { color: #7e8aa1 } /* Comment.PreprocFile */
.highlight .c1 { color: #7e8aa1 } /* Comment.Single */
.highlight .cs { color: #7e8aa1; font-style: italic } /* Comment.Special */
.highlight .gd { color: #f88f7f; background-color: #3d1e20 } /* Generic.Deleted */
.highlight .ge { color: #d4d2c8; font-style: italic } /* Generic.Emph */
.highlight .ges { color: #d4d2c8 } /* Generic.EmphStrong */
.highlight .gr { color: #f88f7f } /* Generic.Error */
.highlight .gh { color: #d4d2c8 } /* Generic.Heading */
.highlight .gi { color: #6ad4af; background-color: #19362c } /* Generic.Inserted */
.highlight .go { color: #7e8aa1 } /* Generic.Output */
.highlight .gp { color: #d4d2c8 } /* Generic.Prompt */
.highlight .gs { color: #d4d2c8; font-weight: bold } /* Generic.Strong */
.highlight .gu { color: #d4d2c8 } /* Generic.Subheading */
.highlight .gt { color: #f88f7f } /* Generic.Traceback */
.highlight .kc { color: #FFAD66 } /* Keyword.Constant */
.highlight .kd { color: #FFAD66 } /* Keyword.Declaration */
.highlight .kn { color: #FFAD66 } /* Keyword.Namespace */
.highlight .kp { color: #FFAD66 } /* Keyword.Pseudo */
.highlight .kr { color: #FFAD66 } /* Keyword.Reserved */
.highlight .kt { color: #73D0FF } /* Keyword.Type */
.highlight .ld { color: #D5FF80 } /* Literal.Date */
.highlight .m { color: #DFBFFF } /* Literal.Number */
.highlight .s { color: #D5FF80 } /* Literal.String */
.highlight .na { color: #FFD173 } /* Name.Attribute */
.highlight .nb { color: #FFD173 } /* Name.Builtin */
.highlight .nc { color: #73D0FF } /* Name.Class */
.highlight .no { color: #FFD173 } /* Name.Constant */
.highlight .nd { color: #7e8aa1; font-weight: bold; font-style: italic } /* Name.Decorator */
.highlight .ni { color: #95E6CB } /* Name.Entity */
.highlight .ne { color: #73D0FF } /* Name.Exception */
.highlight .nf { color: #FFD173 } /* Name.Function */
.highlight .nl { color: #d4d2c8 } /* Name.Label */
.highlight .nn { color: #d4d2c8 } /* Name.Namespace */
.highlight .nx { color: #d4d2c8 } /* Name.Other */
.highlight .py { color: #FFD173 } /* Name.Property */
.highlight .nt { color: #5CCFE6 } /* Name.Tag */
.highlight .nv { color: #d4d2c8 } /* Name.Variable */
.highlight .ow { color: #FFAD66 } /* Operator.Word */
.highlight .pm { color: #d4d2c8 } /* Punctuation.Marker */
.highlight .w { color: #d4d2c8 } /* Text.Whitespace */
.highlight .mb { color: #DFBFFF } /* Literal.Number.Bin */
.highlight .mf { color: #DFBFFF } /* Literal.Number.Float */
.highlight .mh { color: #DFBFFF } /* Literal.Number.Hex */
.highlight .mi { color: #DFBFFF } /* Literal.Number.Integer */
.highlight .mo { color: #DFBFFF } /* Literal.Number.Oct */
.highlight .sa { color: #F29E74 } /* Literal.String.Affix */
.highlight .sb { color: #D5FF80 } /* Literal.String.Backtick */
.highlight .sc { color: #D5FF80 } /* Literal.String.Char */
.highlight .dl { color: #D5FF80 } /* Literal.String.Delimiter */
.highlight .sd { color: #7e8aa1 } /* Literal.String.Doc */
.highlight .s2 { color: #D5FF80 } /* Literal.String.Double */
.highlight .se { color: #95E6CB } /* Literal.String.Escape */
.highlight .sh { color: #D5FF80 } /* Literal.String.Heredoc */
.highlight .si { color: #95E6CB } /* Literal.String.Interpol */
.highlight .sx { color: #95E6CB } /* Literal.String.Other */
.highlight .sr { color: #95E6CB } /* Literal.String.Regex */
.highlight .s1 { color: #D5FF80 } /* Literal.String.Single */
.highlight .ss { color: #DFBFFF } /* Literal.String.Symbol */
.highlight .bp { color: #5CCFE6 } /* Name.Builtin.Pseudo */
.highlight .fm { color: #FFD173 } /* Name.Function.Magic */
.highlight .vc { color: #d4d2c8 } /* Name.Variable.Class */
.highlight .vg { color: #d4d2c8 } /* Name.Variable.Global */
.highlight .vi { color: #d4d2c8 } /* Name.Variable.Instance */
.highlight .vm { color: #d4d2c8 } /* Name.Variable.Magic */
.highlight .il { color: #DFBFFF } /* Literal.Number.Integer.Long */
6 changes: 0 additions & 6 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,6 @@ for standard users as well as Argo experts.

|License| |Python version| |Anaconda-Server Badge|

.. versionadded:: v0.1.14

- Rolling out incremental support for **bgc** variables 🎉
- New :ref:`Gallery of notebook examples <Gallery>` for **bgc** variables
- Check out a brief overview of new features on the :ref:`What's New` page


Documentation
-------------
Expand Down
9 changes: 8 additions & 1 deletion docs/whats-new.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,13 @@ What's New
|pypi dwn| |conda dwn|


v0.1.15 (12 Dec. 2023)
----------------------

**Internals**

- Fix bug whereby user name could not be retrieved using :func:`getpass.getuser`. This closes :issue:`310` and allows argopy to be integrated into the EU Galaxy tools for `ecology <https://github.com/galaxyecology/tools-ecology/pull/81>`_. (:pr:`311`) by `G. Maze <http://www.github.com/gmaze>`_.

v0.1.14 (29 Sep. 2023)
----------------------

Expand Down Expand Up @@ -406,7 +413,7 @@ v0.1.13 (28 Mar. 2023)
**Internals**

- Because of the new :class:`argopy.plot.ArgoColors`, the :class:`argopy.plot.discrete_coloring` utility is deprecated in 0.1.13. Calling it will raise an error after argopy 0.1.14. (:pr:`245`) by `G. Maze <http://www.github.com/gmaze>`_
- Because of the new :class:`argopy.plot.ArgoColors`, the `argopy.plot.discrete_coloring` utility is deprecated in 0.1.13. Calling it will raise an error after argopy 0.1.14. (:pr:`245`) by `G. Maze <http://www.github.com/gmaze>`_

- New method to check status of web API: now allows for a keyword check rather than a simple url ping. This comes with 2 new utilities functions :meth:`utilities.urlhaskeyword` and :meth:`utilities.isalive`. (:pr:`247`) by `G. Maze <http://www.github.com/gmaze>`_.

Expand Down

0 comments on commit a2b4f58

Please sign in to comment.