Skip to content

fix: dotenv and pinecone index name#147

Open
Anvayt24 wants to merge 1 commit into
c2siorg:mainfrom
Anvayt24:fix#146
Open

fix: dotenv and pinecone index name#147
Anvayt24 wants to merge 1 commit into
c2siorg:mainfrom
Anvayt24:fix#146

Conversation

@Anvayt24

Copy link
Copy Markdown
Contributor

Fixes #146

  • Loaded .env globally: Added load_dotenv() to db_update/Update.py so variables are loaded into os.environ.
  • Removed hardcoded Pinecone index: Replaced the hardcoded "cybernews-hybrid-test-2" index name in models/NewsModel.py. The Pinecone index name is now strictly read directly from os.getenv("PINECONE_INDEX_NAME") across the application. Added a safeguard to throw a ValueError if the user forgets to set it in their [.env]

@Anvayt24

Copy link
Copy Markdown
Contributor Author

@hardik1408 have a look at this!

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

Successfully merging this pull request may close these issues.

Fix: env loading and hardcoded Pinecone index name

1 participant