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

removed simplejson #6685

Merged
merged 3 commits into from
Jan 11, 2024
Merged

Conversation

AndrewChubatiuk
Copy link
Collaborator

What type of PR is this?

Removed unneeded simplejson dependency

  • Refactor
  • Feature
  • Bug Fix
  • New Query Runner (Data Source)
  • New Alert Destination
  • Other

@AndrewChubatiuk AndrewChubatiuk mentioned this pull request Jan 3, 2024
10 tasks
@AndrewChubatiuk AndrewChubatiuk changed the title Removed simplejson removed simplejson Jan 3, 2024
@masayuki038
Copy link
Collaborator

Thanks for separating this update from #6671.

I think this PR is related to #6218.
@konnectr @justinclift Could you review this?

Copy link

codecov bot commented Jan 8, 2024

Codecov Report

Attention: 6 lines in your changes are missing coverage. Please review.

Comparison is base (3c2c278) 63.30% compared to head (7bd2e00) 63.30%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #6685   +/-   ##
=======================================
  Coverage   63.30%   63.30%           
=======================================
  Files         162      162           
  Lines       13322    13322           
  Branches     1820     1820           
=======================================
  Hits         8434     8434           
  Misses       4599     4599           
  Partials      289      289           
Files Coverage Δ
redash/authentication/jwt_auth.py 77.35% <100.00%> (ø)
redash/utils/__init__.py 72.51% <100.00%> (ø)
redash/cli/__init__.py 59.61% <50.00%> (ø)
redash/handlers/webpack.py 95.00% <50.00%> (ø)
redash/query_runner/arango.py 60.46% <0.00%> (ø)
redash/query_runner/athena.py 50.81% <0.00%> (ø)
redash/query_runner/big_query.py 23.68% <0.00%> (ø)
redash/query_runner/pg.py 41.91% <0.00%> (ø)

@justinclift
Copy link
Member

@guidopetri Any interest in taking a look at this? 😄

Copy link
Collaborator

@guidopetri guidopetri left a comment

Choose a reason for hiding this comment

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

Sorry, I don't understand why we're changing to the JSON library. The original thread here doesn't make sense to me - the question of "why are we replacing this with the standard json library?" wasn't answered. Is the standard json library faster?

@AndrewChubatiuk
Copy link
Collaborator Author

AndrewChubatiuk commented Jan 10, 2024

@guidopetri it was removed in flask 2.0 by default and yes, simplejson is slower.

Results

loads (large obj)

json 0.333s
simplejson 0.351s

dumps (large obj)

json 0.364s
simplejson 0.409s

loads (small objs)

json 0.359s
simplejson 0.438s

dumps (small objs)

json 0.542s
simplejson 0.944s

guidopetri
guidopetri previously approved these changes Jan 11, 2024
Copy link
Collaborator

@guidopetri guidopetri left a comment

Choose a reason for hiding this comment

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

Got it, thanks!

@justinclift
Copy link
Member

Looks like this PR just needs it's dependencies updated by poetry (again?), then we can merge it. 😄

@AndrewChubatiuk
Copy link
Collaborator Author

Looks like this PR just needs it's dependencies updated by poetry (again?), then we can merge it. 😄

Done

Copy link
Member

@justinclift justinclift left a comment

Choose a reason for hiding this comment

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

Cool, lets get this merged. 😄

@justinclift justinclift merged commit 4d51039 into getredash:master Jan 11, 2024
14 of 15 checks passed
@justinclift
Copy link
Member

@AndrewChubatiuk Merged, thanks for getting this all done. 😄

@AndrewChubatiuk AndrewChubatiuk deleted the removed-simplejson branch May 9, 2024 18:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants