Skip to content

Instantly share code, notes, and snippets.

View philipokiokio's full-sized avatar
⚔️
Number One Under the Sun. He who sees Patterns.

Philip Okiokio philipokiokio

⚔️
Number One Under the Sun. He who sees Patterns.
View GitHub Profile
import os
import json
import inspect
from pydantic import BaseModel
from typing import Dict, List, Tuple, Type
import root.main as root
import importlib
from slack_sdk import WebClient
from slack_sdk.errors import SlackApiError
import logging
@philipokiokio
philipokiokio / fraud_gaming_prevention.py
Last active August 19, 2023 14:08
Fraud Gaming Prevention with Hash Maps
#This Function incoprate cases that could exist with regards to storing and retrieving the data in a Hash Map /Dictionary
def gaming_refree(camp_data:Camp, link_code:str,gaming_data:dict):
url:str = ""
if len(gaming_data) > 0:
# There is camp data in the cookie so we check if this campaign is in the data store
for _, value in dict(camp_data.payload).items():
if type(value) == dict and value["code"] == link_code:
# when the camp data is not in the cookie
if gaming_data.get(camp_data.slug) is None:
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@philipokiokio
philipokiokio / DA0101EN-Review-Data-Wrangling.ipynb
Created September 25, 2019 09:25
Created on Cognitive Class Labs
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@philipokiokio
philipokiokio / DA0101EN-Review-Data-Wrangling.ipynb
Created September 25, 2019 09:25
Created on Cognitive Class Labs
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@philipokiokio
philipokiokio / DA0101EN-Review-Data-Wrangling.ipynb
Created September 25, 2019 09:15
Created on Cognitive Class Labs
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@philipokiokio
philipokiokio / DA0101EN-Review-Data-Wrangling.ipynb
Created September 25, 2019 09:15
Created on Cognitive Class Labs
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@philipokiokio
philipokiokio / DA0101EN-Review-Data-Wrangling.ipynb
Created September 25, 2019 09:05
Created on Cognitive Class Labs
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@philipokiokio
philipokiokio / DA0101EN-Review-Data-Wrangling.ipynb
Created September 25, 2019 09:05
Created on Cognitive Class Labs
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@philipokiokio
philipokiokio / DA0101EN-Review-Data-Wrangling.ipynb
Created September 25, 2019 08:55
Created on Cognitive Class Labs
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.