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

Bugfixes and migrate Messages table to the database #2457

Merged
merged 430 commits into from
Jul 1, 2024
Merged

Conversation

ogabrielluiz
Copy link
Contributor

This PR changes the Messages table in the MonitorService to use the main database.
It also fixes many bugs including how TracingService calls are made in the API, Graph ordering, Group component run id and many other fixes.

github-actions bot and others added 30 commits June 27, 2024 15:51
This commit refactors the code in the `migrate_messages_from_monitor_service_to_database` function to handle errors that may occur when retrieving messages from the monitor service. If an exception is raised, the error is logged and the function returns `False`. This ensures that the migration process can continue even if there is an issue with retrieving the messages.
This commit adds a new optional `metadata` parameter to the `end` method in the `BaseTracer` class. The `metadata` parameter allows for passing additional information related to the tracing process. This enhancement provides more flexibility and extensibility to the tracing functionality.
…quired parameters to enforce implementation in subclasses
…ype for optional arguments to improve code readability and type safety
…ctly when name is None and self.display_name is True
Bumps [braces](https://github.com/micromatch/braces) from 3.0.2 to
3.0.3.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/micromatch/braces/commit/74b2db2938fad48a2ea54a9c8bf27a37a62c350d"><code>74b2db2</code></a>
3.0.3</li>
<li><a
href="https://github.com/micromatch/braces/commit/88f1429a0f47e1dd3813de35211fc97ffda27f9e"><code>88f1429</code></a>
update eslint. lint, fix unit tests.</li>
<li><a
href="https://github.com/micromatch/braces/commit/415d660c3002d1ab7e63dbf490c9851da80596ff"><code>415d660</code></a>
Snyk js braces 6838727 (<a
href="https://github.com/micromatch/braces/issues/40">#40</a>)</li>
<li><a
href="https://github.com/micromatch/braces/commit/190510f79db1adf21d92798b0bb6fccc1f72c9d6"><code>190510f</code></a>
fix tests, skip 1 test in test/braces.expand</li>
<li><a
href="https://github.com/micromatch/braces/commit/716eb9f12d820b145a831ad678618731927e8856"><code>716eb9f</code></a>
readme bump</li>
<li><a
href="https://github.com/micromatch/braces/commit/a5851e57f45c3431a94d83fc565754bc10f5bbc3"><code>a5851e5</code></a>
Merge pull request <a
href="https://github.com/micromatch/braces/issues/37">#37</a>
from coderaiser/fix/vulnerability</li>
<li><a
href="https://github.com/micromatch/braces/commit/2092bd1fb108d2c59bd62e243b70ad98db961538"><code>2092bd1</code></a>
feature: braces: add maxSymbols (<a
href="https://github.com/micromatch/braces/issues/">https://github.com/micromatch/braces/issues/</a>...</li>
<li><a
href="https://github.com/micromatch/braces/commit/9f5b4cf47329351bcb64287223ffb6ecc9a5e6d3"><code>9f5b4cf</code></a>
fix: vulnerability (<a
href="https://security.snyk.io/vuln/SNYK-JS-BRACES-6838727">https://security.snyk.io/vuln/SNYK-JS-BRACES-6838727</a>)</li>
<li><a
href="https://github.com/micromatch/braces/commit/98414f9f1fabe021736e26836d8306d5de747e0d"><code>98414f9</code></a>
remove funding file</li>
<li><a
href="https://github.com/micromatch/braces/commit/665ab5d561c017a38ba7aafd92cc6655b91d8c14"><code>665ab5d</code></a>
update keepEscaping doc (<a
href="https://github.com/micromatch/braces/issues/27">#27</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/micromatch/braces/compare/3.0.2...3.0.3">compare
view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=braces&package-manager=npm_and_yarn&previous-version=3.0.2&new-version=3.0.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts
page](https://github.com/langflow-ai/langflow/network/alerts).

</details>
This PR adds a BaseTracer class and refactors the serialization logic in
convert_to_langchain_types.
#### Overview
This pull request introduces several improvements and changes aimed at
enhancing the test structure and codebase maintainability. The key
changes include breaking tests into smaller files to distribute across
more shards, replacing XPath locators with test ID locators, and
performing a general code refactor.

#### Changes

- Break Tests into Smaller Files:

Tests have been split into multiple files to better fit across more
shards. This change aims to improve test execution efficiency and
parallelization.

- Replace XPath Locators with Test ID Locators:

All locators previously using XPath have been updated to use data-testid
attributes. This change improves the reliability and readability of the
locators.

- General Code Refactor:

The codebase has undergone a general refactor to improve maintainability
and readability. This includes:
Renaming variables for better clarity.
Extracting reusable functions and components.
Improving code comments and documentation.
anovazzi1 and others added 17 commits July 1, 2024 13:53
* chore: Fix type hinting in ConditionalRouterComponent

* refactor: Update PassComponent to PassMessageComponent
Refactor the `ensure_valid_key` function in `utils.py` to improve the generation of a valid key for authentication. The function now checks if the input key is too short and generates a random key if necessary. Additionally, the key is now URL-safe base64-encoded. This change enhances the security and reliability of the authentication process.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* fix name on EditNodeModal

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <[email protected]>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* fix playground on store

* [autofix.ci] apply automated fixes

* Format code

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <[email protected]>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* feat: Add LanguageModel to field_typing module

* chore: Fix type annotations in model build methods

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
… to not be parsed (#2406)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* chore: update linting workflows to include dev branch in merge_group

* Update README.md

Add 1.0 banner

* Update README.md

* chore: update package versions in pyproject.toml files

* Added db value to every onChange on parameters

* Refactored global variables to find variables on the first render, and to execute just one onChange to update both values and db

* Changed group recursion function to include check for global variables already applied or outdated

* Removed already inserted component check for default fields on global variables

* Fixed import error

* Added required parameters to update node on drop

* Removed check for unused hardcoded name

* Added global variables handling on nodes when adding a flow

* Fixed maximum update depth when deleting used global variable

* Fixed type error on addNewVariableButton modal

* Fixed openai api key on starter flows

* Fixed values to get the .env values by default on the starter projects

* Formatted flows

* fix erros reported by mypy

* [autofix.ci] apply automated fixes

* 🐛 (prototypes/__init__.py): fix missing comma in the list of imported components to prevent syntax error

* chore: Fix type hinting in ConditionalRouterComponent

* [autofix.ci] apply automated fixes

---------

Co-authored-by: Gabriel Luiz Freitas Almeida <[email protected]>
Co-authored-by: Rodrigo Nader <[email protected]>
Co-authored-by: italojohnny <[email protected]>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
support standout logging with json and csv

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* add test to decision flow

* add test to decision flow

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
(fix) Add gpt4 to openai_constants

Co-authored-by: Gabriel Luiz Freitas Almeida <[email protected]>
@dosubot dosubot bot added the size:XL This PR changes 500-999 lines, ignoring generated files. label Jul 1, 2024
@dosubot dosubot bot added the bug Something isn't working label Jul 1, 2024
@ogabrielluiz ogabrielluiz enabled auto-merge July 1, 2024 18:21
@ogabrielluiz ogabrielluiz added this pull request to the merge queue Jul 1, 2024
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Jul 1, 2024
Merged via the queue into main with commit f98fea6 Jul 1, 2024
30 checks passed
@ogabrielluiz ogabrielluiz deleted the dev_to_main branch July 1, 2024 18:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working lgtm This PR has been approved by a maintainer size:XL This PR changes 500-999 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.