ssb-konjunk 0.1.10__tar.gz → 0.1.12__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ssb-konjunk
3
- Version: 0.1.10
3
+ Version: 0.1.12
4
4
  Summary: SSB Konjunk
5
5
  Home-page: https://github.com/statisticsnorway/ssb-konjunk
6
6
  License: MIT
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "ssb-konjunk"
3
- version = "0.1.10"
3
+ version = "0.1.12"
4
4
  description = "SSB Konjunk"
5
5
  authors = ["Edvard Garmannslund <ged@ssb.no>"]
6
6
  license = "MIT"
@@ -196,6 +196,8 @@ def _get_timestamp_special(*args: int, frequency: str) -> str | None:
196
196
  if frequency in ["M", "W"]:
197
197
  if frequency == "M":
198
198
  frequency = "-"
199
+ if frequency == "W":
200
+ frequency = "-W"
199
201
  if len(args) == 2:
200
202
  return f"p{args[0]}{frequency}{args[1]:02}"
201
203
  elif len(args) == 4:
@@ -204,7 +206,10 @@ def _get_timestamp_special(*args: int, frequency: str) -> str | None:
204
206
  )
205
207
  else:
206
208
  return None
209
+
207
210
  else:
211
+ if frequency in ["Q", "B", "T", "H"]:
212
+ frequency = f"-{frequency}"
208
213
  if len(args) == 2:
209
214
  return f"p{args[0]}{frequency}{args[1]}"
210
215
  elif len(args) == 4:
File without changes
File without changes