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

specific release requirement is not overwriting the general one #3149

Closed
kenkclam opened this issue Aug 8, 2016 · 6 comments
Closed

specific release requirement is not overwriting the general one #3149

kenkclam opened this issue Aug 8, 2016 · 6 comments

Comments

@kenkclam
Copy link

kenkclam commented Aug 8, 2016

Hi I have problem with the release
the specific release requirement is not overwriting the "any"
Any suggestions?
Thanks!

Expected Behavior

"release": {
"any": {"release_below_cp": 280, "release_below_iv": 80, "logic": "and"},
"// Example of releasing Rattata:": {},
"// Rattata": {"release_below_cp": 330},
},

if a 300 cp 50iv Rattata is caught,
It should not be released by the general rule (cp >280)
but should be released by the specific rule (cp<330)

Actual Behavior

if a 300 cp 50iv Rattata is caught, it is actually kept.
So the specific rule is not working

Steps to Reproduce

Other Information

OS: Mac

@fyooree
Copy link

fyooree commented Aug 8, 2016

"release_below_iv": 0.8 it should be i think ;)

for the specific rule. remove the //

@kenkclam
Copy link
Author

kenkclam commented Aug 8, 2016

Thanks! I changed it
but it still does not solve my problem!
It is still ignoring the specific rule

(with my mistake, basically nothing below 280 will be kept
Now after the correction, some will be kept
anyhow, a 300cp Rattata should not be kept and the bot is keeping it)

@g2384
Copy link

g2384 commented Aug 8, 2016

It may be because of line 144 in transfer_pokemon.py:

cp_iv_logic = release_config.get('logic')
if not cp_iv_logic:
    cp_iv_logic = self._get_release_config_for('any').get('logic', 'and')

I don't know why it should load the logic from 'any'.

Currently, you need to specify cp, iv and logic in your config.json in order to solve this issue temparily.

@kenkclam
Copy link
Author

kenkclam commented Aug 8, 2016

Do you mean I should change it to

"release": {
"any": {"release_below_cp": 280, "release_below_iv": 80, "logic": "and"},
"// Example of releasing Rattata:": {},
"// Rattata": {"release_below_cp": 330, "release_below_iv": 0.95, "logic": "and"},
},

for the script to work?
I actually try that it does not work.. a cp 300 rattata is still kept.

@g2384
Copy link

g2384 commented Aug 8, 2016

Wait. Do this.

"release": {
    "any": {"release_below_cp": 280, "release_below_iv": 80, "logic": "and"},
    "Rattata": {"release_below_cp": 330, "release_below_iv": 0.95, "logic": "and"}
},

Please let me make a palm face.

@kenkclam
Copy link
Author

kenkclam commented Aug 8, 2016

It works now!

Gosh, that was so dump // probably indicates a comment or something
I had no idea at all

Thanks so much! (I am closing this)

@kenkclam kenkclam closed this as completed Aug 8, 2016
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

No branches or pull requests

3 participants