Pyfa - The Python Fitting Assistant

Hey, long term user of PYFA and first time I have had any major issue.

It’s been a while since I updated my characters and attempted to re-do the esi as ususal:
Editors > Character > Select character > Click SSO login button.

But when I select my character on the Eve website, all I get is:
" pyfa

Error! Server response not received.

The local pyfa server may have timed out, or may not have started correctly."

I turned off all firewalls etc that I have to see if it was my fault with no difference in the result.

What’s going on here?

Anyone? I have googled about and cannot find anything related to this yet I still cannot add characters to Pyfa.

I have created this post on the git repo:

I got this message today after trying to authorize one of my characters in through ESO to update skills (other characters were authorized without errors):

pyfa v2.39.3
EVE Data Version: 2000555 (2022-02-09 13:25:34)

OS version: Windows-10-10.0.19041-SP0
Python version: 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)]
wxPython version: 4.0.6 (wxWidgets 3.0.5)
SQLAlchemy version: 1.3.23
Logbook version: 1.5.3
Requests version: 2.27.1
Dateutil version: 2.8.2

####################

Traceback (most recent call last):
File “gui\characterEditor.py”, line 836, in ssoListChanged
File “gui\characterEditor.py”, line 848, in charChanged
File “site-packages\sqlalchemy\orm\attributes.py”, line 294, in get
File “site-packages\sqlalchemy\orm\attributes.py”, line 725, in get
File “site-packages\sqlalchemy\orm\state.py”, line 652, in _load_expired
File “site-packages\sqlalchemy\orm\loading.py”, line 1010, in load_scalar_attributes
File “site-packages\sqlalchemy\orm\loading.py”, line 206, in load_on_ident
File “site-packages\sqlalchemy\orm\loading.py”, line 286, in load_on_pk_identity
File “site-packages\sqlalchemy\orm\query.py”, line 3490, in one
File “site-packages\sqlalchemy\orm\query.py”, line 3459, in one_or_none
File “site-packages\sqlalchemy\orm\query.py”, line 3535, in iter
File “site-packages\sqlalchemy\orm\query.py”, line 3557, in _execute_and_instances
File “site-packages\sqlalchemy\orm\query.py”, line 3572, in _get_bind_args
File “site-packages\sqlalchemy\orm\query.py”, line 3550, in _connection_from_session
File “site-packages\sqlalchemy\orm\session.py”, line 1145, in connection
File “site-packages\sqlalchemy\orm\session.py”, line 1151, in _connection_for_bind
File “site-packages\sqlalchemy\orm\session.py”, line 440, in _connection_for_bind
AttributeError: ‘NoneType’ object has no attribute ‘twophase’

Hey, any chance we can get Drone EHP to show in pyfa? :>

Thank you, it took me forever to find this. I kept left clicking the cargo tab

Can somebody PLEASE make a dark theme for this app.
I’m going blind with all that white.

Could somebody please rewrite this app in Go or something more compiled and performant and less ugly?

1 Like

Issue tracked here [Request] Dark/Nightmode · Issue #1206 · pyfa-org/Pyfa · GitHub

Pull request here https://github.com/pyfa-org/Pyfa/pull/2175

Cannot connect my character

image

2 Likes

Issue tracker here → Issues · pyfa-org/Pyfa · GitHub

This is the code that throws that exception

File → service/esiAccess.py

   def validate_eve_jwt(self, jwt_token):
        """Validate a JWT token retrieved from the EVE SSO.
        Args:
            jwt_token: A JWT token originating from the EVE SSO
        Returns
            dict: The contents of the validated JWT token if there are no
                  validation errors
        """

        try:
            jwk_sets = self.jwks["keys"]
        except KeyError as e:
            raise GenericSsoError("Something went wrong when retrieving the JWK set. The returned "
                  "payload did not have the expected key {}. \nPayload returned "
                  "from the SSO looks like: {}".format(e, self.jwks))

        jwk_set = next((item for item in jwk_sets if item["alg"] == "RS256"))

        try:
            return jwt.decode(
                jwt_token,
                jwk_set,
                algorithms=jwk_set["alg"],
                issuer=[self.server_base.sso, "https://%s" % self.server_base.sso]
            )
        except ExpiredSignatureError as e:
            raise GenericSsoError("The JWT token has expired: {}".format(str(e)))
        except JWTError as e:
            raise GenericSsoError("The JWT signature was invalid: {}".format(str(e)))
        except JWTClaimsError as e:
            raise GenericSsoError("The issuer claim was not from login.eveonline.com or "
                "https://login.eveonline.com: {}".format(str(e)))

The RFC on JWT audience claim is RFC 7519: JSON Web Token (JWT)

Issue is tracked here Can't add character: "The JWT signature was invalid: Invalid audience" · Issue #2421 · pyfa-org/Pyfa · GitHub

Pull request for fix is here Skip validation of JWT "aud" claim by nmalaguti · Pull Request #2422 · pyfa-org/Pyfa · GitHub

Seems CCP added “aud” claim to the token

Might want to clone PyFa repository locally just in case, Github is on a banhammer rampage.

git clone https://github.com/pyfa-org/Pyfa.git

I cant add a character, what am i doing wrong?
Unbenannt

Got an error it said to share with you. Cheers.

pyfa v2.43.0
EVE Data Version: 2040917 (2022-05-05 06:28:05)

OS version: Windows-10-10.0.22000-SP0
Python version: 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)]
wxPython version: 4.0.6 (wxWidgets 3.0.5)
SQLAlchemy version: 1.3.23
Logbook version: 1.5.3
Requests version: 2.27.1
Dateutil version: 2.8.2

####################

Traceback (most recent call last):
File “gui\builtinViews\fittingView.py”, line 607, in fitChanged
File “gui\builtinViews\fittingView.py”, line 556, in generateMods
File “gui\builtinViews\fittingView.py”, line 556, in
ValueError: None is not in list

####################

Traceback (most recent call last):
File “gui\statsPane.py”, line 79, in fitChanged
File “gui\builtinStatsViews\priceViewFull.py”, line 88, in refreshPanel
File “service\price.py”, line 178, in getPrices
File “service\market.py”, line 501, in getItem
TypeError: Need Item object, integer, float or string as argument

pyfa v2.43.0
EVE Data Version: 2040917 (2022-05-05 06:28:05)

OS version: Windows-10-10.0.22000-SP0
Python version: 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)]
wxPython version: 4.0.6 (wxWidgets 3.0.5)
SQLAlchemy version: 1.3.23
Logbook version: 1.5.3
Requests version: 2.27.1
Dateutil version: 2.8.2

####################

Traceback (most recent call last):
File “gui\builtinViews\fittingView.py”, line 196, in OnMouseMove
IndexError: list index out of range

I have a question about PyFa, hope this is the right place to ask it.

I’m trying to theorycraft over a Dominix fit I might want to use for FOBs. It has 3 remote cap transmitters and 3 remote armor repairers.

After fiddling around a bit I found out that you can ‘project’ the effects of incoming remote cap / armor rep, so I added the same fit I was working on as a ‘Projected’ effect 3 times (the idea is that me and 3 friends will be flying the exact same domi fits).

Now this obviously changes the stats PyFa shows, but how does it calculate this?
Since all domi fits have 3 remote cap transmitters and 3 remote armor reps, will it:
A: Calculate the stats as if all 3 other domi’s use all their 3 remote cap / armor reps on me (i.e. I’m receiving the effects of 9 remote cap transmitters and 9 remote armor reps)
B: Calculate the stats as if each domi ‘splits’ their remote stuff over the 3 other domis (so I’m receiving the effects of 3 remote cap transmitters and 3 remote armor reps)

I’m assuming it’s A, but how could I use PyFa to simulate B?

EDIT:
I think I see how, but would still like confirmation :slight_smile:
I added the domi fit under ‘Projected’ 3 times, but I only put 1 remote cap transmitter and 1 remote armor repairer ‘Active’; the other are ‘Online’. I’m assuming PyFa will then calculate it as if the other 3 Domi’s all use 1 of their remote cap transmitters and 1 remote armor repairer on me. Is that assumption correct?

I believe you need to split manually.

PYFA simulates from the ship’s perspective, so you need to put in how many of the remote modules are being used on your ship specifically.

Any chance to get Drone EHP displayed in Pyfa? :>

Is there a quick way to plug in max alpha skills or do I gotta put in all the legwork?

v2.43.0
Medium Mercoxit Mining Crystal Optimization I - not taken into account in mining calculations
1.16 ratio

Is there any possible way to run Pyfa on Android? Thru OS emu or python dev kits?

Is it intentional that pyfa shows capital module volume in cargohold as assembled volume instead of the smaller packaged volume?