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

Correct the pyproject.toml black configuration ... #340

Merged
merged 1 commit into from
Jun 14, 2024

Conversation

ctrl-schaff
Copy link
Contributor

See https://black.readthedocs.io/en/stable/usage_and_configuration/the_basics.html#configuration-format

This has been broken since I started but I thought it was just a linux thing. Thanks @jal347 for validating it wasn't just me

@ctrl-schaff
Copy link
Contributor Author

Before:

(biothings) jschaff@tsri-ubuntu:~/workspace/biothings/biothings.api/biothings$ black utils/mongo.py 
Usage: black [OPTIONS] SRC ...
Try 'black -h' for help.

Error: Config key extend-exclude must be a string

After:

(biothings) jschaff@tsri-ubuntu:~/workspace/biothings/biothings.api$ black biothings/utils/mongo.py 
reformatted biothings/utils/mongo.py

All done! ✨ 🍰 ✨
1 file reformatted.

@ctrl-schaff ctrl-schaff merged commit 1fec955 into 0.12.x Jun 14, 2024
1 check failed
@ctrl-schaff ctrl-schaff deleted the fix-pyproject-black-configuration branch June 14, 2024 16:05
ctrl-schaff added a commit that referenced this pull request Jul 22, 2024
* test add volume feature

* added in named volume option

* fixed parsing in named volume option

* needs to be tested

* remove named volume when having keep_container flag as true in docker dumper

* added option to create multiple named volumes

* changed to a list

* fix: moved jmespath after other transformations

* add sqlite except for duplicate record _id

* test add volume feature

* added in named volume option

* fixed parsing in named volume option

* needs to be tested

* remove named volume when having keep_container flag as true in docker dumper

* added option to create multiple named volumes

* changed to a list

* revert to pymongo 4.6.3 due to pymongo logs leaking into biothings hub logs

* rolling back pymongo version to see errors

* hide pymongo logs

Unnecessary pymongo logs were shown in hub level after new pymongo 4.7 update.

https://pymongo.readthedocs.io/en/latest/changelog.html
Added support for Python’s native logging library, enabling developers to customize the verbosity of log messages for their applications.

* Add metadata query field validation (#330)

* Change the constructor for the ESQueryBuilder ...

Pass the actual BiothingsESMetadata object rather than a property
of the that into the constructor for the ESQueryBuilder

<main change>
def __init__(
    ...
    metadata: BiothingsMetadata = None, <- used to be BiothingsMetadata.biothings_metadata
)

* Add additional logging to the QStringParser.parse method

* Make logical changes to ensure parity with 0.12.x branch

* Add initial attempt at building metadata fields

* Remove the metadata from the parser constructor

* Create metadata field set generation method

* Add metadata field checking at query runtime

* Add signifcant docstring and logging to the parse method

* Add docstring comments to the structure of the metadata

* Improve error handling for the metadata access

---------

Co-authored-by: jschaff <jschaff@scripps.edu>

* added comments for new dockercontainerdumper options volumes and named_volumes

* metadata query logical enhancements and bugfixes (#331)

* Correct minor logical errors and improve logging

* Add ResultFormatter for metadata field formatting

* Fix pipeline constructor arguments

* Remove breakpoint

---------

Co-authored-by: jschaff <jschaff@scripps.edu>

* Fix metadata fields. (#334)

* Improve metadata field index search (#333)

* Iterate over all pontential metadata index fields

* Add 0 length check to ensure we return None for empty set

* Fix the regex tests by updating the method calls

* Update the metadata tests

---------

Co-authored-by: jschaff <jschaff@scripps.edu>

* client.snapshot.delete keyword arguments

Elasticsearch Python Client 8.0 requires keyword arguments

Credit to @ctrl-schaff for discovering this on pending.api

* Add more idiomatic sqlite multiple document insert (#335)

* Add executemany improvement and extra exception handling

* Modify the signature for bulk_write

* Fix the tuple malformatting

* Remove breakpoints

* Correct the arguments syntax

---------

Co-authored-by: jschaff <jschaff@scripps.edu>

* Api customization (#336)

Initial implementation of allowing use of custom config_webs when creating apis using the hub.

---------

Co-authored-by: mygene_hub <mygene@su05.scripps.edu>
Co-authored-by: Everaldo <everaldorodrigo@gmail.com>
Co-authored-by: Dylan Welzel <dylanwelzel@gmail.com>

* Add advanced plugin support for the command line tooling  (#329)

* Remove requirements around the manifest file

* Revert the import order

* Re-add the btinspect import that was accidently removed

---------

Co-authored-by: jschaff <jschaff@scripps.edu>

* Implement notifiers using asyncio (#337)

* Implement notifiers using asyncio library.

* Implement notifiers using asyncio library.

* Raise error if notifier is not implemented.

* Add certificate to the slack channel message.

* Add exponential backoff strategy.

* Add exponential backoff strategy.

* Clean code.

* Clean code.

* Add comment.

* Clean code.

* Move var to outside of the loop.

* Add comment.

* Keep same parameter name: event.

* Retry if get HTTP 5xx from GA4.

* Add tests for Notifiers.

* Add tests for Notifiers.

* Add tests for Notifiers.

* Add tests for Notifiers.

* Configure SSL for Slack Notifier.

* Fix metadata mapping and remove duplicated code. (#341)

* Fix Slack notifier test. (#343)

* Upgrade to tornado 6.4.1 (#342)

* Correct the pyproject.toml black configuration ... (#340)

See https://black.readthedocs.io/en/stable/usage_and_configuration/the_basics.html#configuration-format

Co-authored-by: jschaff <jschaff@scripps.edu>

* Replace deprecated imp module with importlib (#339)

The imp module has been deprecated since Python 3.4, which was released in March 2014. Python 3.12, released in October 2023, removed support for the imp module entirely.

* Fix pytest "Set" issue for older python versions (3.8 3.7)

* Build Config Err Fix

In the event an error occurs in one build config, every item in the list afterwards will contain the error. Resetting the error to None inside the loop fixes this.

* Add CLI mongodb support (#338)

* Remove requirements around the manifest file

* Revert the import order

* Generalize structure for mongodb support

---------

Co-authored-by: jschaff <jschaff@scripps.edu>

* Add id checking to IgnoreDuplicatedStorage ... (#344)

* Add id checking to IgnoreDuplicatedStorage ...

For the sequential case, this storage works as expected because
each document is checked for uniqueness. When processing this in batch,
there needs to be some more filtering involved especially if the number
of document is small with a higher ratio of duplicates in those
documents.

If you attempt to upload to the database and each batch has duplicates
in it, the entire batch will continually get thrown out until no
documents were actually uploaded to the database. Instead if we verify
the uniqueness constraint prior to uploading by ensuring we have a
one-to-one ratio of id to documents in our collection, then we can
ensure a safe upload.

This still discards identifical or near identical documents without
throwing out an entire batch of potentially valid documents in the batch
upload

* Remove breakpoint

---------

Co-authored-by: jschaff <jschaff@scripps.edu>

* Refactor ES exceptions (#346)

* Refactor ES exceptions.

* Add tests.

* Rollback changes in the connections tests file.

* Refactor ES exceptions.

* Review changes.

* Rise exceptions correctly. (#347)

* Rise exceptions correctly.

* Rise exceptions correctly.

---------

Co-authored-by: jal347 <linjason.03@gmail.com>
Co-authored-by: Everaldo <everaldorodrigo@gmail.com>
Co-authored-by: Chunlei Wu <anewgene@yahoo.com>
Co-authored-by: Dylan Welzel <dylanwelzel@gmail.com>
Co-authored-by: jschaff <jschaff@scripps.edu>
Co-authored-by: Chunlei Wu <newgene@users.noreply.github.com>
Co-authored-by: Jason Lin <35415519+jal347@users.noreply.github.com>
Co-authored-by: mygene_hub <mygene@su05.scripps.edu>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant