Skip to content

V9.0 fix get transformations files count#8162

Merged
chrisburr merged 3 commits intoDIRACGrid:integrationfrom
chaen:v9.0_fix_getTransformationsFilesCount
Apr 16, 2025
Merged

V9.0 fix get transformations files count#8162
chrisburr merged 3 commits intoDIRACGrid:integrationfrom
chaen:v9.0_fix_getTransformationsFilesCount

Conversation

@chaen
Copy link
Copy Markdown
Contributor

@chaen chaen commented Apr 16, 2025

Avoid this crash

2025-04-16T08:01:03,128907Z Transformation/TransformationManager ERROR: Exception while executing handler action
Traceback (most recent call last):
  File "/opt/dirac/versions/v12.0.0a17-1744604884/Linux-x86_64/lib/python3.11/site-packages/DIRAC/Core/DISET/private/Service.py", line 554, in _executeAction
    response = handlerObj._rh_executeAction(proposalTuple)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/dirac/versions/v12.0.0a17-1744604884/Linux-x86_64/lib/python3.11/site-packages/DIRAC/Core/DISET/RequestHandler.py", line 144, in _rh_executeAction
    result = self.__trPool.send(self.__trid, retVal)  # this will delete the value from the S_OK(value)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/dirac/versions/v12.0.0a17-1744604884/Linux-x86_64/lib/python3.11/site-packages/DIRAC/Core/DISET/private/TransportPool.py", line 109, in send
    return transport.sendData(msg)
           ^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/dirac/versions/v12.0.0a17-1744604884/Linux-x86_64/lib/python3.11/site-packages/DIRAC/Core/DISET/private/Transports/BaseTransport.py", line 168, in sendData
    sCodedData = MixedEncode.encode(uData)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/dirac/versions/v12.0.0a17-1744604884/Linux-x86_64/lib/python3.11/site-packages/DIRAC/Core/Utilities/MixedEncode.py", line 16, in encode
    return JEncode.encode(inData)
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/dirac/versions/v12.0.0a17-1744604884/Linux-x86_64/lib/python3.11/site-packages/DIRAC/Core/Utilities/JEncode.py", line 186, in encode
    return json.dumps(inData, cls=DJSONEncoder)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/dirac/versions/v12.0.0a17-1744604884/Linux-x86_64/lib/python3.11/json/__init__.py", line 238, in dumps
    **kw).encode(obj)
          ^^^^^^^^^^^
  File "/opt/dirac/versions/v12.0.0a17-1744604884/Linux-x86_64/lib/python3.11/json/encoder.py", line 200, in encode
    chunks = self.iterencode(o, _one_shot=True)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/dirac/versions/v12.0.0a17-1744604884/Linux-x86_64/lib/python3.11/json/encoder.py", line 258, in iterencode
    return _iterencode(o, 0)
           ^^^^^^^^^^^^^^^^^
TypeError: keys must be str, int, float, bool or None, not datetime.date

BEGINRELEASENOTES
*TS
FIX: Explicitly cast to string when returning dates

ENDRELEASENOTES

@chaen chaen requested a review from fstagni as a code owner April 16, 2025 10:13
@chrisburr chrisburr merged commit 748fd36 into DIRACGrid:integration Apr 16, 2025
23 checks passed
@DIRACGridBot DIRACGridBot added the sweep:ignore Prevent sweeping from being ran for this PR label Apr 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

sweep:ignore Prevent sweeping from being ran for this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants