Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REF: ujson cleanups #54581

Merged
merged 4 commits into from
Aug 17, 2023
Merged

REF: ujson cleanups #54581

merged 4 commits into from
Aug 17, 2023

Conversation

jbrockmendel
Copy link
Member

  • closes #xxxx (Replace xxxx with the GitHub issue number)
  • Tests added and passed if fixing a bug or adding a new feature
  • All code checks passed.
  • Added type annotations to new arguments/methods/functions.
  • Added an entry in the latest doc/source/whatsnew/vX.X.X.rst file if fixing a bug or adding a new feature.

@mroeschke mroeschke added Refactor Internal refactoring of code IO JSON read_json, to_json, json_normalize labels Aug 16, 2023
@@ -137,6 +137,9 @@ typedef int64_t JSLONG;
#error "Endianness not supported"
#endif

// PANDAS_FORMAT is *not* in the original file this is vendored from
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any reason to move this? Unless it is used elsewhere should just stay in the module

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think i did this for a branch where i was trying to reimplement bits of the objToJSON.c in cython. will revert this bit.

@WillAyd
Copy link
Member

WillAyd commented Aug 16, 2023

Cool nice work - merge on green

@mroeschke mroeschke added this to the 2.2 milestone Aug 17, 2023
@mroeschke mroeschke merged commit 3b34c3b into pandas-dev:main Aug 17, 2023
30 of 32 checks passed
@mroeschke
Copy link
Member

Thanks @jbrockmendel

mroeschke pushed a commit to mroeschke/pandas that referenced this pull request Aug 18, 2023
* REF: use stdlib json

* remove unnecessary GET_TC calls

* REF: update dumps->ujson_dumps

* revert enum move
@jbrockmendel jbrockmendel deleted the ref-json-3 branch August 21, 2023 13:58
@neutrinoceros
Copy link
Contributor

This breaks user code that relied on pandas.io.json.loads, I'm surprised this went in without a deprecation period or a mention in pandas 2.2's changelog. Is this not considered public API ? (the lack of any trailing underscore suggests it's not private)

@mroeschke
Copy link
Member

pandas.io.json.loads is not a public API. The public JSON methods are listed in https://pandas.pydata.org/docs/reference/io.html#json and the more general policy on what's public is stated in https://pandas.pydata.org/docs/reference/index.html#api-reference

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
IO JSON read_json, to_json, json_normalize Refactor Internal refactoring of code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants