ff14-advanced-market-search / AzerothAuctionAssassin

Apache License 2.0
9 stars 11 forks source link

1.2.5 #145

Closed cohenaj194 closed 2 weeks ago

cohenaj194 commented 1 month ago

closes: https://github.com/ff14-advanced-market-search/AzerothAuctionAssassin/issues/139

Summary by CodeRabbit

Summary by CodeRabbit

coderabbitai[bot] commented 1 month ago

Walkthrough

The changes in this pull request enhance the alerting functionality and data handling within the auction system. In mega_alerts.py, a new attribute, required_lvl, is introduced for auction items, affecting how alerts are constructed and sent. The pull_single_realm_data function now incorporates this attribute into alert messages. In utils/mega_data_setup.py, the MegaData class is updated to include required_lvl in its data structures, ensuring it is validated and initialized correctly. These modifications improve the robustness and clarity of auction alerts and item level data.

Changes

File Change Summary
mega_alerts.py - Added handling for required_lvl in pull_single_realm_data, check_tertiary_stats_generic, and format_alert_messages.
- Updated alert messages to include required_lvl when applicable.
utils/mega_data_setup.py - Introduced required_min_lvl and required_max_lvl in ilvl_info within __set_desired_ilvl, initialized to default values.
- Updated snipe_info construction to include base_required_levels.
- Modified method signatures to accept base_required_levels.
.github/workflows/windows-exe-build.yml - Updated AAA_VERSION from "1.2.4" to "1.2.5".
AzerothAuctionAssassin.py - Updated AAA_VERSION from "1.2.4.1" to "1.2.5".
- Added code for dynamic import path adjustment for Windows C# binary execution.
- Adjusted UI dimensions and labels for item level management.
utils/api_requests.py - Updated return signature of get_ilvl_items to include base_required_levels.
AzerothAuctionAssassinData/example_desired_ilvl_list.json - Added new item with ilvl 400 and required_min_lvl 71, required_max_lvl 79.
- Duplicated entry for ilvl 483.

Assessment against linked issues

Objective Addressed Explanation
Support required player levels in alerts (#139)
Validate item level data with required levels (#139)

Possibly related PRs

Poem

In the realm of auctions bright,
A new level shines with light.
Alerts now sing of levels due,
With required_lvl, we start anew.
Data dances, robust and clear,
Thanks to changes we hold dear! 🐇✨


🪧 Tips ### Chat There are 3 ways to chat with [CodeRabbit](https://coderabbit.ai): - Review comments: Directly reply to a review comment made by CodeRabbit. Example: - `I pushed a fix in commit , please review it.` - `Generate unit testing code for this file.` - `Open a follow-up GitHub issue for this discussion.` - Files and specific lines of code (under the "Files changed" tab): Tag `@coderabbitai` in a new review comment at the desired location with your query. Examples: - `@coderabbitai generate unit testing code for this file.` - `@coderabbitai modularize this function.` - PR comments: Tag `@coderabbitai` in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples: - `@coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.` - `@coderabbitai read src/utils.ts and generate unit testing code.` - `@coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.` - `@coderabbitai help me debug CodeRabbit configuration file.` Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. ### CodeRabbit Commands (Invoked using PR comments) - `@coderabbitai pause` to pause the reviews on a PR. - `@coderabbitai resume` to resume the paused reviews. - `@coderabbitai review` to trigger an incremental review. This is useful when automatic reviews are disabled for the repository. - `@coderabbitai full review` to do a full review from scratch and review all the files again. - `@coderabbitai summary` to regenerate the summary of the PR. - `@coderabbitai resolve` resolve all the CodeRabbit review comments. - `@coderabbitai configuration` to show the current CodeRabbit configuration for the repository. - `@coderabbitai help` to get help. ### Other keywords and placeholders - Add `@coderabbitai ignore` anywhere in the PR description to prevent this PR from being reviewed. - Add `@coderabbitai summary` to generate the high-level summary at a specific location in the PR description. - Add `@coderabbitai` anywhere in the PR title to generate the title automatically. ### Documentation and Community - Visit our [Documentation](https://coderabbit.ai/docs) for detailed information on how to use CodeRabbit. - Join our [Discord Community](http://discord.gg/coderabbit) to get help, request features, and share feedback. - Follow us on [X/Twitter](https://twitter.com/coderabbitai) for updates and announcements.
cohenaj194 commented 1 month ago

Ill need to fix remove_ilvl_to_list to handle the new feature, but we have to allow backwards compatibility too so this will work for people who dont have a required_lvl set for anything in the AzerothAuctionAssassinData/desired_ilvl_list.json

@coderabbitai recommend a fix.

https://github.com/ff14-advanced-market-search/AzerothAuctionAssassin/blob/main/AzerothAuctionAssassin.py#L1375-L1407

[
// cant remove
    {
        "ilvl": 400,
        "buyout": 10000,
        "sockets": false,
        "speed": false,
        "leech": false,
        "avoidance": false,
        "item_ids": [
            1111
        ],
        "required_lvl": 70
    },
// can remove
    {
        "ilvl": 400,
        "buyout": 1000,
        "sockets": false,
        "speed": true,
        "leech": false,
        "avoidance": false,
        "item_ids": []
    }
]
sonarcloud[bot] commented 4 weeks ago

Quality Gate Failed Quality Gate failed

Failed conditions
10.6% Duplication on New Code (required ≤ 3%)

See analysis details on SonarCloud