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
Exception on /api/v1/orchestrations/pipeline-schedules AttributeError: 'NoneType' object has no attribute 'get' #6240
Comments
@kgpayne @alexmarple looping you two in here since this seems to be a possible bug with the UI and/or multi-file YAML. @BuzzCutNorman can you share a bit about your Meltano setup too? Version of meltano and python version along with your meltano.yml file? Also, cc @visch since this is Windows 😄 |
@tayloramurphy sure thing. I have python 3.9.12 installed. Meltano was installed using pipx and is |
@aaronsteers adding to Engineering Assignments so we can get some eyes on it then we can figure out when to prioritize the fix. |
This points to @cjohnhanson - Can you take a look? |
@BuzzCutNorman (cc: @aaronsteers) this may be a bit hard to fully debug without a windows machine to test on. But I was able to replicate the error and stacktrace by replacing my Do you get this same error when you try to run other commands in the same project where you get the error for the
|
@cjohnhanson (cc: @aaronsteers ) I can verify that after running
I added a extractor tap-postgres to accomplish the the second requested test. The new
I started the
I set |
@cjohnhanson (cc: @aaronsteers ) Yesterday I created a local branch of Meltano and added the following logger to line 51 of
With the logger added I started a |
@cjohnhanson (cc: @aaronsteers ) Working more with this I found that the logger only helps if you have debug logging level in enabled. Once that is taken away you are right back to the error occurring. So the logger is just giving a slight amount of time for something to complete. Which lead me to this line of thinking. The error might occur when the
and the
happens really close together. The
and ran |
@BuzzCutNorman that's a great find, thanks for diving in deeper here. Just to 100% confirm -- you're only seeing this behavior with the If so, I think we can safely assume that this is a race condition between the two worker threads that refer to the same underlying As far as I can tell, we wrap references to the I'm both surprised we've never had reports of this behavior before and that it happens so consistently on your system. I'll get a PR with the change put together and @BuzzCutNorman once I do it'd be great if you could double check that it resolves the issue on your Windows machine, since we're having trouble replicating the issue elsewhere. |
@cjohnhanson (cc: @aaronsteers , @pandemicsyn ) Yes, I only see this behavior when I am navigating the UI after starting it by calling |
@cjohnhanson (cc: @aaronsteers , @pandemicsyn ) Ok I figured out on how I can test this. I have some results to share back. Is it best to put my comments here or put the comments in the PR ? I am guessing PR but just wanted to check. |
@BuzzCutNorman Glad you were able to test locally, I was working out how best to test on my end and was struggling to find a Windows machine that I could easily test on. Go ahead and share results in the PR and we can continue the discussion there. |
I can verify that I get this on Meltano with the Uvicorn feature flag enabled. I can't replicate this on Linux. |
@visch I have concluded I am not the best at testing upstream PRs locally. When you get a chance please test the PR for this issue so Cody can get a trustworthy Windows machine result. Thank you in advance. |
fyi - Took some grinding but was actually able to reproduce this race on my Mac as well, so not limited to Windows anything:
The most consistent way for me was just using one of the http bench mark tools and just hitting a few of the API endpoints as fast as possible. |
There's no tests in the UI, don't blame yourself for not testing every code path! Tests are supposed to do that :D The UI was atleast loading for me, then I changed something on my local machine and now I"m getting
EDIT: Figured this out. If I build the project myself locally ie something like
Meltano wants me to build the webapp folder manually. If instead I install meltano from pypi
Life is good. Something must be bundled with the PyPi build (yarn build or something I don't don't) |
I get this error sometimes when strating
meltano ui
on a windows machine. The error also happens when I navigate between tabs in the UI. The error is associtated with the following API call in the logHere is the ending bit of the error
It can't find the attribute
get
which I think is suppose to be a function of the class ? I also have not been able to determine what the functionget
is suppose to do. It seems like it is reading themeltano.yaml
for theinclude_paths
entries and return all the paths in a list. In theproject_files.py
there are these back to back function you can see there is ameltano
function.In
project.py
there is ameltano
function that returns aMeltanoFile
classThe
MeltanoFile
class that is inmeltano_file.py
has aget_plugins_for_mappings
.The text was updated successfully, but these errors were encountered: