Code Monkey home page Code Monkey logo

Comments (38)

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024 1

Hi Gordon, sorry for misleading message, when I say I was getting the same error, I should say I AM getting the same error. Was loath to raise a bug myself in case me not reading the setup instructions correctly. I am a developer but very new to HA, so thought it likely to be me missing a step.

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

Thanks for the suggestion, I've just upgraded pv_opt, and here are the logs now
AppDaemon_error_log.txt
AppDaemon_pv_opt_log.txt

I've now got this appliance disconnected from the inverter so the solis sensors are down which you'll see in the logs, but the situation is the same regarding all the pv_opt* sensors regardless of whether the inverter is connected or not.

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

It won't run with so many required sensors unavailable - but it doesn't behave very nicely when it fails. I've added some additional error traps to 3.8.11 as a pre-release which you should be able to get through HACS if you allow Beta releases.

Can you re-send the logs when the various sensors are available?

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

AppDaemon_error_log.txt
AppDaemon_pv_opt_log.txt
Hi Francis,

I've done the upgrade to 3.8.11 this morning and have attached to the inverter again. The Solis sensors are now up, but I'm still seeing the pv_opt sensors as unavailable. Interestingly pv_opt is also saying that the Solcast sensors are unavailable, although they are actually ok:

image

image

Update - I've just spotted this in AppDaemon, and this can't be good news:
image

and there are these entries in the main log:

image

Thanks again for all your help with this, and apologies if this is as a result of something I've managed to do wrong!

-Gordon

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

The issues you have highlighted aren't the problem. It is because the button that is used to send times to the inverter in the Solax integration has never been pressed so it is returning an "unknown" state. I've update 3.8.12_pre to allow for this. Let me know how you get on.

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

AppDaemon_error_log.txt
AppDaemon_pv_opt_log.txt
Morning Francis,

Please find new log files attached following the upgrade to 3.8.12_pre

Let me know if you need any more information or anything.

-Gordon

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

Brilliant, thanks for your help with this.

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

OK - found what I'd done wrong. 3.8.14 should be better. Just waiting on a response to a different issue before I release it.

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

Brilliant, thanks for investigating! Let me know when the new version is available and I'll give it a test :-)

from pv_opt.

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024

Just to add I was getting exactly the same error as Gordon. More importantly though I'd like to say a massive thank you to the author for all his hard work and skill.

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

@davidcornwell1969 can I ask what the resolution was to your issue, if it's something I can fix myself and save hassling the developers that would be amazing!

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

Please try 3.8.14 and let me know how you get on

from pv_opt.

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

It looks like this is a problem with the MQTT setup during AppDaemon configuration.

2024-02-23 14:53:41.522698 ERROR pv_opt: User defined log pv_opt_log not found
2024-02-23 14:53:41.523876 WARNING AppDaemon: Unknown Plugin Configuration in get_plugin_api()

self.mqtt.mqtt_publish(conf_topic, dumps(conf), retain=True)

Can I suggest you check that your appdaemon.yaml file looks like the one specified in section 11 of the README?

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

Also note that 3.9.0 is now out which shouldn't impact of the issues either of you have had but improves some of the tariff checks vs the Octopus integration

from pv_opt.

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024

Thanks for the above, I was having difficulting getting the log file not to issue an error even though I thought its should have created in the SAMBA share error. Will go and try to get this working.
I did dump some more debug out for the parameters passed to the self.mqtt.mqtt_publish call (hope you don't mind me changing your code? on my local copy)
This is what gets passed into to the method call,
2024-02-23 18:17:59.284712 INFO pv_opt: - DC about to make call mqtt_publish conf-> homeassistant/switch/pvopt_forced_charge/config dumps(conf) value is {"state_topic": "homeassistant/switch/pvopt_forced_charge/state", "command_topic": "homeassistant/switch/pvopt_forced_charge/set", "name": "Pvopt Forced Charge", "optimistic": true, "object_id": "pvopt_forced_charge", "unique_id": "pvopt_forced_charge", "payload_on": "ON", "payload_off": "OFF", "state_on": "ON", "state_off": "OFF"}

But will take your suggestion and try and gett appdaemon matching yours exactly.
Thanks again
David

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

The first warning is when the initialize method tries to load the MQTT plugin with self.mqtt = self.get_plugin_api("MQTT") so that suggests to me that there is something wrong with this section of appdaemon.yaml:

  appdaemon:
      MQTT:
        type: mqtt
        namespace: mqtt #
        verbose: True
        client_host: core-mosquitto
        client_port: 1883
        client_id: localad
        event_name: MQTT_MESSAGE 
        client_topics: NONE
        client_user: !secret mqtt-user
        client_password: !secret mqtt-password

You should then get something like this when AppDaemon starts up:

    13:16:24 INFO AppDaemon: AppDaemon Version 4.4.2 starting
    13:16:24 INFO AppDaemon: Python version is 3.11.6
    13:16:24 INFO AppDaemon: Configuration read from: /config/appdaemon.yaml
    13:16:24 INFO AppDaemon: Added log: AppDaemon
    13:16:24 INFO AppDaemon: Added log: Error
    13:16:24 INFO AppDaemon: Added log: Access
    13:16:24 INFO AppDaemon: Added log: Diag
    13:16:24 INFO AppDaemon: Added log: PV_Opt
    13:16:25 INFO AppDaemon: Loading Plugin HASS using class HassPlugin from module hassplugin
    13:16:25 INFO HASS: HASS Plugin Initializing
    13:16:25 WARNING HASS: ha_url not found in HASS configuration - module not initialized
    13:16:25 INFO HASS: HASS Plugin initialization complete
    13:16:25 INFO AppDaemon: Loading Plugin MQTT using class MqttPlugin from module mqttplugin
    13:16:26 INFO MQTT: MQTT Plugin Initializing
    13:16:26 INFO MQTT: Using 'localad/status' as Will Topic
    13:16:26 INFO MQTT: Using 'localad/status' as Birth Topic

from pv_opt.

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024

Thank you so much Francis, I think I had tabs rather than spaces to indent appdaemon.yaml. @pepetheprawn Wonder if you maybe have the same issue? Happy to help in any way I can?

Thanks again Francis for all your hard work.

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

Great to hear that you've got yours working @davidcornwell1969 . That appdaemon.yaml I literally copied/pasted from the readme, and I used the file editor within HA that gives you the green tick if the formatting is correct:
image
and the in secrets.yaml I have:
image

I don't see anything obviously wrong, but if you guys spot something or have any suggestions I'd be happy to receive them!

Thanks again for all your hard work.

-Gordon

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

I've just sanity checked my mqtt setup with this handy tool (https://mqtt-explorer.com/) and the mqtt side of things seems to be behaving as I'd expect:

image
so it does seem to be related to the integration between mqtt and pv_opt, but I can't see what's wrong!

-Gordon

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

@pepetheprawn - I've not seen any evidence your issues are MQTT related. When you get a chance send me the latest logs that you have and I'll have another look

@davidcornwell1969 - if the MQTT is fixed now you should be getting a bit further so please also send me log files when you get a chance

from pv_opt.

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024

Francis, seems to get a lot further now, loading tarrifs. I get an error further into the code now hopefully not my bad config.
pv_opt_error.txt.txt
Thx again

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

from pv_opt.

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024

No export tariff (currently), harder to get for a self install !
:)

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

from pv_opt.

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024

Whenever it comes, greatly appreciated. :)

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

Try 3.9.2 - works ok with mine when i explicity say no export tariff. Hopefully should play noce with Octopus Auto but let me know.

from pv_opt.

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024

Really sorry, I think the error is the same as before. Could you guide me as to where in config I can explicitly say no export tariff. I could try that for now and then comment out when I retest a fix?
pv_opt_error.txt.txt
Thanks
Dave :)

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

from pv_opt.

davidcornwell1969 avatar davidcornwell1969 commented on June 16, 2024

Hey Francis,
was pulling my hair out last week, trying to get to the log files if they are indeed being generated. Did a fair bit of googling and thought they should get created in my Samba share/logs folder but nothing in their. Will google some more and send once I have them. I shouldn't have to create the file manually right?
Thanks

Dave

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

No - if you've set up the share correctly and put it in the appdaemon.yaml file it should be there. You do have to restart AppDaemon addon IIRC. If you have the File editor Add On you can check the samba shared folder is there so long as "Enforce Basepath" is turned OFF in the Configuration for it:

image

image

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

Exciting news from the Plymouth office (and it's not about an unexploded WW2 bomb)! I do believe that it's now working! I just upgraded to 3.9.2 and the dashboard all looks great:

image
AppDaemon_error_log.txt
AppDaemon_pv_opt_log.txt
Latest log files attached for your review just to check that everything looks good from your perspective as well.

Thanks so much for all your hard work @fboundy, This really is an amazing bit of software.

-Gordon

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

from pv_opt.

fboundy avatar fboundy commented on June 16, 2024

It looks like you don't have any load history yet so you may be best switching to using a fixed estimate of consumption till you have some history data. Otherwise it looks fine to me. I'll close this issue now.

from pv_opt.

pepetheprawn avatar pepetheprawn commented on June 16, 2024

If I’d known I was dealing with a Janner… Exeter boy (originally) here… I’ll have a look at the logs etc tomorrow. Glad it seems to be working.

On 24 Feb 2024 at 16:01 +0000, Pepe The Prawn @.>, wrote: Exciting news from the Plymouth office (and it's not about an unexploded WW2 bomb)! I do believe that it's now working! I just upgraded to 3.9.2 and the dashboard all looks great: image.png (view on web) AppDaemon_error_log.txt AppDaemon_pv_opt_log.txt Latest log files attached for your review just to check that everything looks good from your perspective as well. Thanks so much for all your hard work @fboundy, This really is an amazing bit of software. -Gordon — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were mentioned.Message ID: @.>

I wasn't born here so I'm not a true janner! Thanks for taking a look at the logs and confirming all ok. This is running on a HA green appliance that I'm going to ship off to a friend, so I'll get them to run it 'read only' for a week or so to collect load history, and then they can kick it into production.

Thanks again for all your hard work with this, it's massively appreciated.

-Gordon

from pv_opt.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.