Python Forum
Key Error: os.environ["HOME"]
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Key Error: os.environ["HOME"]
#11
whenever i apply pay-test form project setting its retun the same output for unittest()
[u]it works for unittest but no output for pytest file as i run in my Pycharm it return error
Error:
please have loot at this -----> https://www.jetbrains.com/help/pycharm/choosing-your-testing-framework.html
Reply
#12
@Axel_Erfurt thanks for the help and assistance follow your suggestion i have to access 97% work but still i have these problems
because the result is zero and i want histogram to check the histogram plot for the clustering doc and data set yet test pass but result is zero
The main function
def main():
 if __name__ == "__main__":

    if len(sys.argv) != 4:
        print(' *', 'usage: <words file> <k, for doc 20>, <threshold, eg 0.9>')
        sys.exit(-1)

    f = sys.argv[1]
    k = int(sys.argv[2])
    t = float(sys.argv[3])

    words = load_tags(f)

    print(' *', 'generating dataset doc...')
    data, labels = make_data_matrix(words, t)

    print(' *', 'clustering doc...')
    word_cluster(data, labels, k=k, show_histogram_plot=True)
test_clustering_probability.py::TestSet::test_will_work PASSED [100%]

============================== warnings summary ===============================
..\..\Python3.8.0\Python\lib\site-packages\scipy\sparse\sparsetools.py:21
D:\Python3.8.0\Python\lib\site-packages\scipy\sparse\sparsetools.py:21: DeprecationWarning: scipy.sparse.sparsetools is deprecated!
scipy.sparse.sparsetools is a private module for scipy.sparse, and should not be used.
_deprecated()

-- Docs: https://docs.pytest.org/en/stable/warnings.html
======================== 1 passed, 1 warning in 1.85s =========================

Process finished with exit code 0
Reply
#13
From a few snippets of code, nobody can tell what is supposed to happen and where the error is.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Home Directory pgoosen 9 6,270 Oct-15-2020, 12:37 PM
Last Post: DeaD_EyE
  os.environ not setting current shell variables in Windows? brian6667 2 10,746 Apr-26-2017, 12:59 PM
Last Post: brian6667

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020